Command Injection

Affecting systeminformation package, versions <4.31.1

Report new vulnerabilities
Do your applications use this vulnerable package? Test your applications

Overview

systeminformation is a simple system and OS information library.

Affected versions of this package are vulnerable to Command Injection. The sanitizeShellString function does not sanitize quotation marks, which could be leveraged by an attacker to execute arbitrary commands.

PoC

const si = require('systeminformation');
si.inetLatency("`<OS command>`");

Remediation

Upgrade systeminformation to version 4.31.1 or higher.

References

CVSS Score

8.2
high severity
  • Attack Vector
    Network
  • Attack Complexity
    Low
  • Privileges Required
    None
  • User Interaction
    None
  • Scope
    Unchanged
  • Confidentiality
    High
  • Integrity
    Low
  • Availability
    None
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N/E:P/RL:O/RC:C
Credit
EffectRenan
CVE
CVE-2020-26274
CWE
CWE-78
Snyk ID
SNYK-JS-SYSTEMINFORMATION-1050436
Disclosed
11 Dec, 2020
Published
14 Dec, 2020