S2OPC OPCUA Toolkit
Data Fields
SOPC_LibSub_ConnectionCfg Struct Reference

Connection configuration to a remote OPC server. More...

#include <libs2opc_client.h>

Data Fields

uint32_t reverse_config_idx
 
SOPC_LibSub_CstString server_uri
 
SOPC_LibSub_CstString server_url
 
SOPC_LibSub_CstString security_policy
 
OpcUa_MessageSecurityMode security_mode
 
uint8_t disable_certificate_verification
 
SOPC_LibSub_CstString path_cert_auth
 
SOPC_LibSub_CstString path_crl
 
SOPC_LibSub_CstString path_cert_srv
 
SOPC_LibSub_CstString path_cert_cli
 
SOPC_LibSub_CstString path_key_cli
 
SOPC_LibSub_CstString policyId
 
SOPC_LibSub_CstString username
 
SOPC_LibSub_CstString password
 
SOPC_LibSub_CstString path_cert_x509_token
 
SOPC_LibSub_CstString path_key_x509_token
 
bool key_x509_token_encrypted
 
int64_t publish_period_ms
 
uint32_t n_max_keepalive
 
uint32_t n_max_lifetime
 
SOPC_LibSub_DataChangeCbkdata_change_callback
 
int64_t timeout_ms
 
uint32_t sc_lifetime
 
uint16_t token_target
 
SOPC_LibSub_EventCbkgeneric_response_callback
 
const void * expected_endpoints
 

Detailed Description

Connection configuration to a remote OPC server.

Deprecated:
This type is deprecated since version 1.5.0 and will be removed in version 1.6.0.

Field Documentation

◆ reverse_config_idx

SOPC_LibSub_ConnectionCfg::reverse_config_idx

If the reverse connection mechanism shall be used, it shall be set with the index of the reverse endpoint configuration. Otherwise it shall be set to 0.

◆ server_uri

SOPC_LibSub_ConnectionCfg::server_uri

Zero-terminated string defining server application URI

◆ server_url

SOPC_LibSub_ConnectionCfg::server_url

Zero-terminated string defining the server endpoint URL

◆ security_policy

SOPC_LibSub_ConnectionCfg::security_policy

The chosen OPC-UA security policy for the connection, one of the SOPC_SecurityPolicy_*_URI string

◆ security_mode

SOPC_LibSub_ConnectionCfg::security_mode

The chosen OPC-UA security mode for the connection, one of the OpcUa_MessageSecurityMode constant

◆ disable_certificate_verification

SOPC_LibSub_ConnectionCfg::disable_certificate_verification

Uses a PKIProvider which does not verify the certificates against a certificate authority. Setting this flag to not 0 severely harms security. The certificate authority is not required in this case. Other certificates are still required when using an encrypted or signed secure channel.

◆ path_cert_auth

SOPC_LibSub_ConnectionCfg::path_cert_auth

Zero-terminated path to the root certificate authority in the DER format

◆ path_crl

SOPC_LibSub_ConnectionCfg::path_crl

Zero-terminated path to the certificate revocation list in the DER format

◆ path_cert_srv

SOPC_LibSub_ConnectionCfg::path_cert_srv

Zero-terminated path to the server certificate in the DER format, signed by the root certificate authority

◆ path_cert_cli

SOPC_LibSub_ConnectionCfg::path_cert_cli

Zero-terminated path to the client certificate in the DER format, signed by the root certificate authority

◆ path_key_cli

SOPC_LibSub_ConnectionCfg::path_key_cli

Zero-terminated path to the client private key which is paired to the public key signed server certificate, in the DER format

◆ policyId

SOPC_LibSub_ConnectionCfg::policyId

Zero-terminated policy id. To know which policy id to use, please read a GetEndpointsResponse or a CreateSessionResponse. AnonymousIdentityToken is used when:

  • username, path_cert_x509_token and path_key_x509_token is NULL
  • the policy id must correspond to an anonymous UserIdentityPolicy UserNameIdentityToken is used when:
  • username is not NULL
  • the policy id must correspond to an username UserIdentityPolicy X509IdentityToken is used when:
  • username is NULL, path_cert_x509_token and path_key_x509_token is not NULL
  • the policy id must correspond to a certificate UserIdentityPolicy

◆ username

SOPC_LibSub_ConnectionCfg::username

Zero-terminated username, NULL for anonymous or certificate access, see policyId

◆ password

SOPC_LibSub_ConnectionCfg::password

Zero-terminated password, ignored when username is NULL. Password is kept in memory for future reconnections.

◆ path_cert_x509_token

SOPC_LibSub_ConnectionCfg::path_cert_x509_token

Zero-terminated path to the x509 certificate, NULL for anonymous access, see policyId

◆ path_key_x509_token

SOPC_LibSub_ConnectionCfg::path_key_x509_token

Zero-terminated path to the x509 private key, NULL for anonymous access, see policyId

◆ key_x509_token_encrypted

bool SOPC_LibSub_ConnectionCfg::key_x509_token_encrypted

◆ publish_period_ms

SOPC_LibSub_ConnectionCfg::publish_period_ms

The requested publish period for the created subscription (in milliseconds)

◆ n_max_keepalive

SOPC_LibSub_ConnectionCfg::n_max_keepalive

The max keep alive count for the subscription. When there is no notification to send, the subscription waits at most the number of publish cycle before sending a publish response (which is then empty).

◆ n_max_lifetime

SOPC_LibSub_ConnectionCfg::n_max_lifetime

The max number of time that a subscription may timeout its publish cycle without being able to send a response (because there is no publish request to answer to). In this case, the subscription is killed by the server. A large value is recommended (e.g. 1000).

◆ data_change_callback

SOPC_LibSub_ConnectionCfg::data_change_callback

The callback for data change notification

◆ timeout_ms

SOPC_LibSub_ConnectionCfg::timeout_ms

Connection timeout (milliseconds)

◆ sc_lifetime

SOPC_LibSub_ConnectionCfg::sc_lifetime

Time before secure channel renewal (milliseconds). A parameter larger than 60000 is recommended.

◆ token_target

SOPC_LibSub_ConnectionCfg::token_target

Number of tokens (PublishRequest) that the client tries to maintain throughout the connection

◆ generic_response_callback

SOPC_LibSub_ConnectionCfg::generic_response_callback

The callback used to transmit generic responses to request passed through SOPC_LibSub_AsyncSendRequestOnSession.

◆ expected_endpoints

SOPC_LibSub_ConnectionCfg::expected_endpoints

Response returned by prior call to GetEndpoints service and checked to be the same during session establishment, NULL otherwise (no verification will be done). Its type shall be a pointer of OpcUa_GetEndpointsResponse.


The documentation for this struct was generated from the following file: