Encrypting a File
Now suppose that you wish to encrypt a file named chapter24.odt so that only the user named Andy Oram can use it. You would issue the following command:
gpg -e -u "James Stanger" -r "Andy Oram" chapter24.odt
The resulting file would be called chapter24.odt.gpg.
Once Andy receives this file, he would issue the following command:
gpg -d chapter24.odt.gpg
He would then be able to read the file using OpenOffice.