diff options
author | Yang Gao <yangg@google.com> | 2015-04-29 12:26:00 -0700 |
---|---|---|
committer | Yang Gao <yangg@google.com> | 2015-04-29 12:26:00 -0700 |
commit | 1685d773ef81420bf747c6988a2ad9baefd126fa (patch) | |
tree | 1d98532d79c3cb93f1fb20148e769f965759aa9f | |
parent | 50f7b87beca2cd19ec2953eacd3dde2373c9e3db (diff) | |
parent | 8a5bce35419abd3d0b51498afcdd091b39683930 (diff) |
Merge pull request #1406 from ctiller/crash-boom-bang
Incoming stream id validation fixes
-rw-r--r-- | src/core/transport/chttp2_transport.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/transport/chttp2_transport.c b/src/core/transport/chttp2_transport.c index 26c550c1f1..3ae693176e 100644 --- a/src/core/transport/chttp2_transport.c +++ b/src/core/transport/chttp2_transport.c @@ -1392,7 +1392,10 @@ static int init_header_frame_parser(transport *t, int is_continuation) { gpr_log(GPR_ERROR, "ignoring out of order new stream request on server; last stream " "id=%d, new stream id=%d", - t->last_incoming_stream_id, t->incoming_stream); + t->last_incoming_stream_id, t->incoming_stream_id); + return init_skip_frame(t, 1); + } else if ((t->incoming_stream_id & 1) == 0) { + gpr_log(GPR_ERROR, "ignoring stream with non-client generated index %d", t->incoming_stream_id); return init_skip_frame(t, 1); } t->incoming_stream = NULL; |