CVE-2023-2587
Executive Summary
CVE-2023-2587 is a cross-site scripting (XSS) vulnerability affecting Teltonika's Remote Management System (RMS) versions prior to 4.10.0. The flaw resides in the main page of the web interface and can be triggered when an attacker possessing the MAC address and serial number of a connected device delivers a maliciously crafted JSON file containing an HTML object. Successful exploitation enables script execution within the context of the victim's account, potentially leading to remote code execution (RCE) on managed IoT/industrial devices. With a CVSS score of 7.5 (High severity), this vulnerability represents a significant supply-chain and operational risk for enterprises using Teltonika RMS to manage fleets of remote devices in logistics, industrial automation, and utility sectors.
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
Technical Analysis
The vulnerability is a stored/reflected cross-site scripting (XSS) flaw located on the main page of the Teltonika Remote Management System web interface. The NVD description indicates that the attack vector requires two specific pieces of information about a connected device: its MAC address and serial number. These identifiers are typically printed on device labels or obtainable through prior reconnaissance, physical access, or default documentation.
The attack mechanism operates as follows: an attacker crafts a JSON file (a standard data interchange format) that embeds an HTML object — a structural element used to embed external content within an HTML document. Teltonika RMS versions prior to 4.10.0 fail to sanitize or validate this content when rendering the data on the main dashboard page. The web interface processes the JSON file and renders the embedded HTML object without proper output encoding, thereby allowing attacker-controlled markup to execute within the browser's security context.
The attack surface is the RMS web dashboard, which is likely accessible to authenticated administrative users managing device fleets. The "main page" of the interface displays device telemetry, status, and configuration data. If the application consumes JSON payloads (for device registration, configuration imports, or status updates) and renders this data on the main page without contextual output encoding, it permits the injection of arbitrary HTML/JavaScript.
The XSS context is significant: because the interface is a management console with elevated privileges, script execution occurs in the account context of the logged-in administrator. This enables attackers to hijack sessions, exfiltrate authentication tokens, issue management commands, and potentially pivot to the managed devices themselves. The NVD description explicitly notes that RCE on managed devices is achievable — this suggests the XSS can be chained with legitimate RMS functionality (such as remote command execution, firmware update deployment, or SSH tunneling) that the web console exposes.
It is critical to note the severity scoring. The CVSS score provided is 7.5, classified as High. The specific vector string is not disclosed in the available data, so the precise CVSS component breakdown (AV/AC/PR/UI/S/C/A) cannot be derived.
The CWE classification is not provided. However, based on the vulnerability mechanism described, the most probable classifications are CWE-79 (Improper Neutralization of Input During Web Page Generation — "Cross-site Scripting") or CWE-80 (Improper Neutralization of Script-Related HTML Tags in a Web Page). The JSON file delivery mechanism suggests insufficient validation of file content before rendering.
The EPSS score of 0.00917 (56.9th percentile) indicates a relatively low probability of exploitation in the wild, but this ranking does not account for targeted attacks against organizations heavily reliant on Teltonika infrastructure.
Exploitation Scenarios
Based solely on the NVD description and vulnerability class characteristics, the attack chain unfolds as follows:
Step 1: Reconnaissance / Target Identification. The attacker must first identify a target organization using Teltonika RMS. This can be achieved through internet-wide scanning (Shodan, Censys) for exposed RMS web interfaces, banner grabbing, or through supply-chain intelligence. The attacker then needs to obtain the MAC address and serial number of a connected device. Sources include: shipping labels, default documentation shipped with devices, configuration exports, intercepted network traffic, physically compromised devices, or social engineering against field technicians.
Step 2: Flaw Trigger. The attacker crafts a JSON file that contains an embedded HTML object. This JSON file is then delivered to the RMS system or an administrator. Delivery paths could include: importing the JSON file through the RMS web interface (if file upload is supported), sending it via a phishing email to an administrator, or uploading it to a compromised device that then syncs data to RMS. When an administrator opens or the system processes this JSON file on the main page, the embedded HTML object is rendered.
Step 3: Payload Execution. Because the vulnerability is an XSS flaw, the attacker embeds JavaScript code within the HTML object. On successful rendering, this JavaScript executes within the administrator's browser session, against the RMS web application origin. The script can perform actions such as: reading and exfiltrating session cookies, performing authenticated API calls, manipulating the DOM to inject additional controls, or triggering legitimate RMS features.
Step 4: Post-Exploitation. Within the account context (administrator), the attacker can use the RMS web console's legitimate functionality to achieve remote code execution on managed devices. The NVD description confirms RCE is achievable. Typical administrative actions in RMS include: deploying firmware updates, pushing configuration files, rebooting devices, establishing reverse SSH tunnels, or executing diagnostic commands. Each of these can be abused to plant persistent backdoors on endpoints.
No public PoC is available for this vulnerability. The attack chain described above is inferred from the vulnerability class (XSS in a management interface) and the explicit RCE outcome stated in the NVD description. Specific implementation details — function names, API endpoints, exact JSON structure — are not disclosed in the available data.
Impact Assessment
Business Impact. This vulnerability directly threatens organizations that rely on Teltonika RMS to manage fleets of remote devices. Compromise of the RMS console grants attackers administrative control over the managed infrastructure, including industrial control devices, routers, gateways, and telemetry systems. Successful exploitation could lead to: operational disruption (device reboots, configuration corruption), data exfiltration (telemetry, configuration secrets, credentials), persistent backdooring of remote assets, and lateral movement into OT/ICS networks that these devices connect to.
Blast Radius. The XSS executes in the context of the logged-in user — likely an administrator with full RMS privileges. The attack is not limited to a single device: the attacker could leverage the RMS console to compromise ALL devices managed through the affected instance, potentially cascading across multiple client sites, geographic regions, or critical infrastructure segments.
CVSS Subscores. The overall score of 7.5 (High) is supplied. The absence of a vector string precludes precise subscore analysis for Attack Vector, Complexity, Privileges Required, User Interaction, and Impact metrics. From the description, we can infer the attack requires some level of user interaction (an administrator viewing the malicious content) and specific preconditions (device MAC and serial number), but the exact metric composition is undisclosed.
Affected Systems. All Teltonika RMS deployments running versions prior to 4.10.0. The affected-version list is not enumerated in the available data, but the threshold of 4.10.0 is explicitly noted.
Detection Guidance
Sigma Rule
title: Teltonika RMS XSS Payload in JSON Upload
id: 8d0c0e7a-3b1f-4a77-9e2b-0f5b2c93d1a4
status: experimental
description: Detects JSON files containing HTML object tags uploaded or processed by Teltonika Remote Management System (CVE-2023-2587)
references:
- https://nvd.nist.gov/vuln/detail/CVE-2023-2587
author: Valtersit Security Research
date: 2025/01/01
tags:
- attack.initial-access
- attack.t1190
- cve.2023-2587
logsource:
product: teltonika
service: rms
detection:
selection_json_content:
payload|contains:
- '<object'
- '<embed'
- '<iframe'
- 'data:text/html'
- 'data:image/svg+xml'
selection_json_extension:
- 'json'
- 'application/json'
condition: selection_json_content and selection_json_extension
falsepositives:
- Legitimate JSON configuration files containing HTML snippets for device dashboards
level: high
YARA Rule
rule Teltonika_RMS_XSS_JSON_Payload {
meta:
author = "Valtersit Security Research"
description = "Detect malicious JSON files with HTML objects targeting Teltonika RMS CVE-2023-2587"
date = "2025-01-01"
reference = "https://nvd.nist.gov/vuln/detail/CVE-2023-2587"
cve = "CVE-2023-2587"
severity = "high"
strings:
$json_start = /{[\s]*"[^"]*"/
$html_object = { 3C 6F 62 6A 65 63 74 } // <object
$html_embed = { 3C 65 6D 62 65 64 } // <embed
$html_iframe = { 3C 69 66 72 61 6D 65 } // <iframe
$data_html = "data:text/html"
$script_tag = "<script>"
$svg_data = "data:image/svg+xml"
$json_mime = "application/json"
condition:
(any of ($html_object, $html_embed, $html_iframe))
and ($data_html or $script_tag or $svg_data)
and ($json_start or $json_mime)
}
Suricata IDS Rule
alert http any any -> any any (msg:"ET EXPLOIT Teltonika RMS XSS JSON Payload (CVE-2023-2587)"; flow:established,to_server; content:"<object"; http_client_body; nocase; content:"data:text/html"; http_client_body; nocase; content:".json"; http_uri; nocase; classtype:web-application-attack; sid:2023125; rev:1; metadata:attack_target Web_Server, created_at 2025_01_01, cve CVE-2023-2587, deployment Perimeter, former_category EXPLOIT, signature_severity Major, tag XSS, tag CVE-2023-2587)
Elastic Detection
sequence by source.ip, destination.ip with maxspan=1m
[network where event.action == "connection_established" and destination.port in (80, 443)]
[http where event.action == "request" and
url.path contains ".json" and
any(http.request.body.content matches "<object") and
any(http.request.body.content matches "data:text/html|data:image/svg+xml|<script>")]
Splunk SPL Query
index=web OR index=proxy sourcetype="json"
| where match(_raw, "<object|data:text/html|<script>|data:image/svg\+xml")
AND match(_raw, "MAC|Serial|serial_number|mac_address")
| eval cve="CVE-2023-2587"
| eval attack_class="XSS"
| table _time, src_ip, dest_ip, uri, http_method, response_code
| sort - _time
Wazuh OSSEC Rule
<group name="teltonika_rms,">
<rule id="100217" level="12">
<decoded_as>json</decoded_as>
<match>object|embed|iframe</match>
<regex>(?i)\<object\b|\<embed\b|\<iframe\b</regex>
<regex>(?i)(data:text/html|data:image/svg\+xml)</regex>
<description>Teltonika RMS potential XSS payload in JSON content (CVE-2023-2587)</description>
<group>attack.initial_access,</group>
<mitre>
<id>T1190</id>
</mitre>
</rule>
</group>
Mitigation & Patch Guidance
Patch Confidence: 2/4 — CLAIMED (single source claims patch, not independently confirmed).
Immediate Mitigations:
- Upgrade Teltonika Remote Management System to version 4.10.0 or later if available from the vendor (official claim). Verify the patch independently before deployment.
- Restrict access to the RMS web interface to trusted networks via firewall rules; never expose it directly to the internet.
- Enforce multi-factor authentication (MFA) on all RMS accounts to mitigate session-hijacking impact if XSS is triggered.
- Monitor logs for unexpected JSON file uploads or imports to the RMS system.
- Segment the RMS console from OT networks where managed devices reside.
Patch/Upgrade Steps:
- Contact Teltonika support or check the official RMS changelog for the version 4.10.0 release notes confirming the XSS fix.
- Back up the RMS configuration and database before upgrading.
- Schedule the upgrade during a maintenance window, as the RMS console may be unavailable during installation.
- Verify the fix by re-testing JSON file imports with HTML objects after the upgrade.
Long-Term Hardening:
- Implement a web application firewall (WAF) with XSS detection rules in front of the RMS interface.
- Audit all administrative accounts and enforce the principle of least privilege.
- Inventory all devices connected to RMS; validate that MAC addresses and serial numbers match expected hardware.
- Establish a patch management cadence for all cyber-physical systems management platforms.
- Consider network-level monitoring for anomalous JSON uploads or unusual device configuration changes.
Vendor Fix: Not independently verified. Single-source claim (CNA) that version 4.10.0 addresses the vulnerability. No CISA KEV listing confirms active exploitation; EPSS suggests low overall exploit probability.
References
- NVD Entry: https://nvd.nist.gov/vuln/detail/CVE-2023-2587
- Teltonika Networks RMS Product Page (for vendor advisory reference): https://teltonika-networks.com/product/rms
- CISA Known Exploited Vulnerabilities Catalog (CVE-2023-2587 not listed): https://www.cisa.gov/known-exploited-vulnerabilities-catalog
- FIRST EPSS Score Data: https://www.first.org/epss/
- MITRE ATT&CK T1190 — Exploit Public-Facing Application: https://attack.mitre.org/techniques/T1190/
Threat Actor Campaigns: No known threat-actor campaigns have been publicly attributed to CVE-2023-2587 as of the reporting date. No exploit-in-the-wild evidence has been confirmed. The EPSS percentile (56.9%) suggests moderate attention within the scanning community but no confirmed mass exploitation.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.