nopasaran.tools.http_2_socket_server.HTTP2SocketServer¶
- class nopasaran.tools.http_2_socket_server.HTTP2SocketServer(host: str, port: int)¶
Bases:
HTTP2SocketBase- __init__(host: str, port: int)¶
Methods
__init__(host, port)close()Close the HTTP/2 connection and clean up resources
receive_test_frames(test_frames)Wait for test frames with adaptive timeout
send_frames(frames)Send frames with GOAWAY checking after each frame
start([tls_enabled, ...])Start the HTTP/2 server
Wait for peer SETTINGS (preface).
Wait for peer SETTINGS ACK.
- close()¶
Close the HTTP/2 connection and clean up resources
- receive_test_frames(test_frames) str¶
Wait for test frames with adaptive timeout
- send_frames(frames)¶
Send frames with GOAWAY checking after each frame
- start(tls_enabled=False, connection_settings_server={}, cloudflare_origin=False)¶
Start the HTTP/2 server
- wait_for_preface()¶
Wait for peer SETTINGS (preface). Returns (event, msg, frames).
- wait_for_preface_ack()¶
Wait for peer SETTINGS ACK. Returns (event, msg).