Encryting both file contents and file name with GnuPG

David Shaw dshaw at jabberwocky.com
Sun Jan 2 16:28:36 CET 2011


On Jan 2, 2011, at 10:06 AM, Neil Phillips wrote:

> SecureZip will take a file and encrypt both the filename and the file.
> 
> so far with GnuPG i can only see how to encrypt the file.
> 
> i do not want to use a specific name as there are too many files to do that.
> i want something like;
> 
> gpg -recipient "Neil Phillips" -output_encrypt "mySecrets.txt" -encrypt
> "mySecrets.txt"
> 
> where i end up with my source file "mySecrets.txt" and a GnuPG encrypted file
> whose name is the result of encrypting "mySecrets.txt"
> 
> sort of nesting i guess.
> 
> so where it says -output_encrypt "mySecrets.txt" i want the result of:
> gpg -recipient "Neil Phillips" -encrypt [just the name: "mySecrets.txt]
> 
> i am using windows. the source file location is secure.
> i want to place a copy of the source file in an unsecure place.
> hence i want to rename the file as well as encrypt the file itself.

GPG does not do this.  GPG gives you the necessary hooks to do it yourself (i.e. the --output) option, but does not do it for you.

David




More information about the Gnupg-users mailing list