How could we validate that the encryption was really successful after completion?
I assume such an option (e.g. --validate or --verify) would be a good addition to crypto. The only feasible solution I can see right now, though, is to decrypto the file as a new temporary file and then compare this result with the original input file (maybe by comparing md5/sha256 hash values).
Ok, theoretically it could still be the decryption that is messing up in this scenario, but I don't exactly see a better solution.
GPG errors are raised if there are problems with encryption and the non 0 exit status code indicates a problem. I think that we need to rely on GPG to handle that.
How could we validate that the encryption was really successful after completion?
I assume such an option (e.g.
--validate
or--verify
) would be a good addition tocrypto
. The only feasible solution I can see right now, though, is todecrypto
the file as a new temporary file and then compare this result with the original input file (maybe by comparing md5/sha256 hash values).Ok, theoretically it could still be the decryption that is messing up in this scenario, but I don't exactly see a better solution.