Convert TWINT certificate


Important: This step does not have to be carried out for the integration via mame.

To connect your shop(s) to TWINT you need a valid certificate which you can create and download on the page “Settings -> Order certificate from SwissSign”. Then it has to be converted into the correct format.

The downloaded certificate must be converted from file type .p12 to .pem. There are three different ways to do this (only one needs to be done):

 

1. Automatic conversion

This is the easiest way to convert the certificate. The certificate will be converted to the correct format by the plugin if the PHP extension OpenSSL is enabled on your web hosting. Simply use the upload button in the TWINT settings in WooCommerce after you have entered and saved the certificate password.

 

2. Conversion using the command line

If OpenSSL is not enabled on your web hosting you can convert the certificate and private key to the PEM format using a command line tool (e.g. Terminal on Mac):

openssl pkcs12 -in twint.p12 -out twint.pem -passout pass:PASSWORD

Replace twint.p12 with the name of your certificate (path) and PASSWORD with a password to encrypt the private key in the PEM file. You will then be asked for the password you created in the TWINT portal when you created the certificate.

You can then upload the certificate to the server in one of the following two ways:

  • Rename the converted .pem file to “twint.txt”(uploading PEM files is restricted be WordPress) and upload it by using the upload button in the TWINT settings in WooCommerce.
  • Upload the PEM file to the folder /wp-content/uploads/mame_twint of your WordPress installation (create the folder if it doesn’t exist). Please make sure that the file is named “twint.pem”.

 

3. Conversion using an online tool

Alternatively you can also use an online tool, e.g.:

https://www.sslshopper.com/ssl-converter.html

You can then upload the certificate to the server in one of the following two ways:

  • Rename the converted .pem file to “twint.txt” (uploading PEM files is restricted be WordPress) and upload it by using the upload button in the TWINT settings in WooCommerce.
  • Upload the PEM file to the folder /wp-content/uploads/mame_twint of your WordPress installation (create the folder if it doesn’t exist). Please make sure that the file is named “twint.pem”.