Cross-Site Scripting (XSS) in @nextcloud/dialogs (CVE-2021-29438)
Summary
Cross-site scripting in @nextcloud/dialogs (CVE-2021-29438). Risk of unauthorized operations or information disclosure. Exploitable via options.isHTML. Mitigation: upgrade to 3.1.2 or later.
Original description
The description as published by the source.
Impact
The Nextcloud dialogs library before 3.1.2 did insufficiently escape text input passed to a toast. If your application displays toasts with user-supplied input, this could lead to a XSS vulnerability.
Note: Nextcloud Server employs a strict Content Security Policy that mitigates the risk of these XSS vulnerabilities.
Patches
The vulnerability has been patched in version 3.1.2. If you need to display HTML in the toast, explicitly pass the options.isHTML config flag.
Workarounds
Make sure no user-supplied input flows into toasts.
Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2021-29438 has been found in @nextcloud/dialogs.
Attackers can target a specific entry point like options.isHTML over the network to misuse the product.
Risk of unauthorized operations or information disclosure.
What to do: upgrade @nextcloud/dialogs to 3.1.2 or later.
If unsure, ask your IT team or search "@nextcloud/dialogs CVE-2021-29438" on the vendor's site.
CVE-2021-29438 (@nextcloud/dialogs) — CWE-79
Attack vector: remote (network-reachable)
Attack surface: options.isHTML
Patched: 3.1.2 — apply immediately
Workaround: Make sure no user-supplied input flows into toasts.
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
Cross-site scripting (XSS) (CWE-79) exists in @nextcloud/dialogs. Attackers reach the vulnerable code path via options.isHTML.
Check the vendor advisory for the affected versions of @nextcloud/dialogs. Attack surface: options.isHTML.
Severity: ?. Risk of unauthorized operations or information disclosure.
Update to 3.1.2.
Workaround: Make sure no user-supplied input flows into toasts.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r '@nextcloud/dialogs' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r '@nextcloud/dialogs' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
@nextcloud/dialogsを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply temporary workaround mitigate
Make sure no user-supplied input flows into toasts.パッチが適用されるまでの応急処置として、Make sure no user-supplied input flows into toasts. を実施。回避策の副作用 (機能低下) を確認した上で。
-
3Apply patch patch
Upgrade @nextcloud/dialogs to 3.1.2ステージング環境で 3.1.2 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
4Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- web github.com
- web npmjs.com