The easiest method for key pair creation is to create a self-signed key. This key is self-signed because no other authority guarantees its authenticity. For testing purposes, it is sufficient to create one that works for 30 days using the following command:
openssl req -new -x509 -keyout server.pem -out server.pem -nodes
This command will ask some questions. If you want to use the default, just press enter. If you want to leave them blank, you can enter a period. However, the certificate may then be deemed invalid by some clients.
Country Name (2 letter code) [AU]: UK
State or Province Name (full name) [Some-State]: .
Locality Name (eg, city) []: London
Organization Name (eg, company) [Internet Widgits Pty Ltd]: Packt Publishing
Organizational Unit Name (eg, section) []: .
Common Name (eg, YOUR name) []: www.packtpub.com
Email Address []: [email protected]
Enter country name, city name, organization name and email address. For the common name, enter your server address. The...