CVE-2026-59157: webhookd Unrestricted HTTP Header To Shell Vulnerability
MODERATECVE-2026-59157 is a MODERATE (CVSS 6.5) unrestricted http header to shell vulnerability (CWE-807: Reliance on Untrusted Inputs in a Security Decision) affecting webhookd libraries in the Go ecosystem. The issue involves unrestricted http header to shell variable injection. Remediation is available by upgrading affected packages to version 1.22.0.
CVE-2026-59157 at a Glance
Security Impact
CVSS: 6.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N).
How to Fix CVE-2026-59157
To remediate this vulnerability, upgrade all affected webhookd dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade github.com/ncarlier/webhookd to 1.22.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/ncarlier/webhookd
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-59157, inspect your project dependencies for webhookd:
inspect dependencies for github.com/ncarlier/webhookd
Analyze the terminal output to locate any version of webhookd in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.22.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-807: Reliance on Untrusted Inputs in a Security Decision, where the product uses a protection mechanism that relies on the existence or values of an input, but the input can be modified by an untrusted actor in a way that bypasses the protection mechanism. In webhookd, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-59157 Affected webhookd Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/ncarlier/webhookd
|
Go |
< 1.22.0
|
1.22.0
|
References
Frequently Asked Questions
What is CVE-2026-59157?
Which webhookd versions are affected?
What version fixes CVE-2026-59157?
Is github.com/ncarlier/webhookd affected?
What is the CVSS score of CVE-2026-59157?
What CWE is associated with CVE-2026-59157?
How can I check Go dependencies for CVE-2026-59157?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-v25g-mvwr-f5fp",
"modified" : "2026-09-09T23:47:03Z",
"published" : "2026-09-09T23:47:03Z",
"aliases" : [ "CVE-2026-59157" ],
"summary" : "webhookd: Unrestricted HTTP Header to Shell Variable Injection",
"details" : "## Description\nBefore 1.22, if the Basic Auth (`htpasswd`) middleware was not configured, all incoming HTTP headers were blindly forwarded to the webhook script execution environment as shell variables. While the Basic Auth middleware correctly strips the authentication header (`X-WebAuthn-User`) from the incoming request before conditionally re-injecting it on successful authentication, disabling Basic Auth left the system vulnerable if deployed behind an unhardened reverse proxy.\n\n## Impact\nIf an upstream reverse proxy is not properly hardened to strip client-provided authentication headers, an attacker could manually supply these headers (e.g., `X-WebAuthn-User`). A webhook script relying on this forwarded header for privilege elevation or identity verification could therefore be exploited to bypass security controls and impersonate other users.\n\n## Mitigation\nThe `WHD_ALLOWED_UPSTREAM_HEADERS` configuration setting has been introduced to enforce a strict allowlist of HTTP headers that can be converted into shell variables. \n\nAdditionally, the default behavior has been changed to adhere to the principle of least privilege. It is no longer `*` (allow all). The default allowed headers are now restricted to standard operational headers:\n`Accept,Content-Type,Content-Length,User-Agent,X-Forwarded-For`\n\nAdministrators relying on upstream authentication proxies must explicitly add their authentication headers (e.g., `WHD_ALLOWED_UPSTREAM_HEADERS=\"Accept,Content-Type,Content-Length,User-Agent,X-Forwarded-For,x-webauthn-user\"`) to ensure they are passed to the scripts securely.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/ncarlier/webhookd"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.22.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/ncarlier/webhookd/security/advisories/GHSA-v25g-mvwr-f5fp"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/ncarlier/webhookd"
}, {
"type" : "WEB",
"url" : "https://github.com/ncarlier/webhookd/releases/tag/v1.22.0"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-290", "CWE-807" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-09-09T23:47:03Z",
"nvd_published_at" : null
}
}