# GPGTAR(1) - man - phpMan

[GPGTAR(1)](https://www.chedong.com/phpMan.php/man/GPGTAR/1/markdown)                               GNU Privacy Guard 2.2                              [GPGTAR(1)](https://www.chedong.com/phpMan.php/man/GPGTAR/1/markdown)



## NAME
       **gpgtar** - Encrypt or sign files into an archive

## SYNOPSIS
       **gpgtar** [_options_] _filename1_ _[_ _filename2,_ _..._ _]_ _directory1_ _[_ _directory2,_ _..._ _]_


## DESCRIPTION
       **gpgtar**  encrypts or signs files into an archive.  It is an gpg-ized tar using the same format
       as used by PGP's PGP Zip.


## OPTIONS
       **gpgtar** understands these options:



### --create
              Put given files and directories into a vanilla ``ustar'' archive.


### --extract
              Extract all files from a vanilla ``ustar'' archive.


### --encrypt
### -e
              option  **--symmetric**  for  an  archive  that  may  be  decrypted  via a secret key or a
              passphrase.


### --decrypt
### -d


### --sign
### -s
              option **--encrypt** to create a signed and then encrypted archive.


### --list-archive
### -t


### --symmetric
### -c
              is AES-128, but may be chosen with the **--cipher-algo** option to **gpg**.


       **--recipient** _user_
### -r
              Encrypt for user id _user_. For details see **gpg**.


       **--local-user** _user_
### -u
              Use _user_ as the key to sign with.  For details see **gpg**.


       **--output** _file_
### -o
              Write the archive to the specified file _file_.


### --verbose
### -v


### --quiet
### -q


### --skip-crypto
              Skip all crypto operations and create or extract vanilla ``ustar'' archives.


### --dry-run
              Do not actually output the extracted files.


       **--directory** _dir_
### -C
              from the input filename.  If no input filename is known a directory named ‘_GPGARCH_’ is
              used.  For tarball creation, switch to directory _dir_ before performing any operations.


       **--files-from** _file_
### -T
              Take the file names to work from the file _file_; one file per line.


       **--null** Modify option **--files-from** to use a binary nul instead of a linefeed to separate  file
              names.


### --utf8-strings
              Assume that the file names read by **--files-from** are UTF-8 encoded.  This option has an
              effect only on Windows where the active code page is otherwise assumed.


### --openpgp
              This option has no effect because OpenPGP encryption and signing is the default.


       **--cms**  This option is reserved and shall not be used.  It will eventually be used to  encrypt
              or sign using the CMS protocol; but that is not yet implemented.



       **--set-filename** _file_
              Use  the  last  component of _file_ as the output directory.  The default is to take the
              directory name from the input filename.  If no input filename  is  known  a  directory
              named ‘_GPGARCH_’ is used.  This option is deprecated in favor of option **--directory**.


       **--gpg** _gpgcmd_
              Use the specified command _gpgcmd_ instead of **gpg**.


       **--gpg-args** _args_
              Pass the specified extra options to **gpg**.


       **--tar-args** _args_
              Assume  _args_  are  standard  options of the command **tar** and parse them.  The only sup‐
              ported tar options are "--directory", "--files-from", and "--null" This is an obsolete
              options because those supported tar options can also be given directly.


### --version
              Print version of the program and exit.


       **--help** Display a brief help page and exit.


## EXAMPLES
       Encrypt the contents of directory ‘_mydocs_’ for user Bob to file ‘_test1_’:

         gpgtar --encrypt --output test1 -r Bob mydocs


       List the contents of archive ‘_test1_’:

         gpgtar --list-archive test1



## DIAGNOSTICS
       The program returns 0 if everything was fine, 1 otherwise.



## SEE ALSO
       [**gpg**(1)](https://www.chedong.com/phpMan.php/man/gpg/1/markdown), [**tar**(1)](https://www.chedong.com/phpMan.php/man/tar/1/markdown),

       The  full  documentation  for  this tool is maintained as a Texinfo manual.  If GnuPG and the
       info program are properly installed at your site, the command

         info gnupg

       should give you access to the complete manual including a menu structure and an index.



GnuPG 2.2.27                                 2020-12-21                                    [GPGTAR(1)](https://www.chedong.com/phpMan.php/man/GPGTAR/1/markdown)
