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

httpcaddyfile: Improve detection of indistinguishable TLS automation policies #5120

Merged
merged 7 commits into from Oct 13, 2022

Conversation

mholt
Copy link
Member

@mholt mholt commented Oct 5, 2022

This is a somewhat experimental / WIP branch.

The problem is we have listener plugins that provide their own TLS, and we shouldn't be preventing a valid config from being produced. I think the assumptions made in this part of the code were too bold, and we need to relax them slightly now.

Initial change is a bit of a hack, but seems valid too. If auto_https off is used, we don't even use httpsHostsSharedWithHostlessKey so we can skip the count which yields an error sometimes when it shouldn't.

@mholt mholt added in progress 🏃‍♂️ Being actively worked on do not merge ⛔ Not ready yet! labels Oct 5, 2022
@mholt mholt added this to the v2.6.2 milestone Oct 5, 2022
@mholt mholt self-assigned this Oct 5, 2022
@mholt mholt removed the do not merge ⛔ Not ready yet! label Oct 13, 2022
Add comments to try to explain what happened
@mholt mholt removed the in progress 🏃‍♂️ Being actively worked on label Oct 13, 2022
@mholt mholt merged commit 6bad878 into master Oct 13, 2022
@mholt
Copy link
Member Author

mholt commented Oct 13, 2022

Ok, I think this change is pretty good overall. It removes some unnecessary (and necessarily incorrect) checks, tweaks tests to hopefully improve their likelihood of passing (sigh, that race condition), updates a dependency (unrelated but accidentally snuck into this PR instead of a separate branch), and fixes HTTP/3 listening when the network type is unknown (because it may be specified by a plugin).

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.

None yet

1 participant