Feature notes: Asynchronous QUIC server and HTTP/3 component
Owns a record-free TLS session, connection state and real packet ciphers. aHost must outlive this instance. Configure DNS, groups and ALPN through TLS before Start. Calls require external serialization and must not reenter this instance, including from TLS events. Callbacks only queue data or install keys; the pump supplies CRYPTO bytes after TLS returns.
Output buffers retain their shared read-only contract. PacketSent is a separate notification after actual transmission; protecting or dequeuing a packet does not discard Initial keys. OpenPacket authenticates before updating receive packet numbers or acting on reserved bits. The caller supplies framing, ACK/recovery, retransmission retention and close timers.
constructor Create(aHost: TsmStreamSecII; aRole: tQuicRole; aVersion: Cardinal; const aInitialDestinationID, aLocalParameters: TBytes; const aParameterContext: tQuicTransportParameterContext; aVersionPolicy: tQuicClientNegotiation = nil);
destructor Destroy; override;
procedure SetVersionPolicy(aPolicy: tQuicClientNegotiation);
procedure ApplyRetry(const aDestinationID: TBytes; const aContext: tQuicTransportParameterContext);
procedure ConfigureEarlyData(const aContext: TBytes);
procedure ConfigureEarlyPeerParameters(const aParameters: tQuicTransportParameters);
property EarlyDataOffered: Boolean read GetEarlyDataOffered;
property EarlyDataAccepted: Boolean read GetEarlyDataAccepted;
property EarlyDataRejected: Boolean read GetEarlyDataRejected;
property EarlyDataWindowOpen: Boolean read GetEarlyDataWindowOpen;
procedure Start;
procedure ReceiveCrypto(aLevel: tQuicEncryptionLevel; aOffset: UInt64; const aData: TBytes);
procedure ProcessCryptoInput;
procedure SynchronizeKeys;
procedure ReleaseSession;
procedure DetachDestroyedSession;
function TakeCryptoOutput(out aChunk: tQuicCryptoChunk): Boolean;
function ProtectPacket(aLevel: tQuicEncryptionLevel; const aHeader, aPayload: TBytes; aPacketNumber: UInt64; aPacketNumberOffset: Integer): TBytes;
function OpenPacket(aLevel: tQuicEncryptionLevel; const aPacket: TBytes; aPacketNumberOffset: Integer; out aHeader, aPayload: TBytes; out aPacketNumber: UInt64): Boolean;
function AuthenticatePacket(aLevel: tQuicEncryptionLevel; const aPacket: TBytes; aPacketNumberOffset: Integer; out aHeader, aPayload: TBytes; out aPacketNumber: UInt64): Boolean;
procedure SetKeyContext(aNowMicros, aPtoMicros: UInt64);
function RequestKeyUpdate: Boolean;
function KeyUpdateDeadline(out aDeadline: UInt64): Boolean;
procedure AckFrameValidated(const aFrame: tQuicFrame);
procedure PacketSent(aPacketNumber: UInt64; const aPayload: TBytes; aNowMicros: UInt64); overload;
procedure PacketSent(aLevel: tQuicEncryptionLevel); overload;
procedure ReceiveHandshakeDone;
property KeyUpdates: tQuicKeyUpdate read fKeyUpdates;
property TLS: TTLS_ContentLayer read fTLS;
property State: tQuicConnectionState read fState;