Warning: This question has been heavily edited. I tried my best to guess the original author's intentions. Please view the original version.
I'm unsure on how to use the GPG command line tool, that we're using to encrypt files.
File.txt is a simple text file:
Testing hello world My security things.
This is how I encrypt the file:
gpg --symmetric File.txt
This gives me a new, encrypted file: File.txt.gpg
If someone else now modifies the encrypted file, I'm no longer able to decrypt it.
$ gpg --decrypt File.txt.gpg
gpg: no valid OpenPGP data found.
gpg: decrypt_message failed: eof
How can I get the content of my file, even though someone has modified it?