Skip to content

Commit

Permalink
[docs] Update links to RFCs and draft specifications.
Browse files Browse the repository at this point in the history
  • Loading branch information
jlaine committed Jul 17, 2022
1 parent 957552a commit cd54b92
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 18 deletions.
4 changes: 2 additions & 2 deletions src/aioquic/h3/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,15 @@ class Setting(IntEnum):
MAX_FIELD_SECTION_SIZE = 0x6
QPACK_BLOCKED_STREAMS = 0x7

# https://datatracker.ietf.org/doc/html/draft-ietf-httpbis-h3-websockets-02#section-5
# https://datatracker.ietf.org/doc/html/rfc9220#section-5
ENABLE_CONNECT_PROTOCOL = 0x8
# https://datatracker.ietf.org/doc/html/draft-ietf-masque-h3-datagram-05#section-9.1
H3_DATAGRAM = 0xFFD277
# https://datatracker.ietf.org/doc/html/draft-ietf-webtrans-http2-02#section-10.1
ENABLE_WEBTRANSPORT = 0x2B603742

# Dummy setting to check it is correctly ignored by the peer.
# https://tools.ietf.org/html/draft-ietf-quic-http-34#section-7.2.4.1
# https://datatracker.ietf.org/doc/html/rfc9114#section-7.2.4.1
DUMMY = 0x21


Expand Down
12 changes: 3 additions & 9 deletions src/aioquic/quic/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ class QuicLoggerTrace:
"""
A QUIC event trace.
Events are logged in the format defined by qlog draft-03.
Events are logged in the format defined by qlog.
See:
- https://datatracker.ietf.org/doc/html/draft-ietf-quic-qlog-main-schema
- https://datatracker.ietf.org/doc/html/draft-ietf-quic-qlog-main-schema-02
- https://datatracker.ietf.org/doc/html/draft-marx-quic-qlog-quic-events
- https://datatracker.ietf.org/doc/html/draft-marx-quic-qlog-h3-events
"""
Expand Down Expand Up @@ -280,13 +280,7 @@ def to_dict(self) -> Dict[str, Any]:

class QuicLogger:
"""
A QUIC event logger.
Serves as a container for traces in the format defined by qlog draft-03.
See:
- https://datatracker.ietf.org/doc/html/draft-marx-qlog-main-schema-03
- https://datatracker.ietf.org/doc/html/draft-marx-qlog-event-definitions-quic-h3-02
A QUIC event logger which stores traces in memory.
"""

def __init__(self) -> None:
Expand Down
12 changes: 6 additions & 6 deletions tests/test_crypto.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@

PROTOCOL_VERSION = QuicProtocolVersion.VERSION_1

# https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A.5
# https://datatracker.ietf.org/doc/html/rfc9001#appendix-A.5
CHACHA20_CLIENT_PACKET_NUMBER = 654360564
CHACHA20_CLIENT_PLAIN_HEADER = binascii.unhexlify("4200bff4")
CHACHA20_CLIENT_PLAIN_PAYLOAD = binascii.unhexlify("01")
CHACHA20_CLIENT_ENCRYPTED_PACKET = binascii.unhexlify(
"4cfe4189655e5cd55c41f69080575d7999c25a5bfb"
)

# https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A.2
# https://datatracker.ietf.org/doc/html/rfc9001#appendix-A.2
LONG_CLIENT_PACKET_NUMBER = 2
LONG_CLIENT_PLAIN_HEADER = binascii.unhexlify(
"c300000001088394c8f03e5157080000449e00000002"
Expand Down Expand Up @@ -79,7 +79,7 @@
"e221af44860018ab0856972e194cd934"
)

# https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A.3
# https://datatracker.ietf.org/doc/html/rfc9001#appendix-A.3
LONG_SERVER_PACKET_NUMBER = 1
LONG_SERVER_PLAIN_HEADER = binascii.unhexlify(
"c1000000010008f067a5502a4262b50040750001"
Expand Down Expand Up @@ -115,7 +115,7 @@ class CryptoTest(TestCase):
"""
Test vectors from:
https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A
https://datatracker.ietf.org/doc/html/rfc9001#appendix-A
"""

def create_crypto(self, is_client):
Expand All @@ -128,7 +128,7 @@ def create_crypto(self, is_client):
return pair

def test_derive_key_iv_hp(self):
# https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A.1
# https://datatracker.ietf.org/doc/html/rfc9001#appendix-A.1

# client
secret = binascii.unhexlify(
Expand All @@ -150,7 +150,7 @@ def test_derive_key_iv_hp(self):

@skipIf("chacha20" in SKIP_TESTS, "Skipping chacha20 tests")
def test_derive_key_iv_hp_chacha20(self):
# https://tools.ietf.org/html/draft-ietf-quic-tls-34#appendix-A.5
# https://datatracker.ietf.org/doc/html/rfc9001#appendix-A.5

# server
secret = binascii.unhexlify(
Expand Down
2 changes: 1 addition & 1 deletion tests/test_crypto_draft_29.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ class CryptoTest(TestCase):
"""
Test vectors from:
https://tools.ietf.org/html/draft-ietf-quic-tls-18#appendix-A
https://datatracker.ietf.org/doc/html/draft-ietf-quic-tls-18#appendix-A
"""

def create_crypto(self, is_client):
Expand Down

0 comments on commit cd54b92

Please sign in to comment.