CVE-2021-23399: Arbitrary Command Injection in wincred

wincred Updated 02 Oct 2025

Summary

29/06/2021
No i
Critical
9.8

CVE-2021-23399: Arbitrary Command Injection. Affects wincred versions < 1.0.2. No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The wincred package is an npm package that provides functionality for managing Windows credentials. It allows users to store and retrieve credentials securely. The package is widely used in Windows-based applications and is an essential component for managing user authentication and authorization. However, all versions of the wincred package are vulnerable to arbitrary command injection.

Vulnerability Detail

The vulnerability (CVE-2021-23399) in the wincred package arises from the getCredential function's failure to properly sanitize user input. If an attacker-controlled user input is passed to this function, it can lead to the execution of arbitrary commands. The vulnerability stems from the use of the child_process exec function without input sanitization. This allows an attacker to inject malicious commands, potentially leading to unauthorized access, data breaches, or system compromise. The severity of this vulnerability is rated as CRITICAL with a CVSS score of 9.8.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

As a temporary workaround, developers can implement input sanitization and validation manually before passing user input to the getCredential function. This can involve filtering out any potentially malicious characters or using input validation libraries. However, it is strongly advised to update to the latest version of the wincred package as soon as possible.

Conclusion

The wincred package is vulnerable to arbitrary command injection, which can have severe consequences such as unauthorized access and data breaches. It is crucial to update to the latest version of the package (1.0.3 or above) and implement proper input sanitization and validation. For further support on vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for wincred →

Share this vulnerability

FAQ

The wincred package is an npm package used for managing Windows credentials securely.

The vulnerability (CVE-2021-23399) is an arbitrary command injection issue that allows attackers to execute arbitrary commands by providing malicious user input to the getCredential function.

The vulnerability can lead to unauthorized access, data breaches, or compromise of the affected system.

To fix this vulnerability, update the wincred package to version 1.0.3 or above and ensure proper input sanitization and validation.

As a temporary workaround, implement input sanitization and validation manually before passing user input to the getCredential function. However, updating to the latest version is strongly recommended.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback