feat: Add support for HTTP/1.0 and HTTP/0.9#2577
Conversation
Signed-off-by: Lior Okman <lior.okman@sap.com>
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 <lior.okman@sap.com>
| 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.
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.
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.
What this PR does / why we need it:
This PR implements the API for enabling HTTP/1.0 and HTTP/0.9 (#2534)