-
Notifications
You must be signed in to change notification settings - Fork 381
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
feat: Add support for HTTP/1.0 and HTTP/0.9 #2577
Conversation
Signed-off-by: Lior Okman <[email protected]>
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #2577 +/- ##
==========================================
- Coverage 64.11% 64.04% -0.08%
==========================================
Files 119 119
Lines 18561 18627 +66
==========================================
+ Hits 11901 11930 +29
- Misses 5880 5912 +32
- Partials 780 785 +5 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Lior Okman <[email protected]>
if http1Settings.HTTP10 != nil { | ||
var defaultHost *string | ||
if ptr.Deref(http1Settings.HTTP10.UseDefaultHost, false) { | ||
for _, hostname := range httpIR.Hostnames { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
imo we should make this more strict - making sure a single hostname exists and it doesnt include a wildcard (even *.example.com should be rejected)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
making sure a single hostname exists and it doesnt include a wildcard (even *.example.com should be rejected)
It's already like this.
I couldn't find a way to create a test that defines a Gateway
resource which would translate to the Hostnames
array containing more than one entry at any time. Notice that the Gateway
resource doesn't allow providing more than one hostname per listener.
The code initializes the array so that it always contains exactly one entry - either the single value supported by the Listener
structure or a wildcard entry.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM thanks !
* feat: Add support for HTTP/1.0 and HTTP/0.9 Signed-off-by: Lior Okman <[email protected]> * Make the linter happy Signed-off-by: Lior Okman <[email protected]> --------- Signed-off-by: Lior Okman <[email protected]> Signed-off-by: Stéphane Cottin <[email protected]>
What this PR does / why we need it:
This PR implements the API for enabling HTTP/1.0 and HTTP/0.9 (#2534)