Advertisement
Guest User

Untitled

a guest
Feb 17th, 2013
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.91 KB | None | 0 0
  1. Follow the steps in order:
  2. 1. Download and build GPG according to your operating system from
  3. http://gnupg.org/Download the binary package directly if you do not
  4. know how to compile the source code.
  5.  
  6. 2. Download and install OpenSSL. Most Linux distributions come with
  7. pre-compiled OpenSSL packages. For Windows systems you may download
  8. binaries “Win32 OpenSSL v1.0.1e Light” from the following webpage
  9. http://slproweb.com/products/Win32OpenSSL.html
  10. If you have problems running OpenSSL, you may want to install
  11. version of Visual C++ 2008 `Redistributablesfor your operating
  12. system from the same webpage.
  13.  
  14. 3. Familiarize yourself with GnuPG. You can use manpages, or online
  15. documentation at
  16. http://gnupg.org/documentation/howtos.en.html.
  17. RSA Key Generation
  18.  
  19. 4. Use GPG to generate an RSA key pair (public and private keys).
  20. Choose option for RSA 2048 bit sign key. Provide your full name, and
  21. psu email address when asked.
  22.  
  23. 5. Export your public key in ASCII format into file public.key.
  24.  
  25. 6. Go to Angel lab2 directory to download the PGP public key of
  26. CMPSC443 (it is called cmpsc443public.key) and import it into your
  27. local key database (again you will use gpg command line). Use gpg –
  28. list-keysto verify that key was imported correctly.
  29. OpenSSL, AES generation and symmetric encryption
  30.  
  31. 7. Use openssl enccommand line symmetric cipher routine to generate a
  32. 256bit AES key in CBC mode. You should use SHA1 as a message digest
  33. function for generating the key. Save generated secret key, IV, and
  34. salt into file named aes.key. (Use –P opting to print out the key,
  35. salt and IV used then immediately exit, don’t do any encryption at
  36. this step.)
  37. http://www.openssl.org/docs/apps/enc.html#
  38.  
  39. 8. Create a text file lab2.txtthat contains your full name and
  40. operating system you are using for this lab. *You are to print all
  41. commands used for keys generation, encryption, and digital
  42. signatures in the file at step 14.*
  43. 9. Use openssl encto encrypt lab2.txt with generated AES key. Use –
  44. kfile option to specify generated key aes.key. Encrypted file must
  45. be saved in base64-encoded format in file lab2_encr.txt.
  46. GPG, asymmetric encryption, and digital signatures
  47.  
  48. 10. Use gpg to encrypt aes.key file generated in step 7 with public key
  49. of cmpsc443public.key and store the result in ASCII format in
  50. aes.key.asc file.
  51.  
  52. 11. Use gpg and your own private RSA key to digitally sign aes.key.asc.
  53. Digital signature must be appendedto cipher and stored in
  54. key_signed.txt
  55.  
  56. 12. Use gpg and your own private RSA key to digitally sign
  57. lab2_encr.txt. Digital signature must be appendedto cipher and
  58. stored in lab2_signed.txt
  59.  
  60. 13. Verify both created signatures.
  61.  
  62. 14. Repeat steps 8 through 13. For step 5:In lab2.txt add all commands
  63. that you used to generate AES and RSA keys, encrypt both files, and
  64. sign both files. Make sure to provide comments for each command used!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement