You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/plugin_core.xml
+28Lines changed: 28 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -105,6 +105,15 @@
105
105
Some clients don't send Content-Length for POST requests with empty body; they should send `Content-Length: 0`. When this check is enabled they'll get a `411 Length required` error.
106
106
</markdown></description>
107
107
</option>
108
+
<optionname="proxy_protocol.tlv_max_length">
109
+
<short>maximum length of TLV parameters in PROXY v2 headers</short>
110
+
<default><value>-1</value></default>
111
+
<description><markdown><![CDATA[
112
+
Maximum length of TLV section (after address data) in PROXY v2 headers. `-1` means no limit but also doesn't store it.
113
+
114
+
Also see <https://github.com/haproxy/haproxy/blob/master/doc/proxy-protocol.txt>.
115
+
]]></markdown></description>
116
+
</option>
108
117
109
118
<optionname="static.exclude_extensions">
110
119
<short>don't deliver static files with one of the listed extensions</short>
@@ -628,6 +637,25 @@
628
637
</action>
629
638
</section>
630
639
640
+
<actionname="proxy_protocol.trust">
641
+
<short>Trust PROXY header</short>
642
+
643
+
<description><markdown>
644
+
When a [PROXY header](https://github.com/haproxy/haproxy/blob/master/doc/proxy-protocol.txt) was present and contained addresses, replace the `request.local*` and `request.remote*` variables with those from the PROXY header.
645
+
646
+
This only triggers once per connection, and should be done early in the config (so it happens for the first request); the new addresses are used for the following requests too (they are stored per connection).
647
+
648
+
You only should trust the PROXY header on connections from trusted IPs.
649
+
</markdown></description>
650
+
<example>
651
+
<config>
652
+
if request.remoteip == "198.51.100.1" or request.remoteip == "127.0.0.1" {
653
+
proxy_protocol.trust;
654
+
}
655
+
</config>
656
+
</example>
657
+
</action>
658
+
631
659
<actionname="io.buffer_out">
632
660
<short>set memory limit for outgoing chunkqueues (default is 256KiB)</short>
0 commit comments