Contents · Forum Home · StreamSec Tools 4.1.5.363 documentation

StreamSec.Http.Http2Frames

******************************************************************************

Feature notes: HTTPS application layer notes (HTTP/1.1, h2, h3)

Classes, interfaces and records

classEHttp2FrameError

inherits from Exception

(no public members)

recordtHttp2FrameHeader

Len : Cardinal;
24-bit payload length
FrameTyp: Byte; Flags : Byte; StreamID: Cardinal;
31-bit; the reserved bit is masked off on read

classtHttp2FrameReader

Accumulates inbound octets and yields whole frames. A frame whose declared length exceeds MaxFrameLen is reported as h2rError with cErrFrameSize BEFORE its payload is buffered, so a hostile length cannot force unbounded buffering.

constructor Create; procedure Push(aData: Pointer; aLen: Integer); function Next(out aHeader: tHttp2FrameHeader; out aPayload: TBytes; out aErrorCode: Cardinal): tHttp2ReadResult;
h2rFrame: aHeader/aPayload filled, frame consumed. h2rNone: need more bytes. h2rError: aErrorCode set (framing error); the caller must abort the connection.
property MaxFrameLen: Integer read fMaxFrameLen write fMaxFrameLen; property Pending: Integer read fLen;

Types (enumerations, sets, aliases)

enumtHttp2ReadResult

  tHttp2ReadResult = (h2rNone, h2rFrame, h2rError);

Routines