PGP - Pretty Good Privacy

I have created a pair of PGP keys (public and private) on tanner. The question for this assignment has been encrypted using the public key. You will need to decrypt the question, answer it, and send your answer to me in an encrypted form. To do so, follow the steps below. For a summary of PGP commands, click here.
  1. On tanner, in your home directory, create another directory called ".pgp" (without the quotes). Set your current directory to ~/.pgp:
        cd ~/.pgp
    
  2. Download my PGP public key and my signed question into your .pgp account.

  3. Generate your own pair of PGP keys using
        pgp -kg
    
    Make sure to use the pgp version /opt/local/bin/pgp. Two rings, one public (pubring.pgp) and one secret (secring.pgp) will be created in your .pgp directory. To view the contents of a ring - pubring.pgp, for instance - type in
        pgp -kv yourid pubring
    
    Here yourid is the user identifier you used when creating your keys. Make sure you remember both this identifier and the pass phrase associated with your keys.

  4. Add my public key to your public ring.
        pgp -ka damian.public.pgp pubring
    

  5. Extract the assignment question from the PGP file:
        pgp question.pgp -o question.txt
    
    The signature will be verified and the original text will be saved in question.txt.

  6. Write your answer to the question into a text file (let me refer to it as the answerfile), and sign it using your private key.
        pgp -sta answerfile -u yourid
    
    A file called answerfile.asc (that could be displayed in text format) will be created.

  7. Extract your public key from your public ring:
        pgp -kx yourid keyname ~/.pgp/pubring
    
    Your public key will be extracted in the file keyname.pgp.

  8. Encrypt your public key using my public key.
        pgp -e keyname.pgp
    
    You will be promted for the userid of the public key you wish to encrypt with. Use "mirela.damian", without quotes.

  9. Email me both answerfile.asc and the encrypted keyname.pgp.

To verify the correctedness of your work, I will extract your public key from keyname.pgp and use it to check your signature from answerfile.pgp.