Skip to content

feat(ctp): add IgnoredUpgradeTypes to HTTP1Settings#8599

Merged
zirain merged 5 commits intoenvoyproxy:mainfrom
michalskalski:ms-http-11-upgrade
Apr 1, 2026
Merged

feat(ctp): add IgnoredUpgradeTypes to HTTP1Settings#8599
zirain merged 5 commits intoenvoyproxy:mainfrom
michalskalski:ms-http-11-upgrade

Conversation

@michalskalski
Copy link
Copy Markdown
Contributor

@michalskalski michalskalski commented Mar 26, 2026

What type of PR is this?

Feature - adds new API field and functionality

What this PR does / why we need it:

This PR adds support for ignoredUpgradeTypes in ClientTrafficPolicy.spec.http1, which allows Envoy to ignore HTTP/1.1 Upgrade requests instead of rejecting them with 403. This maps to Envoy's ignore_http_11_upgrade in https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#config-core-v3-http1protocoloptions

Use Case:

Clients like Apache HttpClient 5.4+ send RFC-2817 TLS upgrade headers (Upgrade: TLS/1.2, Connection: Upgrade) by default on HTTP/1.1 requests. Envoy rejects these with 403 as a security measure against HTTP smuggling. This field allows users to configure matchers for upgrade values that should be ignored rather than rejected.

Example usage:

apiVersion: gateway.envoyproxy.io/v1alpha1
kind: ClientTrafficPolicy
metadata:
  name: ignore-tls-upgrade
spec:
  targetRefs:
  - group: gateway.networking.k8s.io
    kind: Gateway
    name: eg
  http1:
    ignoredUpgradeTypes:
    - type: Prefix
      value: "TLS/"

Which issue(s) this PR fixes:

Fixes #7102

Release Notes: Yes

@michalskalski michalskalski requested a review from a team as a code owner March 26, 2026 10:48
@netlify
Copy link
Copy Markdown

netlify bot commented Mar 26, 2026

Deploy Preview for cerulean-figolla-1f9435 ready!

Name Link
🔨 Latest commit c81782e
🔍 Latest deploy log https://app.netlify.com/projects/cerulean-figolla-1f9435/deploys/69cc90440333da0008d31358
😎 Deploy Preview https://deploy-preview-8599--cerulean-figolla-1f9435.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.39%. Comparing base (4dcb964) to head (c81782e).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8599      +/-   ##
==========================================
- Coverage   74.41%   74.39%   -0.03%     
==========================================
  Files         243      243              
  Lines       38336    38345       +9     
==========================================
- Hits        28526    28525       -1     
- Misses       7814     7821       +7     
- Partials     1996     1999       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@michalskalski
Copy link
Copy Markdown
Contributor Author

/retest

**What type of PR is this?**

Feature - adds new API field and functionality

**What this PR does / why we need it**:

This PR adds support for `ignoreHTTP11Upgrade` in
`ClientTrafficPolicy.spec.http1`, which allows Envoy to ignore HTTP/1.1
Upgrade requests instead of rejecting them with 403. This maps to
Envoy's `ignore_http_11_upgrade` in https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#config-core-v3-http1protocoloptions

**Use Case**:

Clients like Apache HttpClient 5.4+ send RFC-2817 TLS upgrade
headers (`Upgrade: TLS/1.2`, `Connection: Upgrade`) by default on
HTTP/1.1 requests. Envoy rejects these with 403 as a security measure
against HTTP smuggling. This field allows users to configure matchers
for upgrade values that should be ignored rather than rejected.

**Example usage**:

```yaml
apiVersion: gateway.envoyproxy.io/v1alpha1
kind: ClientTrafficPolicy
metadata:
  name: ignore-tls-upgrade
spec:
  targetRefs:
  - group: gateway.networking.k8s.io
    kind: Gateway
    name: eg
  http1:
    ignoreHTTP11Upgrade:
    - type: Prefix
      value: "TLS/"
```

**Which issue(s) this PR fixes**:

Fixes envoyproxy#7102

Release Notes: Yes

Signed-off-by: Michal Skalski <michal@skalski.org>
Signed-off-by: Michal Skalski <michal@skalski.org>
Signed-off-by: Michal Skalski <michal@skalski.org>
@michalskalski
Copy link
Copy Markdown
Contributor Author

/retest

1 similar comment
@michalskalski
Copy link
Copy Markdown
Contributor Author

/retest

arkodg
arkodg previously approved these changes Mar 31, 2026
@arkodg arkodg requested review from a team March 31, 2026 15:58
@arkodg arkodg added this to the v1.8.0-rc.1 Release milestone Mar 31, 2026
Comment thread api/v1alpha1/clienttrafficpolicy_types.go Outdated
As reviewers pointed out this option is already in HTTP1Settings and
old name included redundant info.

Signed-off-by: Michal Skalski <michal@skalski.org>
@michalskalski michalskalski changed the title feat(ctp): add ignoreHTTP11Upgrade to HTTP1Settings feat(ctp): add IgnoredUpgradeTypes to HTTP1Settings Apr 1, 2026
@michalskalski
Copy link
Copy Markdown
Contributor Author

/retest

Signed-off-by: Isaac Wilson <isaac.wilson514@gmail.com>
Copy link
Copy Markdown
Contributor

@jukie jukie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@jukie jukie requested review from a team and arkodg April 1, 2026 03:27
@zirain zirain merged commit 990e720 into envoyproxy:main Apr 1, 2026
39 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support configurable ignore of HTTP/1.1 upgrades

4 participants