Skip to main content

Certificates for CODESYS and PLC

CODESYS supports the signing with X.509 certificates.

The certificates for encryption in CODESYS Development System or for communication with the PLC can be self-signed or CA-signed. Which certification level is used depends on the security demands. You can create certificates with special tools or in the CODESYS environment.

CA-signed certificates must be created by a trusted external Certification Authority (CA) or by a CA located at the operator's facility. To obtain a CA-signed certificate, you can send a self-generated certificate to a CA via a Certificate Signing Request (CSR) and then reinstall it on your computer or on the PLC.

Important

The CA uses the data from the CSR to create the X.509 certificate for the PLC. When signing the CSR, the transfer of the following "x509v3 extensions" from the CSR is required:

Key Usage, Extended Key Usage, Subject Alternative Name, each with the Critical flag.

You can create self-signed certificates yourself with your own private key, but they are not signed by a CA. When you create self-signed certificates in the CODESYS environment, you get help from dialogs and encryption wizards.

Tip

A self-signed certificate is useful for testing purposes or as a temporary solution until a CA-signed certificate is available.

Certificate management on the local Windows computer: Valid certificates for the encryption of a CODESYS project and for the exchange between the PLC and CODESYS Development System must be stored in the local Windows Certificate Store (certmgr) on your computer.

Tip

To install a certificate file from the local file system in the Windows Certificate Store, double-click the file in the file directory. Then the appropriate import wizard will help you.

Certificate management on the PLC is the responsibility of the system operator. For more information, see: Certificates of the PLC

The Security Screen provides an interface for certificate handling for the project as well as for the certificates required for communication with the PLC. In the case of communication between CODESYS and the PLC, the Security Screen provides an alternative to the corresponding commands in the PLC Shell of the device editor.