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

http: pathless CONNECT #11048

Merged
merged 5 commits into from
May 8, 2020
Merged

http: pathless CONNECT #11048

merged 5 commits into from
May 8, 2020

Conversation

alyssawilk
Copy link
Contributor

@alyssawilk alyssawilk commented May 4, 2020

Removing the synthetic path added to CONNECT requests theoretically completing Envoy CONNECT support.

Additional Description:

This has the side-effect of changing Envoy's default response to CONNECT requests from 403 (upgrade forbidden) to 404 (route not found) because without the path header, CONNECT request fail to match traditional route rules.

Risk Level: Medium (high for early CONNECT users, low otherwise)
Testing: Altered tests
Docs Changes: will un-hide in a follow-up
Release Notes: added
Runtime guard: envoy.reloadable_features.stop_faking_paths
Part of #1451 and #1630

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@alyssawilk
Copy link
Contributor Author

Hey @mattklein123 would like your thoughts on the behavioral change.

I was going to special case, and change the HCM "send upgrade rejected" response to happen if an upgrade failed (route match, no opgrade configured) or for CONNECT requests which had no route match, to preserve the existing behavior. I feel like 403 on connect is more clear than 404, and behavioral changes and runtime guards, yadda yadda.

I had second thoughts, because if we add more logic to the extensible connect matcher, it gets complicated to tell if the 404 is a connect rejection, or if a fancy extended connect matcher failed to match. Basically keeping the old behavior doesn't seem very future proof.

Wanted to get your take on which way to go, and I'll either runtime guard and add release notes and such, or special-case to preserve existing behavior, revert the test changes, and we'll have to remember to be careful if anyone extends the connect matcher.

@alyssawilk
Copy link
Contributor Author

Also I don't remember where we left off with our comfort with Pathless connect. I think the plan was to improve fuzzing and I think @asraa has done that so I think we're OK, but if you want more guards in place before this lands LMK

Copy link
Member

@mattklein123 mattklein123 left a comment

Choose a reason for hiding this comment

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

Wanted to get your take on which way to go, and I'll either runtime guard and add release notes and such, or special-case to preserve existing behavior, revert the test changes, and we'll have to remember to be careful if anyone extends the connect matcher.

IMO the 404 when we fail to match is more future proof, agreed. I wonder if we should be setting any access log codes and/or error reasons specific to these cases though to help with debugging? WDYT?

Also I don't remember where we left off with our comfort with Pathless connect. I think the plan was to improve fuzzing and I think @asraa has done that so I think we're OK, but if you want more guards in place before this lands LMK

If we feel comfortable with the fuzzing coverage I'm fine landing it.

source/common/http/http2/codec_impl.cc Show resolved Hide resolved
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@mattklein123
Copy link
Member

LGTM but needs a format fix.

/wait

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
mattklein123
mattklein123 previously approved these changes May 7, 2020
Copy link
Member

@mattklein123 mattklein123 left a comment

Choose a reason for hiding this comment

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

Awesome!

@mattklein123
Copy link
Member

/azp run envoy-presubmit

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mattklein123
Copy link
Member

/azp run envoy-presubmit

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@mattklein123
Copy link
Member

/retest

@repokitteh-read-only
Copy link

🔨 rebuilding ci/circleci: coverage (failed build)

🐱

Caused by: a #11048 (comment) was created by @mattklein123.

see: more, trace.

@mattklein123 mattklein123 merged commit 6aaad26 into envoyproxy:master May 8, 2020
@alyssawilk alyssawilk deleted the hostless branch August 27, 2020 16:33
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.

3 participants