The library exports DTLS version primitives (DTLS1Version, DTLS1u2Version, DTLSMinVersion, DTLSMaxVersion) and the docstrings on set_min_proto_version and set_max_proto_version list them as supported versions. But SSLContext creates every context with TLS_method(), and OpenSSL rejects DTLS version numbers on a TLS-method context — SSL_CTX_ctrl returns 0 and the setter raises.
Supporting DTLS would mean creating contexts with DTLS_method() when DTLS versions are requested. The version-range validation added in #142 also uses a numeric comparison that gives wrong results for DTLS, since DTLS version numbers decrease with protocol version (DTLS 1.0 = 0xFEFF, DTLS 1.2 = 0xFEFD).
The library exports DTLS version primitives (
DTLS1Version,DTLS1u2Version,DTLSMinVersion,DTLSMaxVersion) and the docstrings onset_min_proto_versionandset_max_proto_versionlist them as supported versions. ButSSLContextcreates every context withTLS_method(), and OpenSSL rejects DTLS version numbers on a TLS-method context —SSL_CTX_ctrlreturns 0 and the setter raises.Supporting DTLS would mean creating contexts with
DTLS_method()when DTLS versions are requested. The version-range validation added in #142 also uses a numeric comparison that gives wrong results for DTLS, since DTLS version numbers decrease with protocol version (DTLS 1.0 = 0xFEFF, DTLS 1.2 = 0xFEFD).