D-Link DIR-818LW/DIR-822 B1 SetRouterSettings.php IPTWAN_build_command RemotePort command injection

CVSS Meta Temp Score
CVSS is a standardized scoring system to determine possibilities of attacks. The Temp Score considers temporal factors like disclosure, exploit and countermeasures. The unique Meta Score calculates the average score of different sources to provide a normalized scoring system.
Current Exploit Price (≈)
Our analysts are monitoring exploit markets and are in contact with vulnerability brokers. The range indicates the observed or calculated exploit price to be seen on exploit markets. A good indicator to understand the monetary effort required for and the popularity of an attack.
CTI Interest Score
Our Cyber Threat Intelligence team is monitoring different web sites, mailing lists, exploit markets and social media networks. The CTI Interest Score identifies the interest of attackers and the security community for this specific vulnerability in real-time. A high score indicates an elevated risk to be targeted for this vulnerability.
8.5$5k-$25k0.00

Summaryinfo

A vulnerability classified as critical was found in D-Link DIR-818LW and DIR-822 B1. The affected element is the function IPTWAN_build_command of the file SetRouterSettings.php. Such manipulation of the argument RemotePort as part of Shell Metacharacter leads to command injection. This vulnerability is traded as CVE-2018-19986. The attack may be launched remotely. There is no exploit available.

Detailsinfo

A vulnerability, which was classified as critical, has been found in D-Link DIR-818LW and DIR-822 B1 (Router Operating System) (version unknown). Affected by this issue is the function IPTWAN_build_command of the file SetRouterSettings.php. The manipulation of the argument RemotePort as part of a Shell Metacharacter leads to a command injection vulnerability. Using CWE to declare the problem leads to CWE-77. The product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component. Impacted is confidentiality, integrity, and availability. CVE summarizes:

In the /HNAP1/SetRouterSettings message, the RemotePort parameter is vulnerable, and the vulnerability affects D-Link DIR-818LW Rev.A 2.05.B03 and DIR-822 B1 202KRb06 devices. In the SetRouterSettings.php source code, the RemotePort parameter is saved in the $path_inf_wan1."/web" internal configuration memory without any regex checking. And in the IPTWAN_build_command function of the iptwan.php source code, the data in $path_inf_wan1."/web" is used with the iptables command without any regex checking. A vulnerable /HNAP1/SetRouterSettings XML message could have shell metacharacters in the RemotePort element such as the `telnetd` string.

The weakness was shared 05/13/2019. This vulnerability is handled as CVE-2018-19986 since 12/09/2018. The attack may be launched remotely. No form of authentication is required for exploitation. There are known technical details, but no exploit is available. The current price for an exploit might be approx. USD $5k-$25k (estimation calculated on 09/15/2023). The MITRE ATT&CK project declares the attack technique as T1202.

By approaching the search of inurl:SetRouterSettings.php it is possible to find vulnerable targets with Google Hacking.

There is no information about possible countermeasures known. It may be suggested to replace the affected object with an alternative product.

VulDB is the best source for vulnerability data and more expert information about this specific topic.

Productinfo

Type

Vendor

Name

License

Website

CPE 2.3info

CPE 2.2info

CVSSv4info

VulDB Vector: 🔍
VulDB Reliability: 🔍

CVSSv3info

VulDB Meta Base Score: 8.5
VulDB Meta Temp Score: 8.5

VulDB Base Score: 7.3
VulDB Temp Score: 7.3
VulDB Vector: 🔍
VulDB Reliability: 🔍

NVD Base Score: 9.8
NVD Vector: 🔍

CVSSv2info

AVACAuCIA
💳💳💳💳💳💳
💳💳💳💳💳💳
💳💳💳💳💳💳
VectorComplexityAuthenticationConfidentialityIntegrityAvailability
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock

VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍

NVD Base Score: 🔍

Exploitinginfo

Class: Command injection
CWE: CWE-77 / CWE-74 / CWE-707
CAPEC: 🔍
ATT&CK: 🔍

Physical: No
Local: No
Remote: Yes

Availability: 🔍
Status: Not defined
Google Hack: 🔍

EPSS Score: 🔍
EPSS Percentile: 🔍

Price Prediction: 🔍
Current Price Estimation: 🔍

0-DayUnlockUnlockUnlockUnlock
TodayUnlockUnlockUnlockUnlock

Threat Intelligenceinfo

Interest: 🔍
Active Actors: 🔍
Active APT Groups: 🔍

Countermeasuresinfo

Recommended: no mitigation known
Status: 🔍

0-Day Time: 🔍

Timelineinfo

12/09/2018 🔍
05/13/2019 +155 days 🔍
05/14/2019 +1 days 🔍
09/15/2023 +1585 days 🔍

Sourcesinfo

Vendor: dlink.com

Advisory: github.com
Status: Not defined

CVE: CVE-2018-19986 (🔍)
GCVE (CVE): GCVE-0-2018-19986
GCVE (VulDB): GCVE-100-134624

Entryinfo

Created: 05/14/2019 07:14
Updated: 09/15/2023 18:52
Changes: 05/14/2019 07:14 (37), 06/09/2020 09:45 (18), 09/15/2023 18:52 (3)
Complete: 🔍
Cache ID: 216::103

VulDB is the best source for vulnerability data and more expert information about this specific topic.

Discussion

No comments yet. Languages: en.

Please log in to comment.

Do you want to use VulDB in your project?

Use the official API to access entries easily!