saltstack/salt

[BUG] gpg.encrypt text=foo output=/some/file does not write to a file

已關閉

#56,645 建立於 2020年4月15日

 (4 則留言) (0 個反應) (0 位負責人)Python (5,508 個分叉)batch import
ConfirmedExecution-Modulebuggood first issueneeds-testcaseseverity-medium

倉庫指標

星標
 (13,710 顆星)
PR 合併指標
 (平均合併 72天 6小時) (30 天內合併 221 個 PR)

描述

Description

A clear and concise description of what the bug is.

Setup

Create/import a GPG key.

Steps to Reproduce the behavior

Try to encrypt some text:

[root@master1 salt]# salt-call gpg.encrypt text=foo recipients=2CFCA2B538DD0FAC75838096A4E89A0D3328D483 output=/tmp/encrypted_foo.txt user=salt
local:
    ----------
    comment:
        Encrypted data has been written to /tmp/encrypted_foo.txt
    res:
        True
[root@master1 salt]# cat /tmp/encrypted_foo.txt
cat: /tmp/encypted_foo.txt: No such file or directory

Expected behavior

The file should be created.

Versions Report

# salt-call test.versions_report
local:
    Salt Version:
               Salt: 3000.1
     
    Dependency Versions:
               cffi: Not Installed
           cherrypy: Not Installed
           dateutil: Not Installed
          docker-py: Not Installed
              gitdb: Not Installed
          gitpython: Not Installed
             Jinja2: 2.7.2
            libgit2: Not Installed
           M2Crypto: Not Installed
               Mako: Not Installed
       msgpack-pure: Not Installed
     msgpack-python: 0.6.2
       mysql-python: Not Installed
          pycparser: Not Installed
           pycrypto: 2.6.1
       pycryptodome: Not Installed
             pygit2: Not Installed
             Python: 2.7.5 (default, Aug  7 2019, 00:51:29)
       python-gnupg: 0.4.3
             PyYAML: 3.11
              PyZMQ: 15.3.0
              smmap: Not Installed
            timelib: Not Installed
            Tornado: 4.5.3
                ZMQ: 4.1.4
     
    System Versions:
               dist: centos 7.6.1810 Core
             locale: UTF-8
            machine: x86_64
            release: 5.3.0-46-generic
             system: Linux
            version: CentOS Linux 7.6.1810 Core

貢獻者指南