Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/vulndb: potential Go vuln in github.com/ory/oathkeeper: GHSA-w9mr-28mw-j8hg #1747

Closed
GoVulnBot opened this issue Apr 26, 2023 · 4 comments
Closed
Assignees
Labels
excluded: EFFECTIVELY_PRIVATE This vulnerability exists in a package can be imported, but isn't meant to be outside that module.

Comments

@GoVulnBot
Copy link

In GitHub Security Advisory GHSA-w9mr-28mw-j8hg, there is a vulnerability in the following Go packages or modules:

Unit Fixed Vulnerable Ranges
github.com/ory/oathkeeper 0.40.3 < 0.40.3

Cross references:

See doc/triage.md for instructions on how to triage this report.

modules:
  - module: github.com/ory/oathkeeper
    versions:
      - fixed: 0.40.3
    packages:
      - package: github.com/ory/oathkeeper
summary: Hop-by-hop abuse to malform header mutator
description: |-
    ### 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: 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
ghsas:
  - GHSA-w9mr-28mw-j8hg
references:
  - advisory: https://github.com/ory/oathkeeper/security/advisories/GHSA-w9mr-28mw-j8hg
  - advisory: https://github.com/advisories/GHSA-w9mr-28mw-j8hg

@zpavlinovic zpavlinovic self-assigned this Apr 26, 2023
@zpavlinovic zpavlinovic added the excluded: EFFECTIVELY_PRIVATE This vulnerability exists in a package can be imported, but isn't meant to be outside that module. label Apr 26, 2023
@zpavlinovic
Copy link
Contributor

Vulnerability in tool.

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/490635 mentions this issue: data/excluded: batch add GO-2023-1748, GO-2023-1747, GO-2023-1749

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/592760 mentions this issue: data/reports: unexclude 75 reports

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/606785 mentions this issue: data/reports: unexclude 20 reports (5)

gopherbot pushed a commit that referenced this issue Aug 20, 2024
  - data/reports/GO-2023-1700.yaml
  - data/reports/GO-2023-1701.yaml
  - data/reports/GO-2023-1707.yaml
  - data/reports/GO-2023-1708.yaml
  - data/reports/GO-2023-1716.yaml
  - data/reports/GO-2023-1718.yaml
  - data/reports/GO-2023-1719.yaml
  - data/reports/GO-2023-1721.yaml
  - data/reports/GO-2023-1723.yaml
  - data/reports/GO-2023-1730.yaml
  - data/reports/GO-2023-1735.yaml
  - data/reports/GO-2023-1738.yaml
  - data/reports/GO-2023-1747.yaml
  - data/reports/GO-2023-1754.yaml
  - data/reports/GO-2023-1758.yaml
  - data/reports/GO-2023-1761.yaml
  - data/reports/GO-2023-1763.yaml
  - data/reports/GO-2023-1764.yaml
  - data/reports/GO-2023-1768.yaml
  - data/reports/GO-2023-1774.yaml

Updates #1700
Updates #1701
Updates #1707
Updates #1708
Updates #1716
Updates #1718
Updates #1719
Updates #1721
Updates #1723
Updates #1730
Updates #1735
Updates #1738
Updates #1747
Updates #1754
Updates #1758
Updates #1761
Updates #1763
Updates #1764
Updates #1768
Updates #1774

Change-Id: I3fc567427d68e095cc62ea48dc9b284b2414a372
Reviewed-on: https://go-review.googlesource.com/c/vulndb/+/606785
Auto-Submit: Tatiana Bradley <tatianabradley@google.com>
Reviewed-by: Damien Neil <dneil@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
excluded: EFFECTIVELY_PRIVATE This vulnerability exists in a package can be imported, but isn't meant to be outside that module.
Projects
None yet
Development

No branches or pull requests

3 participants