Skip to content

Commit

Permalink
[11.x] Restore Request::HEADER_X_FORWARDED_PREFIX in TrustProxies (#5…
Browse files Browse the repository at this point in the history
…2598)

* [11.x] Restore Request::HEADER_X_FORWARDED_PREFIX in TrustProxies

* fix test
  • Loading branch information
taka-oyama authored Aug 31, 2024
1 parent 5ac2aa9 commit d343e5b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Illuminate/Http/Middleware/TrustProxies.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ class TrustProxies
Request::HEADER_X_FORWARDED_HOST |
Request::HEADER_X_FORWARDED_PORT |
Request::HEADER_X_FORWARDED_PROTO |
Request::HEADER_X_FORWARDED_PREFIX |
Request::HEADER_X_FORWARDED_AWS_ELB;

/**
Expand Down
1 change: 1 addition & 0 deletions tests/Foundation/Configuration/MiddlewareTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ public function testTrustHeaders()
Request::HEADER_X_FORWARDED_HOST |
Request::HEADER_X_FORWARDED_PORT |
Request::HEADER_X_FORWARDED_PROTO |
Request::HEADER_X_FORWARDED_PREFIX |
Request::HEADER_X_FORWARDED_AWS_ELB, $method->invoke($middleware));

$property->setValue($middleware, Request::HEADER_X_FORWARDED_AWS_ELB);
Expand Down

0 comments on commit d343e5b

Please sign in to comment.