CVE-2023-27494 Streamlit Cross-site Scripting vulnerability
Attackers can execute arbitrary JavaScript in users' browsers via malicious URLs in Streamlit apps, potentially leading to session hijacking or data theft.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2023-27494?
CVE-2023-27494 is a medium-severity cross-site scripting vulnerability in streamlit, published on 16 Mar 2023. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
Streamlit, software for turning data scripts into web applications, had a cross-site scripting (XSS) vulnerability in versions 0.63.0 through 0.80.0. Users of hosted Streamlit app(s) were vulnerable to a reflected XSS vulnerability. An attacker could craft a malicious URL with Javascript payloads to a Streamlit app. The attacker could then trick the user into visiting the malicious URL and, if successful, the server would render the malicious javascript payload as-is, leading to XSS. Version 0.81.0 contains a patch for this vulnerability.
Weakness: CWE-79
Which versions are affected by CVE-2023-27494?
3 open source packages ship an affected version, including streamlit. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
streamlit PyPI | From 0.63.0 | 0.81.0 |
streamlit PyPI | From 0.63.0 | 0.81.0 |
streamlit PyPI | From 0.63.0 | 0.81.0 |
Products include Snowflake Streamlit.
How do I fix CVE-2023-27494?
Upgrade streamlit to 0.81.0 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2023-27494 being exploited?
There is no known exploitation of CVE-2023-27494 in the wild and no public exploit code.
Other vulnerabilities in streamlit
Sources
Also known as GHSA-9c6g-qpgj-rvxw, PYSEC-2023-50.