Advertisement
Guest User

Untitled

a guest
Aug 16th, 2017
420
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.64 KB | None | 0 0
  1. openssl req -new -nodes -newkey rsa:2048 -subj '/C=IN/ST=MH/L=Pune/O=Organisation/OU=Development/emailAddress=address@example.com/CN=localhost/subjectAltName=DNS.1=192.168.0.1/' -keyout server.key -out server.csr
  2. openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt
  3. cp server.key server.tmp
  4. openssl rsa -in server.tmp -out server.key
  5. cp server.crt /Applications/MAMP/conf/apache
  6. cp server.key /Applications/MAMP/conf/apache
  7.  
  8. //
  9. openssl req -new -sha256 \
  10. -key server.key \
  11. -subj "/C=IN/ST=MH/L=Pune/O=Organisation/OU=Development/emailAddress=address@example.com/CN=localhost" \
  12. -reqexts SAN \
  13. -config <(cat /etc/ssl/openssl.cnf \
  14. <(printf "\n[SAN]\nsubjectAltName=DNS:localhost,DNS:192.168.0.1")) \
  15. -out server.csr
  16.  
  17. openssl req -new -sha256 -key server.key -subj "/C=IN/ST=MH/L=Pune/O=Organisation/OU=Development/emailAddress=address@example.com" -reqexts SAN -config <(cat /etc/ssl/openssl.cnf <(printf "[SAN]\nsubjectAltName=DNS:localhost,DNS:192.168.0.1")) -out server.csr
  18.  
  19. //
  20. openssl req -new -sha256 -key server.key -subj "/C=IN/ST=MH/L=Pune/O=Organisation/OU=Development/emailAddress=address@example.com" -out server.csr -extfile v3.ext
  21. openssl req -x509 -newkey rsa:2048 -out MyCompanyCA.cer -outform PEM -keyout MyCompanyCA.pvk -days 10000 -verbose -config MyCompanyCA.cnf -nodes -sha256 -subj "/CN=Globant"
  22. openssl req -newkey rsa:2048 -keyout MyCompanyLocalhost.pvk -out MyCompanyLocalhost.req -subj /CN=localhost -sha256 -nodes
  23. openssl x509 -req -CA MyCompanyCA.cer -CAkey MyCompanyCA.pvk -in MyCompanyLocalhost.req -out MyCompanyLocalhost.cer -days 10000 -extfile MyCompanyLocalhost.ext -sha256 -set_serial 0x1111
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement