]> git.ipfire.org Git - thirdparty/dnspython.git/commitdiff
Add RFC 8499 to the RFC list.
authorBob Halley <halley@dnspython.org>
Mon, 27 Nov 2023 22:41:31 +0000 (14:41 -0800)
committerBob Halley <halley@dnspython.org>
Mon, 27 Nov 2023 22:41:31 +0000 (14:41 -0800)
dns/query.py
doc/rfc.rst

index a5fc6023dd36c183bfa2c1d2d2a50f34c061c96b..a800a3e1d2961e670e1203b38501e07f283fb6e6 100644 (file)
@@ -869,7 +869,7 @@ def send_tcp(
         # copying the wire into tcpmsg is inefficient, but lets us
         # avoid writev() or doing a short write that would get pushed
         # onto the net
-        tcpmsg = len(what).to_bytes(2, 'big') + what
+        tcpmsg = len(what).to_bytes(2, "big") + what
     sent_time = time.time()
     _net_write(sock, tcpmsg, expiration)
     return (len(tcpmsg), sent_time)
@@ -1093,6 +1093,8 @@ def tls(
         ssl_context.minimum_version = ssl.TLSVersion.TLSv1_2
         if server_hostname is None:
             ssl_context.check_hostname = False
+        print("HAS_ALPN", ssl.HAS_ALPN)
+        ssl_context.set_alpn_protocols(["dot"])
 
     with _make_socket(
         af,
@@ -1103,6 +1105,7 @@ def tls(
     ) as s:
         _connect(s, destination, expiration)
         _tls_handshake(s, expiration)
+        print("ALPN", s.selected_alpn_protocol())
         send_tcp(s, wire, expiration)
         (r, received_time) = receive_tcp(
             s, expiration, one_rr_per_rrset, q.keyring, q.mac, ignore_trailing
index 9e98bfa640d3240dd2dd10b1e4b0fb0e3f6e047d..4c79847782ef8e67722f61417c08c8235ddd5888 100644 (file)
@@ -123,6 +123,9 @@ Misc RFCs
 `RFC 4343 <https://tools.ietf.org/html/rfc4343>`_
     Case-sensitivity clarification.
 
+`RFC 8499 <https://tools.ietf.org/html/rfc8499>`_
+    DNS Terminology.
+
 Additional Transport RFCs
 -------------------------