Skip to content

Commit

Permalink
NGINX Unit strips all cookie headers from responses, closes #124.
Browse files Browse the repository at this point in the history
  • Loading branch information
Syndesi committed Sep 17, 2023
1 parent bf0cb6d commit 17536d4
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/ci-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ jobs:
- cs-lint
- test-mutant
- test-leak
- test-mess-detector
strategy:
matrix:
dockerCompose:
Expand Down Expand Up @@ -222,6 +223,7 @@ jobs:
- cs-lint
- test-mutant
- test-leak
- test-mess-detector
steps:
- uses: actions/checkout@v3
- run: mkdir -p /tmp/docker
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add PHP Mess Detector, closes #114.
- Set configuration framework.disallow_search_engine_index explicitly to false to disable the HTTP tag X-Robots-Tag,
closes #123.
### Changed
- NGINX Unit strips all cookie headers from responses, closes #124.

## 0.0.28 - 2023-09-14
### Added
Expand Down
3 changes: 3 additions & 0 deletions docker/nginx-unit/unit.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@
"share": "/var/www/html/public$uri",
"fallback": {
"pass": "applications/symfony/index"
},
"response_headers": {
"Set-Cookie": null
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/ExampleGeneration/BaseRequestTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ abstract class BaseRequestTestCase extends \App\Tests\FeatureTests\BaseRequestTe
{
private const IGNORED_HEADERS = ['Date', 'Location'];

private const REMOVED_HEADERS = ['X-Debug-Token', 'X-Debug-Token-Link', 'Set-Cookie'];
private const REMOVED_HEADERS = ['X-Debug-Token', 'X-Debug-Token-Link'];

public function getHeadersFromRequest(ResponseInterface $response): string
{
Expand Down

0 comments on commit 17536d4

Please sign in to comment.