CVE-2024-24556: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in urql-graphql urql
urql is a GraphQL client that exposes a set of helpers for several frameworks. The `@urql/next` package is vulnerable to XSS. To exploit this an attacker would need to ensure that the response returns `html` tags and that the web-application is using streamed responses (non-RSC). This vulnerability is due to improper escaping of html-like characters in the response-stream. To fix this vulnerability upgrade to version 1.1.1
AI Analysis
Technical Summary
CVE-2024-24556 is a high-severity Cross-site Scripting (XSS) vulnerability affecting the urql GraphQL client, specifically the @urql/next package versions prior to 1.1.1. Urql is a popular client library used to interact with GraphQL APIs across various JavaScript frameworks. The vulnerability arises from improper neutralization of input during web page generation, classified under CWE-79. In this case, the issue is due to insufficient escaping of HTML-like characters in streamed response data when the web application uses streamed responses (non-React Server Components). An attacker can exploit this by ensuring that the server response includes HTML tags that are not properly sanitized, allowing malicious scripts to be injected and executed in the victim’s browser. This can lead to theft of sensitive information, session hijacking, or other malicious actions executed in the context of the vulnerable web application. The CVSS v3.1 score is 7.2, reflecting a high severity with network attack vector, low attack complexity, no privileges or user interaction required, and a scope change. The vulnerability impacts confidentiality and integrity but not availability. The fix involves upgrading to urql version 1.1.1 or later, where proper escaping and sanitization have been implemented to prevent injection of malicious HTML content in streamed responses.
Potential Impact
For European organizations, this vulnerability poses a significant risk, especially for those using urql in their web applications that employ streamed responses. Exploitation could lead to unauthorized disclosure of sensitive user data, including authentication tokens or personal information, undermining user trust and potentially violating GDPR requirements. The integrity of web application content could also be compromised, allowing attackers to manipulate displayed information or perform phishing attacks within the trusted domain. Given the widespread adoption of GraphQL and urql in modern web development, organizations in sectors such as finance, healthcare, e-commerce, and government services are particularly at risk. The vulnerability’s ability to be exploited remotely without authentication or user interaction increases the threat level. Additionally, exploitation could facilitate further attacks within the network if session tokens or credentials are stolen. The lack of known exploits in the wild currently reduces immediate risk but does not diminish the urgency for remediation due to the ease of exploitation and potential impact.
Mitigation Recommendations
European organizations should prioritize upgrading all instances of urql, especially the @urql/next package, to version 1.1.1 or later to remediate this vulnerability. Beyond upgrading, developers should audit their use of streamed responses to ensure that any user-generated or external content is properly sanitized before being included in responses. Implement Content Security Policy (CSP) headers to restrict the execution of unauthorized scripts and reduce the impact of potential XSS attacks. Regularly conduct security code reviews and penetration testing focusing on injection vulnerabilities in GraphQL clients and APIs. Employ runtime application self-protection (RASP) tools that can detect and block malicious script execution in real time. Finally, monitor web application logs and user reports for signs of suspicious activity that could indicate exploitation attempts.
Affected Countries
Germany, France, United Kingdom, Netherlands, Sweden, Italy, Spain, Poland
CVE-2024-24556: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in urql-graphql urql
Description
urql is a GraphQL client that exposes a set of helpers for several frameworks. The `@urql/next` package is vulnerable to XSS. To exploit this an attacker would need to ensure that the response returns `html` tags and that the web-application is using streamed responses (non-RSC). This vulnerability is due to improper escaping of html-like characters in the response-stream. To fix this vulnerability upgrade to version 1.1.1
AI-Powered Analysis
Technical Analysis
CVE-2024-24556 is a high-severity Cross-site Scripting (XSS) vulnerability affecting the urql GraphQL client, specifically the @urql/next package versions prior to 1.1.1. Urql is a popular client library used to interact with GraphQL APIs across various JavaScript frameworks. The vulnerability arises from improper neutralization of input during web page generation, classified under CWE-79. In this case, the issue is due to insufficient escaping of HTML-like characters in streamed response data when the web application uses streamed responses (non-React Server Components). An attacker can exploit this by ensuring that the server response includes HTML tags that are not properly sanitized, allowing malicious scripts to be injected and executed in the victim’s browser. This can lead to theft of sensitive information, session hijacking, or other malicious actions executed in the context of the vulnerable web application. The CVSS v3.1 score is 7.2, reflecting a high severity with network attack vector, low attack complexity, no privileges or user interaction required, and a scope change. The vulnerability impacts confidentiality and integrity but not availability. The fix involves upgrading to urql version 1.1.1 or later, where proper escaping and sanitization have been implemented to prevent injection of malicious HTML content in streamed responses.
Potential Impact
For European organizations, this vulnerability poses a significant risk, especially for those using urql in their web applications that employ streamed responses. Exploitation could lead to unauthorized disclosure of sensitive user data, including authentication tokens or personal information, undermining user trust and potentially violating GDPR requirements. The integrity of web application content could also be compromised, allowing attackers to manipulate displayed information or perform phishing attacks within the trusted domain. Given the widespread adoption of GraphQL and urql in modern web development, organizations in sectors such as finance, healthcare, e-commerce, and government services are particularly at risk. The vulnerability’s ability to be exploited remotely without authentication or user interaction increases the threat level. Additionally, exploitation could facilitate further attacks within the network if session tokens or credentials are stolen. The lack of known exploits in the wild currently reduces immediate risk but does not diminish the urgency for remediation due to the ease of exploitation and potential impact.
Mitigation Recommendations
European organizations should prioritize upgrading all instances of urql, especially the @urql/next package, to version 1.1.1 or later to remediate this vulnerability. Beyond upgrading, developers should audit their use of streamed responses to ensure that any user-generated or external content is properly sanitized before being included in responses. Implement Content Security Policy (CSP) headers to restrict the execution of unauthorized scripts and reduce the impact of potential XSS attacks. Regularly conduct security code reviews and penetration testing focusing on injection vulnerabilities in GraphQL clients and APIs. Employ runtime application self-protection (RASP) tools that can detect and block malicious script execution in real time. Finally, monitor web application logs and user reports for signs of suspicious activity that could indicate exploitation attempts.
Affected Countries
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2024-01-25T15:09:40.208Z
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 683879c8182aa0cae28296cf
Added to database: 5/29/2025, 3:14:16 PM
Last enriched: 7/8/2025, 1:57:22 AM
Last updated: 7/29/2025, 7:49:24 PM
Views: 9
Related Threats
CVE-2025-9047: SQL Injection in projectworlds Visitor Management System
MediumCVE-2025-9046: Stack-based Buffer Overflow in Tenda AC20
HighCVE-2025-9028: SQL Injection in code-projects Online Medicine Guide
MediumCVE-2025-26709: CWE-200 Exposure of Sensitive Information to an Unauthorized Actor in ZTE F50
MediumCVE-2025-9027: SQL Injection in code-projects Online Medicine Guide
MediumActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.