Documentation
¶
Overview ¶
This package contains all the test scenarii that are part of the test suite. Each of them is executed in a separate connection. For executing scenarii, use the scripts in the bin/test_suite package.
When adding a new scenario, one should comply with the following requirements:
Its Name() must match its source code file without the extension. It must be registered in the GetAllScenarii() function. It must define an upper bound on its completion time. It should use the Timeout() function to achieve this.
Index ¶
- Constants
- func GetAllScenarii() map[string]Scenario
- type AbstractScenario
- func (s *AbstractScenario) CompleteHandshake(conn *qt.Connection, trace *qt.Trace, handshakeErrorCode uint8, ...) *agents.ConnectionAgents
- func (s *AbstractScenario) Finished()
- func (s *AbstractScenario) HTTP3() bool
- func (s *AbstractScenario) IPv6() bool
- func (s *AbstractScenario) Name() string
- func (s *AbstractScenario) SetTimer(d time.Duration)
- func (s *AbstractScenario) Timeout() <-chan time.Time
- func (s *AbstractScenario) Version() int
- type AckECNScenario
- type AckOnlyScenario
- type AddressValidationScenario
- type ClosedConnectionScenario
- type ConnectionMigrationScenario
- type ConnectionMigrationv4v6Scenario
- type FlowControlScenario
- type GetOnStream2Scenario
- type HTTP3EncoderStreamScenario
- type HTTP3GETScenario
- type HTTP3ReservedFramesScenario
- type HTTP3ReservedStreamsScenario
- type HTTP3UniStreamsLimitsScenario
- type HandshakeScenario
- type Handshakev6Scenario
- type KeyUpdateScenario
- type MultiPacketClientHello
- type MultiStreamScenario
- type NewConnectionIDScenario
- type PaddingScenario
- type RetireConnectionIDScenario
- type Scenario
- type ServerFlowControlScenario
- type SimpleGetAndWaitScenario
- type SpinBitScenario
- type StopSendingOnReceiveStreamScenario
- type StreamOpeningReorderingScenario
- type TransportParameterScenario
- type UnsupportedTLSVersionScenario
- type VersionNegotiationScenario
- type ZeroLengthCID
- type ZeroRTTScenario
Constants ¶
View Source
const ( AE_TLSHandshakeFailed = 1 AE_FailedToSetECN = 2 AE_NonECN = 3 AE_NoACKECNReceived = 4 AE_NonECNButACKECN = 5 )
View Source
const ( AO_TLSHandshakeFailed = 1 AO_SentAOInResponseOfAO = 2 )
View Source
const ( AV_TLSHandshakeFailed = 1 AV_SentMoreThan3Datagrams = 2 AV_SentMoreThan3TimesAmount = 3 AV_HostTimedOut = 4 )
View Source
const ( CCS_TLSHandshakeFailed = 1 CCS_NoPacketsReceived = 2 CSS_APacketWasReceived = 3 )
View Source
const ( CM_TLSHandshakeFailed = 1 CM_UDPConnectionFailed = 2 CM_HostDidNotMigrate = 3 CM_HostDidNotValidateNewPath = 4 CM_TooManyCIDs = 5 )
View Source
const ( CM46_TLSHandshakeFailed = 1 CM46_UDPConnectionFailed = 2 CM46_HostDidNotMigrate = 3 CM46_HostDidNotValidateNewPath = 4 CM46_NoNewCIDReceived = 5 CM46_NoNewCIDUsed = 6 CM46_MigrationIsDisabled = 7 CM46_NoCIDAllowed = 8 )
View Source
const ( FC_TLSHandshakeFailed = 1 FC_HostSentMoreThanLimit = 2 FC_HostDidNotResumeSending = 3 FC_NotEnoughDataAvailable = 4 FC_RespectedLimitsButNoBlocked = 5 // After discussing w/ the implementers, it is not reasonable to expect a STREAM_BLOCKED or a BLOCKED frame to be sent. // These frames should be sent to signal poor window size w.r.t. to the RTT FC_EndpointDoesNotSupportHQ = 6 )
View Source
const ( H_ReceivedUnexpectedPacketType = 1 H_TLSHandshakeFailed = 2 H_NoCompatibleVersionAvailable = 3 H_Timeout = 4 )
View Source
const ( H3ES_TLSHandshakeFailed = 1 H3ES_RequestTimeout = 2 H3ES_NotEnoughStreamsAvailable = 3 H3ES_SETTINGSNotSent = 4 )
View Source
const ( H3G_TLSHandshakeFailed = 1 H3G_RequestTimeout = 2 H3G_NotEnoughStreamsAvailable = 3 )
View Source
const ( H3RF_TLSHandshakeFailed = 1 H3RF_RequestTimeout = 2 H3RF_NotEnoughStreamsAvailable = 3 )
View Source
const ( H3RS_TLSHandshakeFailed = 1 H3RS_RequestTimeout = 2 H3RS_NotEnoughStreamsAvailable = 3 )
View Source
const ( H3USFC_TLSHandshakeFailed = 1 H3USFC_RequestTimeout = 2 H3USFC_NotEnoughStreamsAvailable = 3 H3USFC_StreamIDError = 4 )
View Source
const ( SGW_TLSHandshakeFailed = 1 SGW_EmptyStreamFrameNoFinBit = 2 SGW_RetransmittedAck = 3 // This could affect performance, but we don't check it anymore SGW_WrongStreamIDReceived = 4 SGW_UnknownError = 5 SGW_DidNotCloseTheConnection = 6 SGW_MultipleErrors = 7 SGW_TooLowStreamIdBidiToSendRequest = 8 SGW_DidntReceiveTheRequestedData = 9 SGW_AnsweredOnUnannouncedStream = 10 SGW_EndpointDoesNotSupportHQ = 11 )
View Source
const ( GS2_TLSHandshakeFailed = 1 GS2_TooLowStreamIdUniToSendRequest = 2 GS2_ReceivedDataOnStream2 = 3 GS2_AnswersToARequestOnAForbiddenStreamID = 5 // This is hard to disambiguate sometimes, we don't check anymore GS2_DidNotCloseTheConnection = 6 GS2_EndpointDoesNotSupportHQ = 7 )
View Source
const ( KU_TLSHandshakeFailed = 1 KU_HostDidNotRespond = 2 )
View Source
const ( MPCH_TLSHandshakeFailed = 1 MPCH_RequestFailed = 2 )
View Source
const ( MS_TLSHandshakeFailed = 1 MS_NoTPReceived = 2 // We don't distinguish the two first cases anymore MS_NotAllStreamsWereClosed = 3 )
View Source
const ( NCI_TLSHandshakeFailed = 1 NCI_HostDidNotProvideCID = 2 NCI_HostDidNotAnswerToNewCID = 3 NCI_HostDidNotAdaptCID = 4 NCI_HostSentInvalidCIDLength = 5 NCI_NoCIDAllowed = 6 )
View Source
const ( P_VNDidNotComplete = 1 P_ReceivedSmth = 2 )
View Source
const ( RCI_TLSHandshakeFailed = 1 RCI_HostDidNotProvideCID = 2 RCI_HostDidNotProvideNewCID = 3 RCI_HostSentInvalidCIDLength = 4 )
View Source
const ( SFC_TLSHandshakeFailed = 1 SFC_DidNotClose = 2 )
View Source
const ( SB_TLSHandshakeFailed = 1 SB_DoesNotSpin = 2 )
View Source
const ( SSRS_TLSHandshakeFailed = 1 SSRS_DidNotCloseTheConnection = 2 SSRS_CloseTheConnectionWithWrongError = 3 SSRS_MaxStreamUniTooLow = 4 SSRS_UnknownError = 5 )
View Source
const ( SOR_TLSHandshakeFailed = 1 SOR_HostDidNotRespond = 2 SOR_EndpointDoesNotSupportHQ = 3 )
View Source
const ( TP_NoTPReceived = 1 TP_TPResentAfterVN = 2 // All others error code are now handled by the handshake scenario TP_HandshakeDidNotComplete = 3 TP_MissingParameters = 4 // Since draft-15, there are no parameters that MUST be present )
View Source
const ( UTS_NoConnectionCloseSent = 1 UTS_WrongErrorCodeIsUsed = 2 // See https://tools.ietf.org/html/draft-ietf-quic-tls-10#section-11 UTS_VNDidNotComplete = 3 UTS_ReceivedUnexpectedPacketType = 4 )
View Source
const ( VN_NotAnsweringToVN = 1 VN_DidNotEchoVersion = 2 // draft-07 and below were stating that VN packets should echo the version of the client. It is not used anymore VN_LastTwoVersionsAreActuallySeal = 3 // draft-05 and below used AEAD to seal cleartext packets, VN packets should not be sealed, but some implementations did anyway. VN_Timeout = 4 VN_UnusedFieldIsIdentical = 5 // See https://github.com/quicwg/base-drafts/issues/963 )
View Source
const ( ZLCID_TLSHandshakeFailed = 1 ZLCID_RequestFailed = 2 )
View Source
const ( ZR_TLSHandshakeFailed = 1 ZR_NoResumptionSecret = 2 ZR_ZeroRTTFailed = 3 ZR_DidntReceiveTheRequestedData = 4 )
View Source
const ForceVersionNegotiation = 0x1a2a3a4a
Variables ¶
This section is empty.
Functions ¶
func GetAllScenarii ¶
Types ¶
type AbstractScenario ¶
type AbstractScenario struct {
// contains filtered or unexported fields
}
Each scenario should embed this structure
func (*AbstractScenario) CompleteHandshake ¶
func (s *AbstractScenario) CompleteHandshake(conn *qt.Connection, trace *qt.Trace, handshakeErrorCode uint8, additionalAgents ...agents.Agent) *agents.ConnectionAgents
Useful helper for scenarii that requires the handshake to complete before executing their test and don't want to discern the cause of its failure.
func (*AbstractScenario) Finished ¶
func (s *AbstractScenario) Finished()
func (*AbstractScenario) HTTP3 ¶
func (s *AbstractScenario) HTTP3() bool
func (*AbstractScenario) IPv6 ¶
func (s *AbstractScenario) IPv6() bool
func (*AbstractScenario) Name ¶
func (s *AbstractScenario) Name() string
func (*AbstractScenario) SetTimer ¶
func (s *AbstractScenario) SetTimer(d time.Duration)
func (*AbstractScenario) Timeout ¶
func (s *AbstractScenario) Timeout() <-chan time.Time
func (*AbstractScenario) Version ¶
func (s *AbstractScenario) Version() int
type AckECNScenario ¶
type AckECNScenario struct {
AbstractScenario
}
func NewAckECNScenario ¶
func NewAckECNScenario() *AckECNScenario
func (*AckECNScenario) Run ¶
func (s *AckECNScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type AckOnlyScenario ¶
type AckOnlyScenario struct {
AbstractScenario
}
func NewAckOnlyScenario ¶
func NewAckOnlyScenario() *AckOnlyScenario
func (*AckOnlyScenario) Run ¶
func (s *AckOnlyScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type AddressValidationScenario ¶
type AddressValidationScenario struct {
AbstractScenario
}
func NewAddressValidationScenario ¶
func NewAddressValidationScenario() *AddressValidationScenario
func (*AddressValidationScenario) Run ¶
func (s *AddressValidationScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ClosedConnectionScenario ¶
type ClosedConnectionScenario struct {
AbstractScenario
}
func NewClosedConnectionScenario ¶
func NewClosedConnectionScenario() *ClosedConnectionScenario
func (*ClosedConnectionScenario) Run ¶
func (s *ClosedConnectionScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ConnectionMigrationScenario ¶
type ConnectionMigrationScenario struct {
AbstractScenario
}
func NewConnectionMigrationScenario ¶
func NewConnectionMigrationScenario() *ConnectionMigrationScenario
func (*ConnectionMigrationScenario) Run ¶
func (s *ConnectionMigrationScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ConnectionMigrationv4v6Scenario ¶
type ConnectionMigrationv4v6Scenario struct {
AbstractScenario
}
func NewConnectionMigrationv4v6Scenario ¶
func NewConnectionMigrationv4v6Scenario() *ConnectionMigrationv4v6Scenario
func (*ConnectionMigrationv4v6Scenario) Run ¶
func (s *ConnectionMigrationv4v6Scenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type FlowControlScenario ¶
type FlowControlScenario struct {
AbstractScenario
}
func NewFlowControlScenario ¶
func NewFlowControlScenario() *FlowControlScenario
func (*FlowControlScenario) Run ¶
func (s *FlowControlScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type GetOnStream2Scenario ¶
type GetOnStream2Scenario struct {
AbstractScenario
}
func NewGetOnStream2Scenario ¶
func NewGetOnStream2Scenario() *GetOnStream2Scenario
func (*GetOnStream2Scenario) Run ¶
func (s *GetOnStream2Scenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HTTP3EncoderStreamScenario ¶
type HTTP3EncoderStreamScenario struct {
AbstractScenario
}
func NewHTTP3EncoderStreamScenario ¶
func NewHTTP3EncoderStreamScenario() *HTTP3EncoderStreamScenario
func (*HTTP3EncoderStreamScenario) Run ¶
func (s *HTTP3EncoderStreamScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HTTP3GETScenario ¶
type HTTP3GETScenario struct {
AbstractScenario
}
func NewHTTP3GETScenario ¶
func NewHTTP3GETScenario() *HTTP3GETScenario
func (*HTTP3GETScenario) Run ¶
func (s *HTTP3GETScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HTTP3ReservedFramesScenario ¶
type HTTP3ReservedFramesScenario struct {
AbstractScenario
}
func NewHTTP3ReservedFramesScenario ¶
func NewHTTP3ReservedFramesScenario() *HTTP3ReservedFramesScenario
func (*HTTP3ReservedFramesScenario) Run ¶
func (s *HTTP3ReservedFramesScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HTTP3ReservedStreamsScenario ¶
type HTTP3ReservedStreamsScenario struct {
AbstractScenario
}
func NewHTTP3ReservedStreamsScenario ¶
func NewHTTP3ReservedStreamsScenario() *HTTP3ReservedStreamsScenario
func (*HTTP3ReservedStreamsScenario) Run ¶
func (s *HTTP3ReservedStreamsScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HTTP3UniStreamsLimitsScenario ¶
type HTTP3UniStreamsLimitsScenario struct {
AbstractScenario
}
func NewHTTP3UniStreamsLimitsScenario ¶
func NewHTTP3UniStreamsLimitsScenario() *HTTP3UniStreamsLimitsScenario
func (*HTTP3UniStreamsLimitsScenario) Run ¶
func (s *HTTP3UniStreamsLimitsScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type HandshakeScenario ¶
type HandshakeScenario struct {
AbstractScenario
}
func NewHandshakeScenario ¶
func NewHandshakeScenario() *HandshakeScenario
func (*HandshakeScenario) Run ¶
func (s *HandshakeScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type Handshakev6Scenario ¶
type Handshakev6Scenario struct {
AbstractScenario
}
func NewHandshakev6Scenario ¶
func NewHandshakev6Scenario() *Handshakev6Scenario
func (*Handshakev6Scenario) Run ¶
func (s *Handshakev6Scenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type KeyUpdateScenario ¶
type KeyUpdateScenario struct {
AbstractScenario
}
func NewKeyUpdateScenario ¶
func NewKeyUpdateScenario() *KeyUpdateScenario
func (*KeyUpdateScenario) Run ¶
func (s *KeyUpdateScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type MultiPacketClientHello ¶
type MultiPacketClientHello struct {
AbstractScenario
}
func NewMultiPacketClientHello ¶
func NewMultiPacketClientHello() *MultiPacketClientHello
func (*MultiPacketClientHello) Run ¶
func (s *MultiPacketClientHello) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type MultiStreamScenario ¶
type MultiStreamScenario struct {
AbstractScenario
}
func NewMultiStreamScenario ¶
func NewMultiStreamScenario() *MultiStreamScenario
func (*MultiStreamScenario) Run ¶
func (s *MultiStreamScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type NewConnectionIDScenario ¶
type NewConnectionIDScenario struct {
AbstractScenario
}
func NewNewConnectionIDScenario ¶
func NewNewConnectionIDScenario() *NewConnectionIDScenario
func (*NewConnectionIDScenario) Run ¶
func (s *NewConnectionIDScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type PaddingScenario ¶
type PaddingScenario struct {
AbstractScenario
}
func NewPaddingScenario ¶
func NewPaddingScenario() *PaddingScenario
func (*PaddingScenario) Run ¶
func (s *PaddingScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type RetireConnectionIDScenario ¶
type RetireConnectionIDScenario struct {
AbstractScenario
}
func NewRetireConnectionIDScenario ¶
func NewRetireConnectionIDScenario() *RetireConnectionIDScenario
func (*RetireConnectionIDScenario) Run ¶
func (s *RetireConnectionIDScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ServerFlowControlScenario ¶
type ServerFlowControlScenario struct {
AbstractScenario
}
func NewServerFlowControlScenario ¶
func NewServerFlowControlScenario() *ServerFlowControlScenario
func (*ServerFlowControlScenario) Run ¶
func (s *ServerFlowControlScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type SimpleGetAndWaitScenario ¶
type SimpleGetAndWaitScenario struct {
AbstractScenario
}
func NewSimpleGetAndWaitScenario ¶
func NewSimpleGetAndWaitScenario() *SimpleGetAndWaitScenario
func (*SimpleGetAndWaitScenario) Run ¶
func (s *SimpleGetAndWaitScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type SpinBitScenario ¶
type SpinBitScenario struct {
AbstractScenario
}
func NewSpinBitScenario ¶
func NewSpinBitScenario() *SpinBitScenario
func (*SpinBitScenario) Run ¶
func (s *SpinBitScenario) Run(conn *Connection, trace *Trace, preferredPath string, debug bool)
type StopSendingOnReceiveStreamScenario ¶
type StopSendingOnReceiveStreamScenario struct {
AbstractScenario
}
func NewStopSendingOnReceiveStreamScenario ¶
func NewStopSendingOnReceiveStreamScenario() *StopSendingOnReceiveStreamScenario
func (*StopSendingOnReceiveStreamScenario) Run ¶
func (s *StopSendingOnReceiveStreamScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type StreamOpeningReorderingScenario ¶
type StreamOpeningReorderingScenario struct {
AbstractScenario
}
func NewStreamOpeningReorderingScenario ¶
func NewStreamOpeningReorderingScenario() *StreamOpeningReorderingScenario
func (*StreamOpeningReorderingScenario) Run ¶
func (s *StreamOpeningReorderingScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type TransportParameterScenario ¶
type TransportParameterScenario struct {
AbstractScenario
}
func NewTransportParameterScenario ¶
func NewTransportParameterScenario() *TransportParameterScenario
func (*TransportParameterScenario) Run ¶
func (s *TransportParameterScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type UnsupportedTLSVersionScenario ¶
type UnsupportedTLSVersionScenario struct {
AbstractScenario
}
func NewUnsupportedTLSVersionScenario ¶
func NewUnsupportedTLSVersionScenario() *UnsupportedTLSVersionScenario
func (*UnsupportedTLSVersionScenario) Run ¶
func (s *UnsupportedTLSVersionScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type VersionNegotiationScenario ¶
type VersionNegotiationScenario struct {
AbstractScenario
}
func NewVersionNegotiationScenario ¶
func NewVersionNegotiationScenario() *VersionNegotiationScenario
func (*VersionNegotiationScenario) Run ¶
func (s *VersionNegotiationScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ZeroLengthCID ¶
type ZeroLengthCID struct {
AbstractScenario
}
func NewZeroLengthCID ¶
func NewZeroLengthCID() *ZeroLengthCID
func (*ZeroLengthCID) Run ¶
func (s *ZeroLengthCID) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
type ZeroRTTScenario ¶
type ZeroRTTScenario struct {
AbstractScenario
}
func NewZeroRTTScenario ¶
func NewZeroRTTScenario() *ZeroRTTScenario
func (*ZeroRTTScenario) Run ¶
func (s *ZeroRTTScenario) Run(conn *qt.Connection, trace *qt.Trace, preferredPath string, debug bool)
Source Files
¶
- ack_ecn.go
- ack_only.go
- address_validation.go
- closed_connection.go
- connection_migration.go
- connection_migration_v4_v6.go
- flow_control.go
- handshake.go
- handshake_v6.go
- http3_encoder_stream.go
- http3_get.go
- http3_reserved_frames.go
- http3_reserved_streams.go
- http3_uni_streams_limits.go
- http_get_and_wait.go
- http_get_on_uni_stream.go
- key_update.go
- multi_packet_client_hello.go
- multi_stream.go
- new_connection_id.go
- padding.go
- retire_connection_id.go
- scenario.go
- server_flow_control.go
- spin_bit.go
- stop_sending_frame_on_receive_stream.go
- stream_opening_reordering.go
- transport_parameters.go
- unsupported_tls_version.go
- version_negotiation.go
- zero_length_cid.go
- zero_rtt.go
Click to show internal directories.
Click to hide internal directories.