Skip to content

security(compliance-hub): HTML-encode the application name in the export-history action cell - #7961

Open
ar2rsawseen wants to merge 1 commit into
masterfrom
security/compliance-hub-appname-encode
Open

security(compliance-hub): HTML-encode the application name in the export-history action cell#7961
ar2rsawseen wants to merge 1 commit into
masterfrom
security/compliance-hub-appname-encode

Conversation

@ar2rsawseen

Copy link
Copy Markdown
Member

The export/purge history model (plugins/compliance-hub/frontend/public/javascripts/countly.models.js) builds each row's action cell as an HTML string, and exportHistory.html renders it with v-html. Every other value in that string comes from the API, which HTML-encodes its output, but the application name is read from countlyGlobal, whose values are raw at runtime. So an application name is placed into the v-html string unencoded.

Encode the application name with countlyCommon.encodeHtml so it renders as text, matching the encoding of the other fields in the same string.

Only the application name needed it — the remaining fields are already API-encoded and must not be double-encoded; the display is unchanged. This is a distinct sink from #7949 (that fix covered the inline serializer and the active-app jQuery sink); this is downstream HTML construction in the default Compliance Hub plugin.

Scope check: a codebase scan for a raw countlyGlobal value reaching an HTML sink found only two sites — the active-app name (fixed in #7949) and this one. The wider v-html/unescapeHtml source audit is tracked separately.

Reported through the security bug bounty program.

🤖 Generated with Claude Code

…ort-history action cell

The export/purge history model builds each row's action cell as an HTML string and the
template renders it with v-html. Every other value in that string comes from the API,
which HTML-encodes its output, but the application name is read from countlyGlobal, whose
values are raw at runtime. Encode the application name with countlyCommon.encodeHtml so it
is rendered as text, matching the encoding of the other fields in the same string.

Only the application name needed encoding; the remaining fields are already API-encoded and
must not be encoded again. The display is unchanged.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant