28#ifndef LIBS2OPC_CLIENT_CONFIG_CUSTOM_H_
29#define LIBS2OPC_CLIENT_CONFIG_CUSTOM_H_
69 const char* productUri,
70 const char* defaultAppName,
71 const char* defaultAppNameLocale,
104 const char* clientKeyPath,
122 const unsigned char* clientCertificate,
124 const unsigned char* clientPrivateKey);
152 const char* endpointUrl,
187 const char* clientReverseEndpointUri);
202 uint32_t reqLifetime);
216 const char* serverCertPath);
232 size_t certificateNbBytes,
233 const unsigned char* serverCertificate);
250 const char* userPolicyId);
270 const char* userPolicyId,
271 const char* userName,
272 const char* password);
290 const char* userPolicyId,
291 const char* userCertPath,
292 const char* userKeyPath,
312 const char* userPolicyId,
313 size_t certificateNbBytes,
314 const unsigned char* userCertificate,
316 const unsigned char* userPrivateKey);
336 uintptr_t updateParam);
High level interface to configure an OPC UA client.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetServerCertificateFromBytes(SOPC_SecureConnection_Config *secConnConfig, size_t certificateNbBytes, const unsigned char *serverCertificate)
Defines the server certificate DER encoded bytes to be used to establish the secure connection.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetUserName(SOPC_SecureConnection_Config *secConnConfig, const char *userPolicyId, const char *userName, const char *password)
Defines the user authentication mode as username/password for the secure connection,...
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetUserX509FromPaths(SOPC_SecureConnection_Config *secConnConfig, const char *userPolicyId, const char *userCertPath, const char *userKeyPath, bool encrypted)
Defines the user authentication mode as X509 certificate for the secure connection,...
SOPC_SecureConnection_Config * SOPC_ClientConfigHelper_CreateSecureConnection(const char *userDefinedId, const char *endpointUrl, OpcUa_MessageSecurityMode secuMode, SOPC_SecurityPolicy_URI secuPolicy)
Creates a new secure channel configuration in client that shall be completed by using the functions b...
SOPC_ReturnStatus SOPC_ClientConfigHelper_SetKeyCertPairFromPath(const char *clientCertPath, const char *clientKeyPath, bool encrypted)
Sets asymmetrical certificate and key of client from file paths. Certificate files shall use DER form...
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetUserX509FromBytes(SOPC_SecureConnection_Config *secConnConfig, const char *userPolicyId, size_t certificateNbBytes, const unsigned char *userCertificate, size_t keyNbBytes, const unsigned char *userPrivateKey)
Sets asymmetrical certificate and key of user from byte arrays. Certificate shall be in DER format,...
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetServerCertificateFromPath(SOPC_SecureConnection_Config *secConnConfig, const char *serverCertPath)
Defines the server certificate DER file path to be used to establish the secure connection.
SOPC_ReturnStatus SOPC_ClientConfigHelper_GetSecureConnectionConfigs(size_t *nbScConfigs, SOPC_SecureConnection_Config ***scConfigArray)
Gets the configured secure connections array.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetReverseConnection(SOPC_SecureConnection_Config *secConnConfig, const char *clientReverseEndpointUri)
Sets the Secure Connection in reverse connection mode.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetReqLifetime(SOPC_SecureConnection_Config *secConnConfig, uint32_t reqLifetime)
Defines the lifetime requested to the server for this secure connection (symmetric keys renewal) A de...
SOPC_ReturnStatus SOPC_ClientConfigHelper_SetPreferredLocaleIds(size_t nbLocales, const char **localeIds)
Client configuration without XML.
SOPC_ReturnStatus SOPC_ClientConfigHelper_SetPKIprovider(SOPC_PKIProvider *pki)
Defines the PKI provider that will be in charge of validating certificates received by client.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetServerCertUpdateCb(SOPC_SecureConnection_Config *secConnConfig, SOPC_KeyCertPairUpdateCb *serverCertUpdateCb, uintptr_t updateParam)
Sets the callback to be called if the server certificate held by SOPC_CertHolder is updated at runtim...
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetExpectedEndpointsDescription(SOPC_SecureConnection_Config *secConnConfig, const OpcUa_GetEndpointsResponse *getEndpointsResponse)
Defines the Secure Connection expected EndpointsDescription from given GetEndpointsResponse....
SOPC_ReturnStatus SOPC_ClientConfigHelper_SetApplicationDescription(const char *applicationUri, const char *productUri, const char *defaultAppName, const char *defaultAppNameLocale, OpcUa_ApplicationType applicationType)
Defines client application description.
SOPC_ReturnStatus SOPC_SecureConnectionConfig_SetAnonymous(SOPC_SecureConnection_Config *secConnConfig, const char *userPolicyId)
Defines the user authentication mode as anonymous for the secure connection and set the associated us...
SOPC_ReturnStatus SOPC_ClientConfigHelper_SetKeyCertPairFromBytes(size_t certificateNbBytes, const unsigned char *clientCertificate, size_t keyNbBytes, const unsigned char *clientPrivateKey)
Sets asymmetrical certificate and key of client from byte arrays. Certificate shall be in DER format,...
High level interface to configure an OPC UA client and/or server.
SOPC_SecurityPolicy_URI
Enumerated values authorized for use with SOPC_EndpointConfig_AddSecurityConfig or SOPC_ClientConfigH...
Definition libs2opc_common_config.h:42
enum _OpcUa_ApplicationType OpcUa_ApplicationType
enum _OpcUa_MessageSecurityMode OpcUa_MessageSecurityMode
enum _SOPC_ReturnStatus SOPC_ReturnStatus
Common enumerations for S2OPC.
void SOPC_KeyCertPairUpdateCb(uintptr_t updateParam)
Type of the callback triggered on key / certificate update.
Definition sopc_key_cert_pair.h:46
The PKIProvider object for the Public Key Infrastructure.
Definition sopc_pki_struct_lib_internal.h:39
Structure representing a secure connection configuration (secure channel + session) which allow to es...
Definition sopc_user_app_itf.h:216
Definition sopc_types.h:2434