Generate SSL Key and Certificate

From WiDirect
Jump to: navigation, search

It is important to generate a new SSL key and certificate when accepting payments using Authorize.net. To generate an SSL key, run this command:

	sudo openssl genrsa –out localhost.key 2048

To create a self signed certificate, run this command:

	sudo openssl req -new -x509 -nodes -sha1 -days 365 -key localhost.key > localhost.crt

Run the following command to create a certificate signing request (CSR) for a third party to generate a key:

	openssl req -new -key localhost.key -out localhost.csr

View the contents of those files with these commands:

	cat localhost.key
	cat localhost.crt
	cat localhost.csr

The entire contents of the key and certificate files, including the lines that start with hyphens, can be put on the certificate page on the WiDirect to update the certificate.