A PHP internals mailing list thread proposing DTLS (RFC 6347, the UDP counterpart of TLS) support in PHP's ext/openssl extension. The author has built a working proof-of-concept featuring a transport-agnostic Openssl\Dtls class using memory BIOs, enabling applications to drive datagram I/O themselves. This is motivated by WebRTC data channels, DTLS-SRTP, CoAP, and other protocols that multiplex DTLS with other traffic on a single UDP socket — something a simple stream wrapper cannot handle. The ext/openssl maintainer (Jakub) suggests also exposing a dtls:// stream wrapper similar to how tls:// sits atop tcp://. The author proposes both: a low-level engine for multiplexed cases and a dtls:// stream wrapper for the common single-socket case, built on the same core. API design feedback covers using OpenSSLCertificate/OpenSSLAsymmetricKey objects instead of PEM strings, enum vs integer constants for handshake states, and null vs false return semantics.

33m read timeFrom externals.io
Post cover image
162 Impressions