hyperium / h2

HTTP 2.0 client & server implementation for Rust.
MIT License
1.38k stars 278 forks source link

Return an error instead of panicking when stuck in a CONTINUATION loop #506

Closed eaufavor closed 3 years ago

eaufavor commented 3 years ago

A short term mitigation for https://github.com/hyperium/h2/issues/485.

It is not rare a large header can trigger such a CONTINUATION loop. While the stream cannot recover from this issue, returning an error instead of panicking makes the impact radius under better control.

eaufavor commented 3 years ago

30ca83279056390bab51358844ab5a975b49d640 the refactor breaks it. I will update soon

seanmonstar commented 3 years ago

Yea I just noticed I did the merge wrong, sorry!

seanmonstar commented 3 years ago

I fixed up the conflict and merged in https://github.com/hyperium/h2/commit/11229702a03626ca1463f9216d7511616711acc7. Thanks!