PLCnext API Documentation 23.6.0.37
Classes | Typedefs | Enumerations | Functions
Arp::System::Commons::Net Namespace Reference

Namespace for network specific classes, enumerations and functions. More...

Classes

class  IpAddress
 Unified representation for ip address schemes. More...
 
class  Socket
 Interface to realizes ethernet based communications. More...
 
class  TlsSocket
 
class  TlsSocket2
 Interface to realize TLS Connection over TCP More...
 

Typedefs

using TlsContextPtr = std::shared_ptr< TlsContext >
 

Enumerations

enum class  PollMode {
  None = 0 , Read = 1 , Write = 2 , Connect = 3 ,
  Accept = 4
}
 This enum is used to specifiy the poll mode of the <cref name="Socket::Poll" > operation. More...
 
enum class  SelectMode { Read = 0 , Write = 1 , Connect = 3 , Accept = 4 }
 Modes for Select call to check different data channels. More...
 
enum class  ShutdownMode { None = 0 , Read = 1 , Write = 2 , ReadWrite = 3 }
 This enum is used to specifiy the shutdown mode of the <cref name="Socket::Shutdown(ShutdownMode)" > operation. More...
 
enum class  SocketBlockingMode { None = 0 , Blocking = 1 , NoneBlocking = 2 }
 Supported blocking modes. More...
 
enum class  SocketDomain { None = 0 , Ipv4 = 1 , Ipv6 = 2 }
 Supported communication domains, selecting the protocol for communication. More...
 
enum class  SocketError {
  None = 0 , Any = -1 , Interrupted = (10000 + 4) , InvalidArgument = (10000 + 22) ,
  TooManyOpenSockets = (10000 + 24) , WouldBlock = (10000 + 35) , InProgress = (10000 + 36) , AlreadyInProgress = (10000 + 37) ,
  NotSocket = (10000 + 38) , DestinationAddressRequired = (10000 + 39) , MessageSize = (10000 + 40) , ProtoType = (10000 + 41) ,
  ProtocolOption = (10000 + 42) , ProtocolNotSupported = (10000 + 43) , SocketNotSupported = (10000 + 44) , OperationNotSupported = (10000 + 45) ,
  ProtocolFamilyNotSupported = (10000 + 46) , AddressFamilyNotSupported = (10000 + 47) , AddressAlreadyInUse = (10000 + 48) , AddressNotAvailable = (10000 + 49) ,
  NetworkDown = (10000 + 50) , NetworkUnreachable = (10000 + 51) , NetworkReset = (10000 + 52) , ConnectionAborted = (10000 + 53) ,
  ConnectionReset = (10000 + 54) , NoBufferSpaceAvailable = (10000 + 55) , IsConnected = (10000 + 56) , NotConnected = (10000 + 57) ,
  Shutdown = (10000 + 58) , TimedOut = (10000 + 60) , ConnectionRefused = (10000 + 61) , HostDown = (10000 + 64) ,
  HostUnreachable = (10000 + 65) , ProcessLimit = (10000 + 67) , SystemNotReady = (10000 + 91) , VersionNotSupported = (10000 + 92) ,
  NotInitialized = (10000 + 93) , Disconnecting = (10000 + 101) , HostNotFound = (10000 + 1001) , TryAgain = (10000 + 1002)
}
 Possible error codes for socket operation results. More...
 
enum class  SocketOptionName {
  SocketOptionReuseAddress = 0x0004 , SocketOptionKeepAlive = 0x0008 , SocketOptionBroadcast = 0x0020 , SocketOptionReceiveTimeout = 0x0200 ,
  SocketOptionSendTimeout = 0x0800 , SocketOptionNoDelay = 1
}
 Specifies socket options to be set by the application. Copied from Eclr Socket Adaption More...
 
enum class  SocketType { None = 0 , Tcp = 1 , Udp = 2 }
 Enumeration of supported socket types. More...
 
enum class  TlsAlertLevel { None = 0 , Warning = 1 , Fatal = 2 }
 This enum represents avaliable TLS alert Levels More...
 
