UA ANSI C Server Professional
1.4.0.285
|
Data Structures | |
struct | _OpcUa_PkiIdentity |
Holds all information about a certificate issuer or subject. More... | |
struct | _OpcUa_PkiCertificateInfo |
Holds all additional information of a certificate. More... | |
struct | _OpcUa_PkiCertificate |
Encapsulates an OpenSSL certificate. More... | |
struct | _OpcUa_PkiRsaKeyPair |
Encapsulates an OpenSSL key pair. More... | |
struct | _OpcUa_PkiCRL |
Encapsulates an OpenSSL Certificate Revocation List. More... | |
Typedefs | |
typedef struct _OpcUa_PkiIdentity | OpcUa_PkiIdentity |
Holds all information about a certificate issuer or subject. More... | |
typedef struct _OpcUa_PkiCertificateInfo | OpcUa_PkiCertificateInfo |
Holds all additional information of a certificate. More... | |
typedef struct _OpcUa_PkiCertificate | OpcUa_PkiCertificate |
Encapsulates an OpenSSL certificate. More... | |
typedef struct _OpcUa_PkiRsaKeyPair | OpcUa_PkiRsaKeyPair |
Encapsulates an OpenSSL key pair. More... | |
typedef struct _OpcUa_PkiCRL | OpcUa_PkiCRL |
Encapsulates an OpenSSL Certificate Revocation List. More... | |
Functions | |
OpcUa_StatusCode | UaServer_PkiCertificate_Create (OpcUa_PkiCertificate **a_ppCertificate, OpcUa_PkiCertificateInfo a_certificateInfo, OpcUa_PkiIdentity a_subject, OpcUa_PkiRsaKeyPair a_subjectKeyPair, OpcUa_PkiIdentity a_issuer, OpcUa_PkiRsaKeyPair a_issuerKeyPair) |
Creates a new certificate. More... | |
OpcUa_StatusCode | UaServer_PkiCertificate_Delete (OpcUa_PkiCertificate **a_ppCertificate) |
Deletes a certificate and frees it's memory. More... | |
OpcUa_StatusCode | UaServer_PkiCertificate_ToDERFile (OpcUa_PkiCertificate *a_pCertificate, OpcUa_StringA a_sFile) |
Writes the certificate to the given file. More... | |
OpcUa_StatusCode | UaServer_PkiCertificate_FromDER (OpcUa_ByteString *a_bsDER, OpcUa_PkiCertificate **a_ppCertificate) |
Gets a certificate from DER encoded ByteString. More... | |
OpcUa_StatusCode | UaServer_PkiCertificate_HasExtension (OpcUa_PkiCertificate *a_pCertificate, OpcUa_X509Extension a_extension, OpcUa_Boolean *a_pExtensionExists) |
Check if certificate has extension. More... | |
OpcUa_StatusCode | UaServer_PkiCertificate_GetExtension (OpcUa_PkiCertificate *a_pCertificate, OpcUa_X509Extension a_extension, OpcUa_String *a_pExtensionValue) |
Get extension from certificate. More... | |
OpcUa_StatusCode | UaServer_PkiRsaKeyPair_Create (OpcUa_PkiRsaKeyPair **a_ppKeyPair, OpcUa_Int32 a_iBits) |
Creates a new key pair. More... | |
OpcUa_StatusCode | UaServer_PkiRsaKeyPair_Delete (OpcUa_PkiRsaKeyPair **a_ppKeyPair) |
Deletes a key pair and frees it's memory. More... | |
OpcUa_StatusCode | UaServer_PkiRsaKeyPair_ToPEMFile (OpcUa_PkiRsaKeyPair *a_pKeyPair, OpcUa_StringA a_sFile) |
Writes the key pair to the given file. More... | |
OpcUa_StatusCode | UaServer_PkiCRL_Create (OpcUa_PkiCRL **a_ppCRL, OpcUa_UInt64 a_uValidity, OpcUa_PkiIdentity a_issuer, OpcUa_UInt64 a_uCrlNumber) |
Creates a new Certificate Revocation List. More... | |
OpcUa_StatusCode | UaServer_PkiCRL_Delete (OpcUa_PkiCRL **a_ppCRL) |
Deletes a Certificate Revocation List and frees it's memory. More... | |
OpcUa_StatusCode | UaServer_PkiCRL_AddRevoked (OpcUa_PkiCRL *a_pCRL, OpcUa_PkiCertificate a_certificate, OpcUa_DateTime a_revocationDate) |
Adds a certificate to the Certificate Revocation List. More... | |
OpcUa_StatusCode | UaServer_PkiCRL_Sign (OpcUa_PkiCRL *a_pCRL, OpcUa_PkiRsaKeyPair a_issuerKeyPair) |
Signs a Certificate Revocation List. More... | |
OpcUa_StatusCode | UaServer_PkiCRL_ToPEMFile (OpcUa_PkiCRL *a_pCRL, OpcUa_StringA a_sFile) |
Writes the Certificate Revocation List to the given file. More... | |
OpcUa_StatusCode | UaServer_Pki_CheckKeyPair (OpcUa_ByteString *a_pCertificate, OpcUa_ByteString *a_pPrivateKey) |
Check if a private key matches a certificate. More... | |
typedef struct _OpcUa_PkiCertificate OpcUa_PkiCertificate |
Encapsulates an OpenSSL certificate.
typedef struct _OpcUa_PkiCertificateInfo OpcUa_PkiCertificateInfo |
Holds all additional information of a certificate.
typedef struct _OpcUa_PkiCRL OpcUa_PkiCRL |
Encapsulates an OpenSSL Certificate Revocation List.
typedef struct _OpcUa_PkiIdentity OpcUa_PkiIdentity |
Holds all information about a certificate issuer or subject.
typedef struct _OpcUa_PkiRsaKeyPair OpcUa_PkiRsaKeyPair |
Encapsulates an OpenSSL key pair.
OpcUa_StatusCode UaServer_Pki_CheckKeyPair | ( | OpcUa_ByteString * | a_pCertificate, |
OpcUa_ByteString * | a_pPrivateKey | ||
) |
Check if a private key matches a certificate.
a_pCertificate | The certificate belonging to the private key. |
a_pPrivateKey | The private key belonging to the certificate. |
OpcUa_StatusCode UaServer_PkiCertificate_Create | ( | OpcUa_PkiCertificate ** | a_ppCertificate, |
OpcUa_PkiCertificateInfo | a_certificateInfo, | ||
OpcUa_PkiIdentity | a_subject, | ||
OpcUa_PkiRsaKeyPair | a_subjectKeyPair, | ||
OpcUa_PkiIdentity | a_issuer, | ||
OpcUa_PkiRsaKeyPair | a_issuerKeyPair | ||
) |
Creates a new certificate.
a_ppCertificate | A pointer to a variable to store the created certificate. |
a_certificateInfo | UA Application information. |
a_subject | The identity of the certificate owner. |
a_subjectKeyPair | The key pair of the certificate. The public key part will be stored in the certificate. |
a_issuer | The identity of the certificate issuer. |
a_issuerKeyPair | The key pair of the certificate issuer. This is needed to sign the certificate. |
OpcUa_StatusCode UaServer_PkiCertificate_Delete | ( | OpcUa_PkiCertificate ** | a_ppCertificate | ) |
Deletes a certificate and frees it's memory.
a_ppCertificate | A pointer to a variable that points to a OpcUa_PkiCertificate. |
OpcUa_StatusCode UaServer_PkiCertificate_FromDER | ( | OpcUa_ByteString * | a_bsDER, |
OpcUa_PkiCertificate ** | a_ppCertificate | ||
) |
Gets a certificate from DER encoded ByteString.
a_bsDER | The ByteString containing the DER encoded certificate. |
a_ppCertificate | The created certificate is stored here. |
OpcUa_StatusCode UaServer_PkiCertificate_GetExtension | ( | OpcUa_PkiCertificate * | a_pCertificate, |
OpcUa_X509Extension | a_extension, | ||
OpcUa_String * | a_pExtensionValue | ||
) |
Get extension from certificate.
a_pCertificate | The certificate to use. |
a_extension | The certificate extension to get. |
a_pExtensionValue | The value of the specified extension. |
OpcUa_StatusCode UaServer_PkiCertificate_HasExtension | ( | OpcUa_PkiCertificate * | a_pCertificate, |
OpcUa_X509Extension | a_extension, | ||
OpcUa_Boolean * | a_pExtensionExists | ||
) |
Check if certificate has extension.
a_pCertificate | The certificate to use. |
a_extension | The certificate extension to check for. |
a_pExtensionExists | True if the certificate contains the specified extension. |
OpcUa_StatusCode UaServer_PkiCertificate_ToDERFile | ( | OpcUa_PkiCertificate * | a_pCertificate, |
OpcUa_StringA | a_sFile | ||
) |
Writes the certificate to the given file.
a_pCertificate | The certificate to store. |
a_sFile | The file to store the certificate in. |
OpcUa_StatusCode UaServer_PkiCRL_AddRevoked | ( | OpcUa_PkiCRL * | a_pCRL, |
OpcUa_PkiCertificate | a_certificate, | ||
OpcUa_DateTime | a_revocationDate | ||
) |
Adds a certificate to the Certificate Revocation List.
a_pCRL | The CRL to use. |
a_certificate | The certificate to store in the CRL. |
a_revocationDate | The revocation date to set. |
OpcUa_StatusCode UaServer_PkiCRL_Create | ( | OpcUa_PkiCRL ** | a_ppCRL, |
OpcUa_UInt64 | a_uValidity, | ||
OpcUa_PkiIdentity | a_issuer, | ||
OpcUa_UInt64 | a_uCrlNumber | ||
) |
Creates a new Certificate Revocation List.
a_ppCRL | A pointer to a variable to store a pointer to the created CRL. |
a_uValidity | Time from now in seconds until a new CRL will be created. |
a_issuer | The issuer of the CRL. |
a_uCrlNumber | The consecutive number of the CRL. |
OpcUa_StatusCode UaServer_PkiCRL_Delete | ( | OpcUa_PkiCRL ** | a_ppCRL | ) |
Deletes a Certificate Revocation List and frees it's memory.
a_ppCRL | A pointer to a variable that points to a OpcUa_PkiCRL. |
OpcUa_StatusCode UaServer_PkiCRL_Sign | ( | OpcUa_PkiCRL * | a_pCRL, |
OpcUa_PkiRsaKeyPair | a_issuerKeyPair | ||
) |
Signs a Certificate Revocation List.
a_pCRL | The CRL to sign. |
a_issuerKeyPair | The key pair used to sign the CRL. |
OpcUa_StatusCode UaServer_PkiCRL_ToPEMFile | ( | OpcUa_PkiCRL * | a_pCRL, |
OpcUa_StringA | a_sFile | ||
) |
Writes the Certificate Revocation List to the given file.
a_pCRL | The CRL to store. |
a_sFile | The file to store the CRL in. |
OpcUa_StatusCode UaServer_PkiRsaKeyPair_Create | ( | OpcUa_PkiRsaKeyPair ** | a_ppKeyPair, |
OpcUa_Int32 | a_iBits | ||
) |
Creates a new key pair.
a_ppKeyPair | A pointer to a variable to store a pointer to the created key pair. |
a_iBits | RSA modulus (key size) which should be 1024, 2048 or 4096. |
OpcUa_StatusCode UaServer_PkiRsaKeyPair_Delete | ( | OpcUa_PkiRsaKeyPair ** | a_ppKeyPair | ) |
Deletes a key pair and frees it's memory.
a_ppKeyPair | A pointer to a variable that points to a OpcUa_PkiRsaKeyPair. |
OpcUa_StatusCode UaServer_PkiRsaKeyPair_ToPEMFile | ( | OpcUa_PkiRsaKeyPair * | a_pKeyPair, |
OpcUa_StringA | a_sFile | ||
) |
Writes the key pair to the given file.
a_pKeyPair | The key pair to store. |
a_sFile | The file to store the key pair in. |