PDComm.OpcUa.ClientOptions
Class
Security, identity and timing options for Client.Connect.
public sealed class ClientOptionsThe client trusts no server automatically: pass the server's certificate in ClientOptions.TrustedServerDer. The identity and trust inputs are copied during the call, so you can clear them afterwards. If the requested endpoint fails, the client does not fall back to SecurityPolicy.None.
Members
ClientOptions
Constructor
Initializes a new instance with default values.
public ClientOptions()AllowNone
Property
Gets whether SecurityPolicy.None may be used; it is rejected unless this is true.
public bool AllowNone { get; init; }ApplicationUri
Property
Gets the client's application URI; default urn:pdcomm:opcua:client.
public string ApplicationUri { get; init; }CertificateDer
Property
Gets the client's application instance certificate, DER-encoded; empty for none.
public byte[] CertificateDer { get; init; }Mode
Property
Gets the message security mode; default SecurityMode.SignAndEncrypt.
public SecurityMode Mode { get; init; }Policy
Property
Gets the security policy of the secure channel; default SecurityPolicy.Aes256Sha256RsaPss.
public SecurityPolicy Policy { get; init; }PrivateKeyPem
Property
Gets the private key of ClientOptions.CertificateDer, PEM-encoded; empty for none.
public byte[] PrivateKeyPem { get; init; }TimeoutMs
Property
Gets the timeout of each network exchange, in milliseconds; default 10000. DNS resolution is not covered.
public uint TimeoutMs { get; init; }TrustedServerDer
Property
Gets the server certificate to trust explicitly, DER-encoded; empty for none.
public byte[] TrustedServerDer { get; init; }UserSecretHeaderPolicyOnly
Property
Gets whether new RSA-encrypted user secrets omit their outer encryption algorithm URI, so that the authenticated security header selects the policy. Set it only when the server requires it; legacy-format tokens still carry the algorithm URI.
public bool UserSecretHeaderPolicyOnly { get; init; }