enum class  TlsAlertType {
  None = 256 , CloseNotify = 0 , UnexpectedMessage = 10 , BadRecordMac = 20 ,
  DecryptionFailed = 21 , RecordOverflow = 22 , DecompressionFailure = 30 , HandshakeFailure = 40 ,
  NoCertificate = 41 , BadCertificate = 42 , UnsupportedCertificate = 43 , CertificateRevoked = 44 ,
  CertificateExpired = 45 , CertificateUnknown = 46 , IllegalParameter = 47 , UnknownCa = 48 ,
  AccessDenied = 49 , DecodeError = 50 , DecryptError = 51 , TooManyCidsRequested = 52 ,
  ExportRestriction = 60 , ProtocolVersion = 70 , InsufficientSecurity = 71 , InternalError = 80 ,
  InappropriateFallback = 86 , UserCanceled = 90 , NoRenegotiation = 100 , MissingExtension = 109 ,
  UnsupportedExtension = 110 , CertificateUnobtainable = 111 , UnrecognizedName = 112 , BadCertificateStatusResponse = 113 ,
  BadCertificateHashValue = 114 , UnknownPskIdentity = 115 , CertificateRequired = 116 , NoApplicationProtocol = 120
}
 This enum defines the TLS alert types More...
 
enum class  TlsOptions : uint32 {
  None = 0 , Default = (1 << 0) , EnableTlsv12 = (1 << 1) , EnableTlsv13 = (1 << 2) ,
  SupportSessionRenegotiation = (1 << 3) , CheckLeafCrl = (1 << 4) , CheckAllCrl = (1 << 5) , TrustPartialChain = (1 << 6)
}
 This enum is used to select different options for the TlsSocket class More...
 
enum class  TlsVerificationError {
  None = 0 , Ok = 1 , Unspecified = 2 , UnableToGetIssuerCert = 3 ,
  UnableToGetCrl = 4 , UnableToDecryptCertSignature = 5 , UnableToDecryptCrlSignature = 6 , UnableToDecodeIssuerPublicKey = 7 ,
  CertSignatureFailure = 8 , CrlSignatureFailure = 9 , CertNotYetValid = 10 , CertHasExpired = 11 ,
  CrlNotYetValid = 12 , CrlHasExpired = 13 , ErrorInCertNotBeforeField = 14 , ErrorInCertNotAfterField = 15 ,
  ErrorInCrlLastUpdateField = 16 , ErrorInCrlNextUpdateField = 17 , OutOfMem = 18 , DepthZeroSelfSignedCert = 19 ,
  SelfSignedCertInChain = 20 , UnableToGetIssuerCertLocally = 21 , UnableToVerifyLeafSignature = 22 , CertChainTooLong = 23 ,
  CertRevoked = 24 , InvalidCa = 25 , PathLengthExceeded = 26 , InvalidPurpose = 27 ,
  CertUntrusted = 28 , CertRejected = 29 , SubjectIssuerMismatch = 30 , AkidSkidMismatch = 31 ,
  AkidIssuerSerialMismatch = 32 , KeyusageNoCertsign = 33 , UnableToGetCrlIssuer = 34 , UnhandledCriticalExtension = 35 ,
  KeyusageNoCrlSign = 36 , UnhandledCriticalCrlExtension = 37 , InvalidNonCa = 38 , ProxyPathLengthExceeded = 39 ,
  KeyusageNoDigitalSignature = 40 , ProxyCertificatesNotAllowed = 41 , InvalidExtension = 42 , InvalidPolicyExtension = 43 ,
  NoExplicitPolicy = 44 , DifferentCrlScope = 45 , UnsupportedExtensionFeature = 46 , UnnestedResource = 47 ,
  PermittedViolation = 48 , ExcludedViolation = 49 , SubtreeMinmax = 50 , ApplicationVerification = 51 ,
  UnsupportedConstraintType = 52 , UnsupportedConstraintSyntax = 53 , UnsupportedNameSyntax = 54 , CrlPathValidationError = 55 ,
  PathLoop = 56 , SuiteBInvalidVersion = 57 , SuiteBInvalidAlgorithm = 58 , SuiteBInvalidCurve = 59 ,
  SuiteBInvalidSignatureAlgorithm = 60 , SuiteBLosNotAllowed = 61 , SuiteBCannotSignP384WithP256 = 62 , HostnameMismatch = 63 ,
  EmailMismatch = 64 , IpAddressMismatch = 65 , DaneNoMatch = 66 , EeKeyTooSmall = 67 ,
  CaKeyTooSmall = 68 , CaMdTooWeak = 69 , InvalidCall = 70 , StoreLookup = 71 ,
  NoValidScts = 72 , ProxySubjectNameViolation = 73 , OcspVerifyNeeded = 74 , OcspVerifyFailed = 75 ,
  OcspCertUnknown = 76 , SignatureAlgorithmMismatch = 77 , NoIssuerPublicKey = 78 , UnsupportedSignatureAlgorithm = 79 ,
  EcKeyExplicitParams = 80
}
 This enum list possible error codes which further specifies an certificate verification error. For details see: https://www.openssl.org/docs/man1.1.1/man1/verify.html and: https://www.openssl.org/docs/man3.1/man3/X509_STORE_CTX_get_error.html More...
 

Functions

std::ostream & operator<< (std::ostream &os, const IpAddress &ipAddress)
 The ostream operator is used for logging and string formatting.
 
std::istream & operator>> (std::istream &is, IpAddress &ipAddress)
 The istream operator is used for string parsing.
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, PollMode value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, PollMode &value)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, ShutdownMode value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, ShutdownMode &value)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, SocketError value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, SocketError &value)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, TlsAlertLevel value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, TlsAlertLevel &value)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, TlsAlertType value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, TlsAlertType &value)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, TlsOptions value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, TlsOptions &value)
 
constexpr TlsOptions operator& (TlsOptions lhs, TlsOptions rhs)
 
constexpr TlsOptions operator| (TlsOptions lhs, TlsOptions rhs)
 
TlsOptionsoperator&= (TlsOptions &lhs, TlsOptions rhs)
 
TlsOptionsoperator|= (TlsOptions &lhs, TlsOptions rhs)
 
TlsOptions operator~ (TlsOptions arg)
 
ARP_CXX_SYMBOL_EXPORT std::ostream & operator<< (std::ostream &os, TlsVerificationError value)
 
ARP_CXX_SYMBOL_EXPORT std::istream & operator>> (std::istream &is, TlsVerificationError &value)
 

Detailed Description

Namespace for network specific classes, enumerations and functions.

Enumeration Type Documentation

◆ PollMode

This enum is used to specifiy the poll mode of the <cref name="Socket::Poll" > operation.

Enumerator
None 

Not initialized.

Read 

Read operation should be polled.

Write 

Write operation should be polled.

Connect 

Connect operation should be polled.

Accept 

Accept operation should be polled.

◆ SelectMode

Modes for Select call to check different data channels.

Enumerator
Read 

Check if data is available for reading.

Write 

Check if data can be written to socket.

Connect 

Check if a connect request can be performed.

Accept 

Check if a connection request is pending.

◆ ShutdownMode

This enum is used to specifiy the shutdown mode of the <cref name="Socket::Shutdown(ShutdownMode)" > operation.

Enumerator
None 

Not initialized.

Read 

Read operations should be shut down.

Write 

Write operations should be shut down.

ReadWrite 

Read and write operations should be shut down.

◆ SocketBlockingMode

Supported blocking modes.

Enumerator
None 

Blocking mode is undefined.

Blocking 

Socket is in blocking mode, i.e. the Send*, Receive* and Accept methods will block if no data is available.

NoneBlocking 

Socket is in non-blocking mode, i.e. the Send*, Receive* and Accept methods will not block if no data is available.

◆ SocketDomain

Supported communication domains, selecting the protocol for communication.

Enumerator
None 

Undefined domain.

Ipv4 

Communication is based on internet protocol version 4.

Ipv6 

Communication is based on internet protocol version 6 (not supported yet).

◆ SocketError

Possible error codes for socket operation results.

Enumerator
None 

The Socket operation succeeded.

Any 

An unspecified Socket error has occurred.

Interrupted 

A blocking operation was interrupted.

InvalidArgument 

An invalid argument was supplied.

TooManyOpenSockets 

Too many open sockets.

WouldBlock 

A non-blocking socket operation could not be completed immediately.

InProgress 

A blocking operation is currently executing.

AlreadyInProgress 

An operation was attempted on a non-blocking socket that already had an operation in progress.

NotSocket 

An operation was attempted on something that is not a socket.

DestinationAddressRequired 

A required address was omitted from an operation on a socket.

MessageSize 

A message sent on a datagram socket was larger than the internal message buffer or some other network limit, or the buffer used to receive a datagram into was smaller than the datagram itself.

ProtoType 

A protocol was specified in the socket function call that does not support the semantics of the socket type requested.

ProtocolOption 

An unknown, invalid, or unsupported option or level was specified in a getsockopt or setsockopt call.

ProtocolNotSupported 

The requested protocol has not been configured into the system, or no implementation for it exists.

