Every CVE Search/ Get API key

CVE-2021-46888

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability...

5.4 MediumFix available

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
Low
User interaction
Required

What an attacker can affect

Confidentiality
Low
Integrity
Low
Availability
None

Exploit likelihood

0.77%Up 0.7 points since May 22, 2023
90%50%10%1%

What each source reports

NVD Score used 5.4

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Record
CVE-2021-46888
CVSS 3.1
5.4 MediumCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Weakness
CWE-79
Updated
2026-11-02
CVE List No score

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Record
CVE-2021-46888
Updated
2026-11-02
EUVDEUVD-2021-33538 No score

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Record
EUVD-2021-33538
Updated
2026-11-03
GitHub AdvisoriesGHSA-9fcq-h23h-rxhx 5.4

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability...

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Record
GHSA-9fcq-h23h-rxhx
CVSS 3.1
5.4 MediumCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Weakness
CWE-79
Updated
2026-11-02
OSV 5.4

An issue was discovered in hledger before 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

Record
CVE-2021-46888
CVSS 3.1
5.4 MediumCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Updated
2026-11-02
OSVHSEC-2023-0008 No score

Stored XSS in hledger-web

Stored XSS in hledger-web

An issue was discovered in hledger-web < 1.23. A Stored Cross-Site Scripting (XSS) vulnerability exists in toBloodhoundJson that allows an attacker to execute JavaScript by encoding user-controlled values in a payload with base64 and parsing them with the atob function.

hledger-web forms sanitise obvious JavaScript, but not obfuscated JavaScript (see OWASP Filter Evasion Cheat Sheet). This means hledger-web instances, especially anonymously-writable ones like demo.hledger.org, could be loaded with malicious JavaScript to be executed by subsequent visitors.

Reported by Gaspard Baye and Hamidullah Muslih. Fix by Arsen Arsenović.

Record
HSEC-2023-0008
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
hledger-web
Hackage
0.24 up to 1.23, plus listed versions
0.24.10.250.25.10.260.27
Show 39 moreShow less
1.01.0.11.11.101.111.11.11.121.131.141.14.11.151.161.16.11.16.21.171.17.11.181.18.11.191.19.11.21.201.20.11.20.21.20.31.20.41.211.221.22.11.22.21.31.3.11.3.21.41.51.5.11.91.9.11.9.2
1.23

History

History
RecordedChangedSources
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2021-46888 is a medium vulnerability (CVSS 5.4) in Hledger, published May 21, 2023. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.77%, the 55th percentile. Fixed in hledger-web 1.23.

References

MoveEnter Open