summaryrefslogtreecommitdiffhomepage
path: root/test/test_forwarded_header.py
diff options
context:
space:
mode:
authorDan Callahan <d.callahan@f5.com>2024-02-27 15:15:42 +0000
committerDan Callahan <d.callahan@f5.com>2024-02-27 15:15:42 +0000
commitd76761901c4084bcdbc5a449e9bbb47d56b7093c (patch)
treeb4b7b4e3d588b73a2adcc0094cab466d9194c679 /test/test_forwarded_header.py
parentc43629880472bba8d389dfb0b7ae6d883b0ba499 (diff)
parent088117008c9e8f397a58cc8d8070ce047beff12f (diff)
downloadunit-d76761901c4084bcdbc5a449e9bbb47d56b7093c.tar.gz
unit-d76761901c4084bcdbc5a449e9bbb47d56b7093c.tar.bz2
Merge tag '1.32.0' into branches/packaging1.32.0-1
Unit 1.32.0 release.
Diffstat (limited to 'test/test_forwarded_header.py')
-rw-r--r--test/test_forwarded_header.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/test/test_forwarded_header.py b/test/test_forwarded_header.py
index c3f4a4c6..4b2f9424 100644
--- a/test/test_forwarded_header.py
+++ b/test/test_forwarded_header.py
@@ -1,4 +1,5 @@
import pytest
+
from unit.applications.lang.python import ApplicationPython
prerequisites = {'modules': {'python': 'any'}}
@@ -14,11 +15,11 @@ def setup_method_fixture():
def forwarded_header(forwarded):
assert 'success' in client.conf(
{
- "127.0.0.1:7081": {
+ "127.0.0.1:8081": {
"forwarded": forwarded,
"pass": "applications/forwarded_header",
},
- "[::1]:7082": {
+ "[::1]:8082": {
"forwarded": forwarded,
"pass": "applications/forwarded_header",
},
@@ -28,7 +29,7 @@ def forwarded_header(forwarded):
def get_fwd(sock_type='ipv4', xff=None, xfp=None):
- port = 7081 if sock_type == 'ipv4' else 7082
+ port = 8081 if sock_type == 'ipv4' else 8082
headers = {'Connection': 'close'}
@@ -243,7 +244,7 @@ def test_forwarded_header_source_range():
def test_forwarded_header_invalid():
assert 'error' in client.conf(
{
- "127.0.0.1:7081": {
+ "127.0.0.1:8081": {
"forwarded": {"source": '127.0.0.1'},
"pass": "applications/forwarded_header",
}
@@ -254,7 +255,7 @@ def test_forwarded_header_invalid():
def check_invalid_source(source):
assert 'error' in client.conf(
{
- "127.0.0.1:7081": {
+ "127.0.0.1:8081": {
"forwarded": {
"client_ip": "X-Forwarded-For",
"source": source,