SocketNotSupported 

The support for the specified socket type does not exist in this address family.

OperationNotSupported 

The attempted operation is not supported for the type of object referenced.

ProtocolFamilyNotSupported 

The protocol family has not been configured into the system or no implementation for it exists.

AddressFamilyNotSupported 

An address incompatible with the requested protocol was used.

AddressAlreadyInUse 

Only one usage of each socket address (protocol/network address/port) is normally permitted.

AddressNotAvailable 

The requested address is not valid in its context.

NetworkDown 

A socket operation encountered a dead network.

NetworkUnreachable 

A socket operation was attempted to an unreachable network.

NetworkReset 

The connection has been broken due to keep-alive activity detecting a failure while the operation was in progress.

ConnectionAborted 

An established connection was aborted by the software in your host machine.

ConnectionReset 

An existing connection was forcibly closed by the remote host.

NoBufferSpaceAvailable 

An operation on a socket could not be performed because the system lacked sufficient buffer space or because a queue was full.

IsConnected 

A connect request was made on an already connected socket.

NotConnected 

A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied.

Shutdown 

A request to send or receive data was disallowed because the socket had already been shut down in that direction with a previous shutdown call.

TimedOut 

A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

ConnectionRefused 

No connection could be made because the target machine actively refused it.

HostDown 

A socket operation failed because the destination host was down.

HostUnreachable 

A socket operation was attempted to an unreachable host.

ProcessLimit 

A Sockets implementation may have a limit on the number of applications that may use it simultaneously.

SystemNotReady 

Startup cannot function at this time because the underlying system it uses to provide network services is currently unavailable.

VersionNotSupported 

The Sockets version requested is not supported.

NotInitialized 

Either the application has not called Startup, or Startup failed.

Disconnecting 

Returned by Recv or RecvFrom to indicate the remote party has initiated a graceful shutdown sequence.

HostNotFound 

No such host is known.

TryAgain 

This is usually a temporary error during host name resolution and means that the local server did not receive a response from an authoritative server.

◆ SocketOptionName

Specifies socket options to be set by the application. Copied from Eclr Socket Adaption

Enumerator
SocketOptionReuseAddress 

Allows the socket to be bound to an address that is already in use, values:

  • 0 means the reuse of addresses is disabled
  • 1 means the reuse of addresses is enabled
SocketOptionKeepAlive 

Send keep-alive signals, values:

  • 0 means the keep alive option is disabled
  • 1 means the keep alive option is enabled
SocketOptionBroadcast 

Permit sending broadcast messages on the socket, values:

  • 0 means broadcasting is disabled
  • 1 means broadcasting is enabled
SocketOptionReceiveTimeout 

Sets the receiving timeout until reporting an error. The Argument is a struct timeval

SocketOptionSendTimeout 

Sets the sending timeout until reporting an error. The Argument is a struct timeval

SocketOptionNoDelay 

Enables or disables the Nagle algorithm for send coalescing, values:

  • 0 means NoDelay is disabled, that is the nagle algorithm is enabled.
  • 1 means NoDelay is enabled, that is the nagle algorithm is disabled.

◆ SocketType

Enumeration of supported socket types.

Enumerator
None 

Undefined socket type.

Tcp 

Socket uses TCP protocol.

Udp 

Socket uses UDP protocol.

◆ TlsAlertLevel

This enum represents avaliable TLS alert Levels

see: https://www.rfc-editor.org/rfc/rfc8446#page-86

◆ TlsAlertType

This enum defines the TLS alert types

see: https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#tls-parameters-6

Enumerator
None 

Initialization value, should not be set in verify delegate

CloseNotify 

This alert notifies the recipient that the sender will not send any more messages on this connection.Any data received after a closure alert has been received MUST be ignored. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

UnexpectedMessage 

An inappropriate message (e.g., the wrong handshake message, premature Application Data, etc.) was received. This alert should never be observed in communication between proper implementations. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

BadRecordMac 

This alert is returned if a record is received which cannot be deprotected.Because AEAD algorithms combine decryption and verification, and also to avoid side - channel attacks, this alert is used for all deprotection failures.This alert should never be observed in communication between proper implementations, except when messages were corrupted in the network. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

DecryptionFailed 

This alert was used in some earlier versions of TLS, and may have permitted certain attacks against the CBC mode[CBCATT].It MUST NOT be sent by compliant implementations. RFC 5246: https://www.rfc-editor.org/rfc/rfc5246

