Skip to content
Myr

Disable HTTP/2 strict header validation (#637)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tom Christie · committed by GitHub · parent c337938 · Browse files · 1 file+3 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−1 removed

  • other:+3 added−1 removed

1 file+3 added−1 removed

modified:httpx/dispatch/http2.py+3 added-1 removed
1import typing23import h2.connection4import h2.events5from h2.config import H2Configuration6from h2.settings import SettingCodes, Settings78from ..concurrency.base import (9 BaseEvent,
11 unmodified lines
212223class HTTP2Connection(OpenConnection):24 READ_NUM_BYTES = 409625 CONFIG = H2Configuration(validate_inbound_headers=False)2627 def __init__(28 self,29 socket: BaseSocketStream,
2 unmodified lines
32 ):33 self.socket = socket34 self.backend = lookup_backend(backend)35 self.on_release = on_release34 self.state = h2.connection.H2Connection()36 self.state = h2.connection.H2Connection(config=self.CONFIG)3738 self.streams = {} # type: typing.Dict[int, HTTP2Stream]39 self.events = {} # type: typing.Dict[int, typing.List[h2.events.Event]]40
246 unmodified lines