GHSA-w9mr-28mw-j8hg json
Hop-by-hop abuse to malform header mutator
published 3y ago modified 8mo ago also GO-2023-1747
- cvss
- —
- not scored
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- —
- no score, EPSS covers CVEs only
- public exploits
- 0
- none known
Summary
### Impact
Downstream services relying on the presence of headers set by the `header` mutator could be exploited. A client can drop the header set by the `header` mutator by including that header's name in the `Connection` header. Example minimal config:
```yaml - id: 'example' upstream: url: 'https://example.com' match: url: 'http://127.0.0.1:4455/' methods: - GET authenticators: - handler: anonymous authorizer: handler: allow mutators: - handler: header config: headers: X-Subject: {{ .Subject }} ```
``` curl -H "Connection: close,x-subject" http://127.0.0.1:4455/ ```
The `X-Subject` header will not arrive at the downstream server. It is completely dropped. In case the downstream server handles such a request in an unexpected way, an attacker can exploit this, assuming they know or guess the internal header name.
### Patches
c5cc7f736dc84185034be4356057d1c7a656d797
### Workarounds
The downstream server should handle the case that an expected header is not set by responding with an appropriate error.
### References
See background info in https://github.com/golang/go/issues/50580
Patch / fix
- go github.com/ory/oathkeeper 0.40.3
Is GHSA-w9mr-28mw-j8hg in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerAffected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| go | github.com/ory/oathkeeper | <0.40.3 |
0.40.3 |
References
-
github.com
/ory/oathkeeper/security/advisories/GHSA-w9mr-28mw-j8hg
web, advisory
-
github.com
/ory/oathkeeper
package
Sources
- GitHub Advisory GHSA-w9mr-28mw-j8hg
- OSV GO-2023-1747
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.