RecordOverflow 

A TLSCiphertext record was received that had a length more than 2 ^ 14 + 256 bytes, or a record decrypted to a TLSPlaintext record with more than 2 ^ 14 bytes(or some other negotiated limit).This alert should never be observed in communication between proper implementations, except when messages were corrupted in the network. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

DecompressionFailure 

Only TLS 1.2 The decompression function received improper input (e.g., data that would expand to excessive length).This message is always fataland should never be observed in communication between proper implementations. RFC 5246: https://www.rfc-editor.org/rfc/rfc5246

HandshakeFailure 

Receipt of a "handshake_failure" alert message indicates that the sender was unable to negotiate an acceptable set of security parameters given the options available. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

NoCertificate 

This alert was used in SSLv3 but not any version of TLS. It MUST NOT be sent by compliant implementations. RFC 5246: https://www.rfc-editor.org/rfc/rfc5246

BadCertificate 

A certificate was corrupt, contained signatures that did not verify correctly, etc. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

UnsupportedCertificate 

A certificate was of an unsupported type. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

CertificateRevoked 

A certificate was revoked by its signer. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

CertificateExpired 

A certificate has expired or is not currently valid. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

CertificateUnknown 

Some other (unspecified) issue arose in processing the certificate, rendering it unacceptable. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

IllegalParameter 

A field in the handshake was incorrect or inconsistent with other fields.This alert is used for errors which conform to the formal protocol syntax but are otherwise incorrect. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

UnknownCa 

A valid certificate chain or partial chain was received, but the certificate was not accepted because the CA certificate could not be located or could not be matched with a known trust anchor. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

AccessDenied 

A valid certificate or PSK was received, but when access control was applied, the sender decided not to proceed with negotiation. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

DecodeError 

A message could not be decoded because some field was out of the specified range or the length of the message was incorrect.This alert is used for errors where the message does not conform to the formal protocol syntax.This alert should never be observed in communication between proper implementations, except when messages were corrupted in the network. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

DecryptError 

A handshake (not record layer) cryptographic operation failed, including being unable to correctly verify a signature or validate a Finished message or a PSK binder. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

TooManyCidsRequested 

Used by DTLS 1.3 see: RFC9147 Endpoints MAY handle an excessive number of RequestConnectionId messages by terminating the connection using a "too_many_cids_requested" alert. RFC 9147: https://www.rfc-editor.org/rfc/rfc9147

ExportRestriction 

This alert was used in some earlier versions of TLS. It MUST NOT be sent by compliant implementations. rfc5246

ProtocolVersion 

The protocol version the peer has attempted to negotiate is recognized but not supported. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

InsufficientSecurity 

Returned instead of "handshake_failure" when a negotiation has failed specifically because the server requires parameters more secure than those supported by the client. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

InternalError 

An internal error unrelated to the peer or the correctness of the protocol(such as a memory allocation failure) makes it impossible to continue. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

InappropriateFallback 

Sent by a server in response to an invalid connection retry attempt from a client(see[RFC7507]). RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

UserCanceled 

This alert notifies the recipient that the sender is canceling the handshake for some reason unrelated to a protocol failure.If a user cancels an operation after the handshake is complete, just closing the connection by sending a "close_notify" is more appropriate.This alert SHOULD be followed by a "close_notify".This alert generally has AlertLevel = warning. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

NoRenegotiation 

Sent by the client in response to a hello request or by the server in response to a client hello after initial handshaking. Either of these would normally lead to renegotiation; when that is not appropriate, the recipient should respond with this alert.At that point, the original requester can decide whether to proceed with the connection.One case where this would be appropriate is where a server has spawned a process to satisfy a request; the process might receive security parameters(key length, authentication, etc.) at startup, and it might be difficult to communicate changes to these parameters after that point.This message is always a warning. RFC 5246: https://www.rfc-editor.org/rfc/rfc5246

MissingExtension 

Sent by endpoints that receive a handshake message not containing an extension that is mandatory to send for the offered TLS version or other negotiated parameters. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

UnsupportedExtension 

Sent by endpoints receiving any handshake message containing an extension known to be prohibited for inclusion in the given handshake message, or including any extensions in a ServerHello or Certificate not first offered in the corresponding ClientHello or CertificateRequest. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

CertificateUnobtainable 

If a server is unable to obtain certificates in a given CertificateURL, it MUST send a fatal certificate_unobtainable(111) alert if it requires the certificates to complete the handshake.If the server does not require the certificates, then the server continues the handshake. RFC 6066: https://www.rfc-editor.org/rfc/rfc6066.html

UnrecognizedName 

Sent by servers when no server exists identified by the name provided by the client via the "server_name" extension (see[RFC6066]). RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

BadCertificateStatusResponse 

Sent by clients when an invalid or unacceptable OCSP response is provided by the server via the "status_request" extension(see[RFC6066]). RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

BadCertificateHashValue 

The server MUST check that the SHA-1 hash of the contents of the object retrieved from that URL(after decoding any MIME Content - Transfer - Encoding) matches the given hash.If any retrieved object does not have the correct SHA - 1 hash, the server MUST abort the handshake with a bad_certificate_hash_value(114) alert.This alert is always fatal. RFC 6066: https://www.rfc-editor.org/rfc/rfc6066.html

UnknownPskIdentity 

Sent by servers when PSK key establishment is desired but no acceptable PSK identity is provided by the client. Sending this alert is OPTIONAL; servers MAY instead choose to send a "decrypt_error" alert to merely indicate an invalid PSK identity. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

CertificateRequired 

Sent by servers when a client certificate is desired but none was provided by the client. RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

NoApplicationProtocol 

Sent by servers when a client "application_layer_protocol_negotiation" extension advertises only protocols that the server does not support(see[RFC7301]). RFC 8446: https://www.rfc-editor.org/rfc/rfc8446.html

◆ TlsOptions

This enum is used to select different options for the TlsSocket class

Default: A default of options is used: currently EnableTlsv12 and EnableTlsv13 are enabled (EnableTlsv12 | EnableTlsv13) EnableTlsv12: The TlsSocket supports the TLS v1.2 protocol version EnableTlsv13: The TlsSocket supports the TLS v1.3 protocol version SupportSessionRenegotiation: The TlsSocket supports session renegotiation (Only TLS v1.2 connections, since TLS v1.3 removed the support) CheckLeafCrl: The TlsSocket checks the CRL of the peer certificate if a TrustStore is configured CheckAllCrl: The TlsSocket checks the all CRL of the of the peer certificate chain if a TrustStore is configured TrustPartialChain: Normally only ca certificates are trusted. With this option TlsSocket and TlsSocket2 also trust intermediate or end entity certicates stored in the truststore Options can be combined (with |) since they are represented as bit flags

◆ TlsVerificationError

This enum list possible error codes which further specifies an certificate verification error. For details see: https://www.openssl.org/docs/man1.1.1/man1/verify.html and: https://www.openssl.org/docs/man3.1/man3/X509_STORE_CTX_get_error.html

Enumerator
None 

Initialization value, should not be set in verify delegate

Ok 

The operation was successful.

Unspecified 

Unspecified error; should not happen.

UnableToGetIssuerCert 

The issuer certificate of a looked up certificate could not be found. This normally means the list of trusted certificates is not complete.

UnableToGetCrl 

The CRL of a certificate could not be found.

UnableToDecryptCertSignature 

The certificate signature could not be decrypted. This means that the actual signature value could not be determined rather than it not matching the expected value, this is only meaningful for RSA keys.

UnableToDecryptCrlSignature 

The CRL signature could not be decrypted: this means that the actual signature value could not be determined rather than it not matching the expected value. Unused.

UnableToDecodeIssuerPublicKey 

The public key in the certificate SubjectPublicKeyInfo could not be read.

CertSignatureFailure 

The signature of the certificate is invalid.

CrlSignatureFailure 

The signature of the certificate is invalid.

CertNotYetValid 

The certificate is not yet valid: the notBefore date is after the current time.

CertHasExpired 

The certificate has expired: that is the notAfter date is before the current time.

CrlNotYetValid 

The CRL is not yet valid.

CrlHasExpired 

The CRL has expired.

ErrorInCertNotBeforeField 

The certificate notBefore field contains an invalid time.

ErrorInCertNotAfterField 

The certificate notAfter field contains an invalid time.

ErrorInCrlLastUpdateField 

The CRL lastUpdate field contains an invalid time.

ErrorInCrlNextUpdateField 

The CRL nextUpdate field contains an invalid time.

OutOfMem 

An error occurred trying to allocate memory. This should never happen.

DepthZeroSelfSignedCert 

The passed certificate is self-signed and the same certificate cannot be found in the list of trusted certificates.

