116 references to PROTOCOL_ERROR
InMemory.FunctionalTests (75)
Http2\Http2ConnectionTests.cs (51)
1494
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
1509
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
1525
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
1541
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
1573
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
1588
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2534
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2550
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2640
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2674
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2691
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2707
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2771
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2791
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2807
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2892
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
2907
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3080
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.BadRequest_RequestLineTooLong);
3124
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3140
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3175
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3191
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3449
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3465
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3481
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3519
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3771
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
3778
[InlineData((int)(Http2SettingsParameter.SETTINGS_ENABLE_PUSH), 2, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3779
[InlineData((int)(Http2SettingsParameter.SETTINGS_ENABLE_PUSH), uint.MaxValue, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3782
[InlineData((int)(Http2SettingsParameter.SETTINGS_MAX_FRAME_SIZE), 0, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3783
[InlineData((int)(Http2SettingsParameter.SETTINGS_MAX_FRAME_SIZE), 1, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3784
[InlineData((int)(Http2SettingsParameter.SETTINGS_MAX_FRAME_SIZE), 16 * 1024 - 1, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3785
[InlineData((int)(Http2SettingsParameter.SETTINGS_MAX_FRAME_SIZE), 16 * 1024 * 1024, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3786
[InlineData((int)(Http2SettingsParameter.SETTINGS_MAX_FRAME_SIZE), uint.MaxValue, (int)(Http2ErrorCode.
PROTOCOL_ERROR
))]
3816
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4064
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4105
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4121
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4415
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4432
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4448
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4465
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4501
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4518
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4534
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4902
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4938
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
4955
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
5060
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
5082
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
5879
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
Http2\Http2StreamTests.cs (22)
40
await WaitForConnectionErrorAsync<Exception>(ignoreNonGoAwayFrames: false, 1, Http2ErrorCode.
PROTOCOL_ERROR
, "Malformed request: invalid headers.");
58
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.FormatHttp2ErrorMethodInvalid(""));
77
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.FormatHttp2ErrorMethodInvalid("Hello,World"));
447
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2ErrorConnectMustNotSendSchemeOrPath);
464
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
,
524
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
,
724
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
,
745
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
,
766
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
,
789
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.BadRequest_RequestLineTooLong);
1104
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorLessDataThanLength);
1129
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorLessDataThanLength);
1158
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorMoreDataThanLength);
1162
var expectedError = new Http2StreamErrorException(1, CoreStrings.Http2StreamErrorMoreDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);
1193
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorLessDataThanLength);
1197
var expectedError = new Http2StreamErrorException(1, CoreStrings.Http2StreamErrorLessDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);
1229
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorMoreDataThanLength);
1233
var expectedError = new Http2StreamErrorException(1, CoreStrings.Http2StreamErrorMoreDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);
1265
await WaitForStreamErrorAsync(1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.Http2StreamErrorLessDataThanLength);
1269
var expectedError = new Http2StreamErrorException(1, CoreStrings.Http2StreamErrorLessDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);
5833
expectedErrorCode: Http2ErrorCode.
PROTOCOL_ERROR
,
5854
Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.BadRequest_MalformedRequestInvalidHeaders);
Http2\Http2WebSocketTests.cs (2)
297
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.ConnectRequestsWithProtocolRequireSchemeAndPath);
317
await WaitForStreamErrorAsync(expectedStreamId: 1, Http2ErrorCode.
PROTOCOL_ERROR
, CoreStrings.ProtocolRequiresConnect);
Microsoft.AspNetCore.Server.Kestrel.Core (41)
Internal\Http2\Http2Connection.cs (29)
598
SetConnectionErrorCode(ConnectionEndReason.InvalidHttpVersion, Http2ErrorCode.
PROTOCOL_ERROR
);
613
throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorInvalidPreface, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidHandshake);
685
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdEven(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidStreamId);
695
Http2FrameType.PUSH_PROMISE => throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorPushPromiseReceived, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.UnexpectedFrame),
718
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorPaddingTooLong(_incomingFrame.Type), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidDataPadding);
767
return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdZero(_incomingFrame.Type), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidStreamId);
772
return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdNotZero(_incomingFrame.Type), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidStreamId);
778
return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorHeadersInterleaved(_incomingFrame.Type, _incomingFrame.StreamId, _currentHeadersStream.StreamId), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.UnexpectedFrame);
800
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorPaddingTooLong(_incomingFrame.Type), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidDataPadding);
805
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamSelfDependency(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.StreamSelfDependency);
831
throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorHeadersWithTrailersNoEndStream, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.MissingStreamEnd);
928
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamSelfDependency(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.StreamSelfDependency);
1057
: Http2ErrorCode.
PROTOCOL_ERROR
;
1147
throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorWindowUpdateIncrementZero, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidWindowUpdateSize);
1184
throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorContinuationWithNoHeaders, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.UnexpectedFrame);
1289
throw new Http2StreamErrorException(_currentHeadersStream.StreamId, CoreStrings.HttpErrorMissingMandatoryPseudoHeaderFields, Http2ErrorCode.
PROTOCOL_ERROR
);
1383
throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdle(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidStreamId);
1583
throw new Http2ConnectionErrorException(CoreStrings.BadRequest_HeadersExceedMaxTotalSize, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.MaxRequestHeadersTotalSizeExceeded);
1645
throw new Http2ConnectionErrorException(bre.Message, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.MaxRequestHeaderCountExceeded);
1650
throw new Http2ConnectionErrorException(bre.Message, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1654
throw new Http2ConnectionErrorException(CoreStrings.BadRequest_MalformedRequestInvalidHeaders, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1665
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorConnectionSpecificHeaderField, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1676
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorTrailerNameUppercase, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1680
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorHeaderNameUppercase, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1709
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorPseudoHeaderFieldAfterRegularHeaders, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1715
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorTrailersContainPseudoHeaderField, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1724
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorUnknownPseudoHeaderField, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1731
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorResponsePseudoHeaderField, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
1738
throw new Http2ConnectionErrorException(CoreStrings.HttpErrorDuplicatePseudoHeaderField, Http2ErrorCode.
PROTOCOL_ERROR
, ConnectionEndReason.InvalidRequestHeaders);
Internal\Http2\Http2Stream.cs (12)
269
ResetAndAbort(new ConnectionAbortedException(CoreStrings.ConnectRequestsWithProtocolRequireSchemeAndPath), Http2ErrorCode.
PROTOCOL_ERROR
);
278
ResetAndAbort(new ConnectionAbortedException(CoreStrings.Http2ErrorConnectMustNotSendSchemeOrPath), Http2ErrorCode.
PROTOCOL_ERROR
);
289
ResetAndAbort(new ConnectionAbortedException(CoreStrings.ProtocolRequiresConnect), Http2ErrorCode.
PROTOCOL_ERROR
);
305
CoreStrings.FormatHttp2StreamErrorSchemeMismatch(headerScheme, Scheme)), Http2ErrorCode.
PROTOCOL_ERROR
);
336
ResetAndAbort(new ConnectionAbortedException(CoreStrings.BadRequest_RequestLineTooLong), Http2ErrorCode.
PROTOCOL_ERROR
);
356
ResetAndAbort(new ConnectionAbortedException(CoreStrings.FormatHttp2ErrorMethodInvalid(_methodText)), Http2ErrorCode.
PROTOCOL_ERROR
);
364
ResetAndAbort(new ConnectionAbortedException(CoreStrings.FormatHttp2ErrorMethodInvalid(_methodText)), Http2ErrorCode.
PROTOCOL_ERROR
);
404
ResetAndAbort(new ConnectionAbortedException(CoreStrings.FormatBadRequest_InvalidHostHeader_Detail(hostText)), Http2ErrorCode.
PROTOCOL_ERROR
);
417
ResetAndAbort(new ConnectionAbortedException(CoreStrings.FormatHttp2StreamErrorPathInvalid(RawTarget)), Http2ErrorCode.
PROTOCOL_ERROR
);
456
ResetAndAbort(new ConnectionAbortedException(CoreStrings.FormatHttp2StreamErrorPathInvalid(RawTarget)), Http2ErrorCode.
PROTOCOL_ERROR
);
495
throw new Http2StreamErrorException(StreamId, CoreStrings.Http2StreamErrorMoreDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);
540
throw new Http2StreamErrorException(StreamId, CoreStrings.Http2StreamErrorLessDataThanLength, Http2ErrorCode.
PROTOCOL_ERROR
);