DHI-nxen-zrxb-5bdz-m7jt

Source
https://scout.docker.com/v/DHI-nxen-zrxb-5bdz-m7jt
Import Source
https://github.com/docker-hardened-images/advisories/blob/main/dhi/osv/2026/DHI-nxen-zrxb-5bdz-m7jt.json
JSON Data
https://api.osv.dev/v1/vulns/DHI-nxen-zrxb-5bdz-m7jt
Upstream
  • GHSA-6wvj-vwrc-wcrm
Published
2026-11-11T23:10:18Z
Modified
2026-11-16T02:35:54Z
Summary
## Affected product
Details

Affected product

RabbitMQ — rabbitmq_management plugin, OAuth 2.0 login status rendering

Summary

The CVE-2026-67421 fix renamed the login_oauth.ejs template variable to escaped_warnings, establishing a contract that callers pre-escape, and added fmt_escape_html at the call sites. One caller was missed: check_bad_response still passes the server-supplied reason unescaped on the 401/403 OAuth branch, four lines above a sibling branch that escapes the same value. The sink is unchanged — login_oauth.ejs renders <%=escaped_warnings[i]%>, and <%= does not auto-escape in this codebase's EJS engine.

The advisory's defense-in-depth recommendation, base-uri 'none' in the default CSP, was also not applied, so the <base> injection that made CVE-2026-67421 reach credential theft still works.

Note on tooling: this report was prepared with AI assistance (Claude Code). The analysis and the proposed fix were reviewed by the submitter before filing.

Affected code

  • deps/rabbitmq_management/priv/www/js/main.js → check_bad_response, initiate_logout(oauth, reason) on the (req.status == 401 || req.status == 403) && oauth.enabled branch. initiate_logout/2 has that single caller, and it is the only unescaped path into the sink: the other callers of renderWarningMessageInLoginStatus pass either an fmt_escape_html-wrapped value (main.js:29) or a literal (main.js:132 on all affected branches, plus main.js:149 on main).
  • deps/rabbitmq_management/priv/www/js/tmpl/login_oauth.ejs → <p class="warning"><%=escaped_warnings[i]%> </p>.
  • deps/rabbitmq_management/Makefile → default content_security_policy is script-src 'self'; object-src 'self', with no base-uri.

reason carries an attacker-chosen string: rabbit_access_control:check_resource_access/4 formats "~s access to ~ts refused for user '~ts'" with the resource name, and rabbit_channel:check_name/2 restricts only the amq. prefix.

Steps to reproduce

Not runtime-confirmed. Verified by source inspection on the v4.3.6 tag, upstream/v4.3.x and upstream/main: initiate_logout(oauth, fmt_escape_html( appears zero times on all three, and the template sink is unchanged from the version CVE-2026-67421 described.

The chain is the one that advisory documents, with OAuth enabled on the management UI: an attacker with configure permission declares a queue whose name is an HTML payload; a victim with management UI access but no read permission on it triggers Get Message(s); the broker returns 401 with error: not_authorised and a reason embedding the name; check_bad_response routes it to the raw sink.

Impact

Same as CVE-2026-67421 and unchanged by its fix: stored HTML injection into the management UI login status, rendered for an administrator. script-src 'self' blocks inline script, but with no base-uri an injected <base> retargets the UI's periodic relative-URL refresh to an attacker origin, sending the victim's Authorization header with it. Requires OAuth on the management UI, which is not the default, plus a shared vhost and the victim's permission mismatch and interaction.

Suggested remediation

Escape at the missed caller:

initiate_logout(oauth, fmt_escape_html(reason));

Escaping at the sink instead is not viable, despite being CVE-2026-67421's stated primary fix: warningMessageOAuthResource/2 and warningMessageOAuthResources/3 in js/oidc-oauth/helper.js build warnings containing intentional <b> markup around individually escaped values, so a sink-level escape would render those tags as text. The caller contract is required rather than incidental, which is worth recording so the next fix does not reach for the sink again.

Separately, add base-uri 'none' to the default content_security_policy. The management UI uses no <base> element and never reads document.baseURI, and operators who set management.csp.policy explicitly override the default entirely, so this is inert for existing deployments. connect-src should not be defaulted — it can break OAuth flows contacting an external identity provider and needs an operator allowlist.

Two commits implementing both are ready to push to a private fork on request.

Credit

Found while reviewing scanner findings against the 4.3.6 source.

References

Affected packages

Docker Hardened Images:Debian:13 / rabbitmq-4.3

Package

Name
rabbitmq-4.3
Purl
pkg:deb/dhi/rabbitmq-4.3

Affected ranges

Affected versions

4.*
4.3.5-0
4.3.5-1
4.3.6-0
4.3.6-1
4.3.6-2

Database specific

owner_kind
"HSP"
source
"https://github.com/docker-hardened-images/advisories/blob/main/dhi/osv/2026/DHI-nxen-zrxb-5bdz-m7jt.json"