Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.64 KB | None | 0 0
  1. cd /tmp
  2. tar xvzf ~/Downloads/openssl-1.0.1g.tar.gz
  3.  
  4. else if (!strcmp (*args, "-noiter"))
  5. iter = 1;
  6. else if (!strcmp (*args, "-nocrypt"))
  7. nocrypt = 1;
  8.  
  9. else if (!strcmp (*args, "-noiter"))
  10. iter = 1;
  11. else if (!strcmp (*args, "-iter"))
  12. {
  13. if (!args[1]) goto bad;
  14. iter = atoi(*(++args));
  15. if (iter <= 0) goto bad;
  16. }
  17. else if (!strcmp (*args, "-nocrypt"))
  18. nocrypt = 1;
  19.  
  20. cd /tmp/openssl-1.0.1g
  21. ./config --prefix=$HOME/local
  22. make
  23. make test
  24. make install
  25.  
  26. $HOME/local/bin/openssl genrsa -out rsaraw.pem 2048
  27. $HOME/local/bin/openssl pkcs8 -topk8 -v2 aes128 -iter 1000000 -in rsaraw.pem -out rsapk8.pem
  28.  
  29. openssl asn1parse -i -in rsapk8.pem
  30.  
  31. 0:d=0 hl=4 l=1312 cons: SEQUENCE
  32. 4:d=1 hl=2 l= 74 cons: SEQUENCE
  33. 6:d=2 hl=2 l= 9 prim: OBJECT :PBES2
  34. 17:d=2 hl=2 l= 61 cons: SEQUENCE
  35. 19:d=3 hl=2 l= 28 cons: SEQUENCE
  36. 21:d=4 hl=2 l= 9 prim: OBJECT :PBKDF2
  37. 32:d=4 hl=2 l= 15 cons: SEQUENCE
  38. 34:d=5 hl=2 l= 8 prim: OCTET STRING [HEX DUMP]:A4E21F4F210DEB6F
  39. 44:d=5 hl=2 l= 3 prim: INTEGER :0F4240
  40. 49:d=3 hl=2 l= 29 cons: SEQUENCE
  41. 51:d=4 hl=2 l= 9 prim: OBJECT :aes-128-cbc
  42. 62:d=4 hl=2 l= 16 prim: OCTET STRING [HEX DUMP]:DAA184B3F6CC303B6A40A131E5C8C451
  43. 80:d=1 hl=4 l=1232 prim: OCTET STRING [HEX DUMP]:2C15CF37D5ACC537AA92B
  44. (...)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement