This article explains how to create and update a self-signed X.509 certificate for use in Configure My AS2 station.
NOTE: A self-signed certificate is a certificate that is signed with its own private key. If your trading partner requires a certificate that is signed by a Certificate Authority (CA), you will need to contact a CA directly to have them issue your organization a certificate.
Here are the steps to generate, share, and update a self-signed SSL certificate.
Use the following steps to generate a self-signed SSL certificate using the OpenSSL utility:
-
Run the below OpenSSL command to generate your private key and public certificate.
-
-newkey rsa:2048: Creates a 2048 bit RSA key for use with the certificate.
-
-x509: Creates a self-signed certificate.
-
-days: Determines the length of time in days that the certificate is being issued for. For a self-signed certificate, this value can be increased as necessary. "365" specifies that the certificate will be valid for 365 days.
-
-nodes: Creates a certificate that does not require a passphrase.
openssl req -newkey rsa:2048 -nodes -keyout domain.key -x509 -days 365 -out domain.cer
You will be prompted to add identifying information about your website or organization to the certificate. Since a self-signed certificate won’t be used publicly, this information isn’t necessary. If this certificate will be passed on to a certificate authority for signing, the information needs to be as accurate as possible.
Upon completion, the command creates two files: a private key (
domain.key), and a public certificate (domain.cer). The key and certificate are valid for 365 days. Back up your certificate and key in a secure place (such as LastPass or 1Password.)Here is an example of the output:
-
Select your AS2 connection and update the certificate and private key. When you use a universal AS2 connection, you must follow the procedure for each trading partner that you want to update.
-
In the left pane, select Resources > Connections.
-
From the Connectors page, select a specific connection to edit details.
-
In the Edit connection form, go to Configure my AS2 station section of the AS2 connection to update the
.keyand.cerfiles as follows:-
Copy and paste
.cerfile in X.509 Public certificate. -
Copy and paste
.keyfile in X.509 Private key.
Don’t update any other setting in Configure my AS2 station
-
-
Go to Configure partner AS2 station section to update the partner's AS2 public certificate. Copy and paste the content of the public certificate that has been shared by the partner in the Partner’s certificate setting.
Caution
While updating this certificate, you must also update the private key in X.509 Private key again because it’s encrypted and not visible during updates. If you don’t provide it, an empty private key would get updated that will break the integration.
Tip
In the universal AS2 connection, you can identify the right partner by looking at the Partner’s AS2 Identifier, which is unique per partner.
-
Save the connection.