chore: improve documentation of PROXY protocol listener#7447
Open
lkiesow wants to merge 1 commit intocaddyserver:masterfrom
Open
chore: improve documentation of PROXY protocol listener#7447lkiesow wants to merge 1 commit intocaddyserver:masterfrom
lkiesow wants to merge 1 commit intocaddyserver:masterfrom
Conversation
This patch improves the documentation of the caddy.listeners.proxy_protocol to clarify some unexpected behavior. Most notably, the previous documentation stated that `Allow` will *allow/require* PROXY headers. The require in this tripped me up since Caddy will always accept clients in this list regardless, if they are using PROXY protocol or not.
mohammed90
reviewed
Feb 16, 2026
Comment on lines
+44
to
+53
| // allow PROXY headers from. | ||
| // Note that while the PROXY protocol is allowed, | ||
| // it is not required to be used by clients in this range. | ||
| Allow []string `json:"allow,omitempty"` | ||
| allow []netip.Prefix | ||
|
|
||
| // Deny is an optional list of CIDR ranges to | ||
| // deny PROXY headers from. | ||
| // Connections without PROXY headers from clients | ||
| // in this range are still allowed. |
Member
There was a problem hiding this comment.
I think it's more fair/accurate to mention it's dependant on the fallback policy, and it should use may instead of are. What do you think?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This patch improves the documentation of the
caddy.listeners.proxy_protocol to clarify some unexpected behavior.
Most notably, the previous documentation stated that
Allowwill allow/require PROXY headers. The require in this tripped me up since Caddy will always accept clients in this list regardless, if they are using PROXY protocol or not.Assistance Disclosure
No AI was used.