GHSA-879P-475X-RQH2

Vulnerability from github – Published: 2026-02-24 20:37 – Updated: 2026-02-24 20:37
VLAI?
Summary
Caddy is vulnerable to cross-origin config application via local admin API /load
Details

commit: e0f8d9b2047af417d8faf354b675941f3dac9891 (as-of 2026-02-04) channel: GitHub security advisory (per SECURITY.md)

summary

The local caddy admin API (default listen 127.0.0.1:2019) exposes a state-changing POST /load endpoint that replaces the entire running configuration.

When origin enforcement is not enabled (enforce_origin not configured), the admin endpoint accepts cross-origin requests (e.g., from attacker-controlled web content in a victim browser) and applies an attacker-supplied JSON config. this can change the admin listener settings and alter HTTP server behavior without user intent.

Severity

Medium

Justification: - The attacker can apply an arbitrary caddy config (integrity impact) by driving a victim’s local admin API. - Exploitation requires a victim running caddy with the admin API enabled and visiting an attacker-controlled page (or otherwise issuing the request from an untrusted local client).

Affected component

  • caddyconfig/load.go: adminLoad.handleLoad (/load admin endpoint)
  • Pinned callsite: https://github.com/caddyserver/caddy/blob/e0f8d9b2047af417d8faf354b675941f3dac9891/caddyconfig/load.go#L73

Reproduction

Attachment: poc.zip (integration harness) with canonical and control runs.

unzip -q -o poc.zip -d poc
cd poc/poc-F-CADDY-ADMIN-LOAD-001
make test

Expected output (excerpt):

[CALLSITE_HIT]: adminLoad.handleLoad
[PROOF_MARKER]: http_code=200 admin_moved=true response_pwned=true

Control output (excerpt):

[NC_MARKER]: http_code=403 load_blocked=true admin_moved=false response_pwned=false

Impact

An attacker can replace the running caddy configuration via the local admin API. Depending on the deployed configuration/modules, this can: - Change admin listener settings (e.g., move the admin listener to a new address) - Change HTTP server behavior (e.g., alter routes/responses)

Suggested remediation

Ensure cross-origin web content cannot trigger POST /load on the local admin API by default, for example by: - Enabling origin enforcement by default for unsafe methods, and/or - Requiring an unguessable token for /load (and other state-changing admin endpoints).

poc.zip PR_DESCRIPTION.md

Show details on source website

{
  "affected": [
    {
      "package": {
        "ecosystem": "Go",
        "name": "github.com/caddyserver/caddy/v2"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "2.11.1"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2026-27589"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-352"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-02-24T20:37:35Z",
    "nvd_published_at": "2026-02-24T17:29:04Z",
    "severity": "MODERATE"
  },
  "details": "commit: e0f8d9b2047af417d8faf354b675941f3dac9891 (as-of 2026-02-04)\nchannel: GitHub security advisory (per SECURITY.md)\n\n## summary\n\nThe local caddy admin API (default listen `127.0.0.1:2019`) exposes a state-changing `POST /load` endpoint that replaces the entire running configuration.\n\nWhen origin enforcement is not enabled (`enforce_origin` not configured), the admin endpoint accepts cross-origin requests (e.g., from attacker-controlled web content in a victim browser) and applies an attacker-supplied JSON config. this can change the admin listener settings and alter HTTP server behavior without user intent.\n\n## Severity\n\nMedium\n\nJustification:\n- The attacker can apply an arbitrary caddy config (integrity impact) by driving a victim\u2019s local admin API.\n- Exploitation requires a victim running caddy with the admin API enabled and visiting an attacker-controlled page (or otherwise issuing the request from an untrusted local client).\n\n## Affected component\n\n- `caddyconfig/load.go: adminLoad.handleLoad` (`/load` admin endpoint)\n- Pinned callsite: https://github.com/caddyserver/caddy/blob/e0f8d9b2047af417d8faf354b675941f3dac9891/caddyconfig/load.go#L73\n\n## Reproduction\n\nAttachment: `poc.zip` (integration harness) with canonical and control runs.\n\n```bash\nunzip -q -o poc.zip -d poc\ncd poc/poc-F-CADDY-ADMIN-LOAD-001\nmake test\n```\n\nExpected output (excerpt):\n\n```\n[CALLSITE_HIT]: adminLoad.handleLoad\n[PROOF_MARKER]: http_code=200 admin_moved=true response_pwned=true\n```\n\nControl output (excerpt):\n\n```\n[NC_MARKER]: http_code=403 load_blocked=true admin_moved=false response_pwned=false\n```\n\n## Impact\n\nAn attacker can replace the running caddy configuration via the local admin API. Depending on the deployed configuration/modules, this can:\n- Change admin listener settings (e.g., move the admin listener to a new address)\n- Change HTTP server behavior (e.g., alter routes/responses)\n\n## Suggested remediation\n\nEnsure cross-origin web content cannot trigger `POST /load` on the local admin API by default, for example by:\n- Enabling origin enforcement by default for unsafe methods, and/or\n- Requiring an unguessable token for `/load` (and other state-changing admin endpoints).\n\n[poc.zip](https://github.com/user-attachments/files/25079818/poc.zip)\n[PR_DESCRIPTION.md](https://github.com/user-attachments/files/25079820/PR_DESCRIPTION.md)",
  "id": "GHSA-879p-475x-rqh2",
  "modified": "2026-02-24T20:37:35Z",
  "published": "2026-02-24T20:37:35Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/caddyserver/caddy/security/advisories/GHSA-879p-475x-rqh2"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-27589"
    },
    {
      "type": "WEB",
      "url": "https://github.com/caddyserver/caddy/commit/65e0ddc22137bbbaa68c842ae0b98d0548504545"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/caddyserver/caddy"
    },
    {
      "type": "WEB",
      "url": "https://github.com/caddyserver/caddy/releases/tag/v2.11.1"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:P",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Caddy is vulnerable to cross-origin config application via local admin API /load "
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.


Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…