Certificates are used in the PayDirect API for request signing. You will need to generate 2 certificates as both differ in where they are used.
- A public key, to be uploaded to the Paydirect Settings page in our Console.
- A private key, to be used for signing requests, which you should not share with anyone outside your organization.
To generate both of these tickets, you will need software that uses TLS (Transport Layer Security) and SSL (Secure Socket Layer). Depending on your operating system, the library that you use may differ:
Operating System:
You may already have this installed on your device to check open a terminal and run the following command.
openssl version
If you do not have either of these libraries, please go to the official website and download the latest stable release. Once you have installed one of the above libraries, you can generate your certificates.
Generate a Private Key:
To generate a private key, you can run the following command in your laptops terminal:
openssl ecparam -genkey -name secp521r1 -noout -out ec512-private-key.pem
Generate a Public Key:
To generate a public key, you can run the following command in your laptops terminal:
openssl ec -in ec512-private-key.pem -pubout -out ec512-public-key.pem
Once both commands have been run, locate the following files and store them in a folder for future use.
Uploading your certificate
- You must give the certificate a unique name
- You must upload the public key that you created previously.
Comments
0 comments
Please sign in to leave a comment.