class

HT2::RapidResetProtection

Inherits Reference < Object

Protection against CVE-2023-44487 (Rapid Reset Attack) This attack involves rapidly creating and canceling HTTP/2 streams to exhaust server resources.

Constructors

new(config : Config = Config.new)
Source

Instance methods

banned?(connection_id : String) : Bool

Check if connection is banned

Source
config
Source
metrics

Get current metrics for monitoring

Source
record_data_received(stream_id : UInt32) : Nil

Record data received for stream

Source
record_headers_received(stream_id : UInt32) : Nil

Record headers received for stream

Source
record_stream_cancelled(stream_id : UInt32, connection_id : String) : Bool

Record stream cancellation (RST_STREAM)

Source
record_stream_closed(stream_id : UInt32) : Nil

Record normal stream closure

Source
record_stream_created(stream_id : UInt32, connection_id : String) : Bool

Record new stream creation

Source

Nested types