Connects a peer beginning the DTLS handshake using the underlying PacketPeerUDP which must be connected (see PacketPeerUDP.connectToHost). If validate_certs is true, PacketPeerDTLS will validate that the certificate presented by the remote peer and match it with the for_hostname argument. You can specify a custom X509Certificate to use for validation via the valid_certificate argument.
Disconnects this peer, terminating the DTLS session.
Returns the status of the connection. See status for values.
Poll the connection to check for incoming packets. Call this frequently to update the status and keep the connection working.
Construct a new instance of PacketPeerDTLS. Note: use memnew!PacketPeerDTLS instead.
DTLS packet peer.
This class represents a DTLS peer connection. It can be used to connect to a DTLS server, and is returned by DTLSServer.takeConnection. Warning: SSL/TLS certificate revocation and certificate pinning are currently not supported. Revoked certificates are accepted as long as they are otherwise valid. If this is a concern, you may want to use automatically managed certificates with a short validity period.