File name seen by gpg

Alvaro Martínez alvaro.gmj at
Thu Oct 25 22:29:35 CEST 2018


I just joined the list, hoping to find some guidance regarding my use of
gpg as part of a backup scheme.

I uploaded files to Amazon S3, after encrypting them locally. I kept a log
containing the hash of the encrypted file, the hash of the plain file, and
the file name. The idea is that I would regularly hash the files on my
computer and check the hashes against the copies in S3. I used symmetric
encryption because I read that public key encryption done by GPG includes
some random content and therefore does not always produce the same output.

I didn't know when I encrypted the files that the file name is part of the
encrypted data, and therefore a change in the file name changes the
resulting hash. I have files with accented characters on their names, those
names were encoded in UTF-8 by a Linux system. I am now using a Mac, which
encodes the same characters in a different way ("fully decomposed" vs the
original "precomposed" UTF-8), so the hashes of the encrypted files do not

I want to use a scheme which allows me to somehow future-proof my backups.
I can still do the checks and backups in a Linux box, but this issue made
me realize subtle system changes can break my backup strategy easily.

I read elsewhere that GPG can be told to not store any name, but if I do
that I'll have to re-upload my files, and although I'm willing to do that
for an improvement in the backup scheme, it would be quite painful on my
512Kbps line.

Is there any way to tell GPG which name it should use for the input file in
the encrypted data? something like the "iconv" option for rsync would be
ideal, but my searches on the web don't return any results.

Thanks for reading :)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Gnupg-users mailing list