SelfSignedCertInChain 

The certificate chain could be built up using the untrusted certificates but the root could not be found locally.

UnableToGetIssuerCertLocally 

The issuer certificate could not be found: this occurs if the issuer certificate of an untrusted certificate cannot be found.

UnableToVerifyLeafSignature 

No signatures could be verified because the chain contains only one certificate and it is not self signed.

CertChainTooLong 

The certificate chain length is greater than the supplied maximum depth. Unused.

CertRevoked 

The certificate has been revoked.

InvalidCa 

A CA certificate is invalid. Either it is not a CA or its extensions are not consistent with the supplied purpose.

PathLengthExceeded 

The basicConstraints pathlength parameter has been exceeded.

InvalidPurpose 

The supplied certificate cannot be used for the specified purpose.

CertUntrusted 

The root CA is not marked as trusted for the specified purpose.

CertRejected 

The root CA is marked to reject the specified purpose.

SubjectIssuerMismatch 

deprecated

AkidSkidMismatch 

deprecated

AkidIssuerSerialMismatch 

deprecated

KeyusageNoCertsign 

deprecated

UnableToGetCrlIssuer 

Unable to get CRL issuer certificate.

UnhandledCriticalExtension 

Unhandled critical extension.

KeyusageNoCrlSign 

Key usage does not include CRL signing.

UnhandledCriticalCrlExtension 

Unhandled critical CRL extension.

InvalidNonCa 

Invalid non-CA certificate has CA markings.

ProxyPathLengthExceeded 

Proxy path length constraint exceeded.

KeyusageNoDigitalSignature 

Key usage does not include digital signature.

ProxyCertificatesNotAllowed 

Proxy certificates not allowed

InvalidExtension 

Invalid or inconsistent certificate extension.

InvalidPolicyExtension 

Invalid or inconsistent certificate policy extension.

NoExplicitPolicy 

No explicit policy.

DifferentCrlScope 

Different CRL scope.

UnsupportedExtensionFeature 

Unsupported extension feature.

UnnestedResource 

RFC 3779 resource not subset of parent's resources.

PermittedViolation 

Permitted subtree violation.

ExcludedViolation 

Excluded subtree violation.

SubtreeMinmax 

Name constraints minimum and maximum not supported.

ApplicationVerification 

Application verification failure. Unused.

UnsupportedConstraintType 

Unsupported name constraint type.

UnsupportedConstraintSyntax 

Unsupported or invalid name constraint syntax.

UnsupportedNameSyntax 

Unsupported or invalid name syntax.

CrlPathValidationError 

CRL path validation error.

PathLoop 

Path loop.

SuiteBInvalidVersion 

Suite B: certificate version invalid.

SuiteBInvalidAlgorithm 

Suite B: invalid public key algorithm.

SuiteBInvalidCurve 

Suite B: invalid ECC curve.

SuiteBInvalidSignatureAlgorithm 

Suite B: invalid signature algorithm.

SuiteBLosNotAllowed 

Suite B: curve not allowed for this LOS.

SuiteBCannotSignP384WithP256 

Suite B: cannot sign P-384 with P-256.

HostnameMismatch 

Hostname mismatch.

EmailMismatch 

Email address mismatch.

IpAddressMismatch 

IP address mismatch.

DaneNoMatch 

DANE TLSA authentication is enabled, but no TLSA records matched the certificate chain. This error is only possible in s_client(1).

EeKeyTooSmall 

EE certificate key too weak.

CaKeyTooSmall 

CA certificate key too weak.

CaMdTooWeak 

CA signature digest algorithm too weak.

InvalidCall 

invalid certificate verification context.

StoreLookup 

Issuer certificate lookup error.

NoValidScts 

Certificate Transparency required, but no valid SCTs found.

ProxySubjectNameViolation 

Proxy subject name violation.

OcspVerifyNeeded 

Returned by the verify callback to indicate an OCSP verification is needed.

OcspVerifyFailed 

Returned by the verify callback to indicate OCSP verification failed.

OcspCertUnknown 

Returned by the verify callback to indicate that the certificate is not recognized by the OCSP responder.

SignatureAlgorithmMismatch 

The issuer's public key is not of the type required by the signature in the subject's certificate.

NoIssuerPublicKey 

The issuer certificate does not have a public key.

UnsupportedSignatureAlgorithm 
</summary> 
EcKeyExplicitParams 
</summary>