How to verify the file was successfully encrypted...

Janusz A. Urbanowicz alex at bofh.net.pl
Wed Jul 12 12:25:09 CEST 2006


On Tue, Jul 11, 2006 at 01:38:23PM -0600, Benny Helms wrote:
> Hi folks.
> 
> I've read the man page.  I've read the FAQ's.  I'm not seeing what I'm
> looking for.
> 
> Using something like "zip", you can use a -T to test the integrity of
> the file.  Note: this is not testing that nobody has altered it, or that
> it came from a specific user; it is only testing whether it is a good
> gpg file and whether it can be decrypted.  All I can find in gpg is a
> way to verify the integrity vs. a signature file.
> 
> I'm looking for a way to gpg encrypt a file, test that the encryption
> was good and that the file can be extracted, and then to delete the
> original file.

What is your actual threat model here?

The simplest answer is to check gpg's rc after the encryption run.



More information about the Gnupg-users mailing list