Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First byte timeout #3454

Open
DFINITYManu opened this issue Dec 1, 2023 · 1 comment
Open

First byte timeout #3454

DFINITYManu opened this issue Dec 1, 2023 · 1 comment
Labels
C-feature Category: feature. This is adding a new feature.

Comments

@DFINITYManu
Copy link

We have in hyper a HTTP1 header read timeout (which is strangely not available for HTTP?) and this works great... if the client sends at least one byte (or a newline?).

If the client never sends a single byte, and just holds the connection open, the timeout never triggers.

I suggest we either make the timeout trigger even when no bytes have been sent (make the timer start ticking the minute serve_connection() is called) or we introduce another field explicitly for first byte timeout.

This will harden hyper servers against clients who attempt to open and hog connections open without any intention of sending any data.

@DFINITYManu DFINITYManu added the C-feature Category: feature. This is adding a new feature. label Dec 1, 2023
@seanmonstar
Copy link
Member

Yes, several have indicated that a separate timeout makes sense: #3185 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature Category: feature. This is adding a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants