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

Support PROXY Protocol listener filter (1.7) #5119

Merged

Conversation

sam-heilbron
Copy link
Contributor

Backport of: solo-io#5117

Description

Support PROXY Protocol listener filter and ensure it is executed before the TLS inspector listener filter.

Context

https://www.envoyproxy.io/docs/envoy/latest/configuration/listeners/listener_filters/proxy_protocol.html

We previously relied on a now deprecated Envoy flag, use_proxy_proto defined on the Listener FilterChain: https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/listener/v3/listener_components.proto#config-listener-v3-filterchain.

SNI Context

Using the deprecated flag, the PROXY protocol listener filter is appended to the filter chain. However, we need the PROXY protocol listener filter to be executed before the TLS inspector filter. Since the PROXY protocol adds bytes to the beginning of the connection, the SNI will not be parsed correctly if the PROXY protocol listener filter is not executed first. Without SNI matching, you would get the wrong certificate, and traffic would drop.

Checklist:

  • I included a concise, user-facing changelog (for details, see https://github.com/solo-io/go-utils/tree/master/changelogutils) which references the issue that is resolved.
  • If I updated APIs (our protos) or helm values, I ran make -B install-go-tools generated-code to ensure there will be no code diff
  • I followed guidelines laid out in the Gloo Edge contribution guide
  • I opened a draft PR or added the work in progress label if my PR is not ready for review
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

@solo-changelog-bot
Copy link

Issues linked to changelog:
solo-io#5116

@github-actions github-actions bot added the keep pr updated signals bulldozer to keep pr up to date with base branch label Aug 5, 2021
@sam-heilbron sam-heilbron marked this pull request as ready for review August 5, 2021 01:47
@soloio-bulldozer soloio-bulldozer bot merged commit 317a238 into v1.7.x Aug 5, 2021
@soloio-bulldozer soloio-bulldozer bot deleted the backport/v1.7.x/proxy-protocol-listener-filter branch August 5, 2021 02:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
keep pr updated signals bulldozer to keep pr up to date with base branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants