Base · Medium

CWE-214: Invocation of Process Using Visible Sensitive Information

A process is invoked with sensitive command-line arguments, environment variables, or other elements that can be seen by other processes on the operating system.

CWE-214 · Base Level ·8 CVEs

Description

A process is invoked with sensitive command-line arguments, environment variables, or other elements that can be seen by other processes on the operating system.

Many operating systems allow a user to list information about processes that are owned by other users. Other users could see information such as command line arguments or environment variable settings. When this data contains sensitive information such as credentials, it might allow other users to launch an attack against the product or related resources.

Potential Impact

Confidentiality

Read Application Data

Demonstrative Examples

In the example below, the password for a keystore file is read from a system property.
Bad
String keystorePass = System.getProperty("javax.net.ssl.keyStorePassword");if (keystorePass == null) {System.err.println("ERROR: Keystore password not specified.");System.exit(-1);}
                     ...
If the property is defined on the command line when the program is invoked (using the -D... syntax), the password may be displayed in the OS process list.

Real-World CVE Examples

CVE IDDescription
CVE-2023-38994IAM product includes LDAP password in a process call, allowing local users to obtain the password
CVE-2005-1387password passed on command line
CVE-2005-2291password passed on command line
CVE-2001-1565username/password on command line allows local users to view via "ps" or other process listing programs
CVE-2004-1948Username/password on command line allows local users to view via "ps" or other process listing programs.
CVE-1999-1270PGP passphrase provided as command line argument.
CVE-2004-1058Kernel race condition allows reading of environment variables of a process that is still spawning.
CVE-2021-32638Code analysis product passes access tokens as a command-line parameter or through an environment variable, making them visible to other processes via the ps command.

Taxonomy Mappings

  • PLOVER: — Process information infoleak to other processes
  • Software Fault Patterns: SFP23 — Exposed Data

Frequently Asked Questions

What is CWE-214?

CWE-214 (Invocation of Process Using Visible Sensitive Information) is a software weakness identified by MITRE's Common Weakness Enumeration. It is classified as a Base-level weakness. A process is invoked with sensitive command-line arguments, environment variables, or other elements that can be seen by other processes on the operating system.

How can CWE-214 be exploited?

Attackers can exploit CWE-214 (Invocation of Process Using Visible Sensitive Information) to read application data. This weakness is typically introduced during the Architecture and Design, Implementation, Operation phase of software development.

How do I prevent CWE-214?

Follow secure coding practices, conduct code reviews, and use automated security testing tools (SAST/DAST) to detect this weakness early in the development lifecycle.

What is the severity of CWE-214?

CWE-214 is classified as a Base-level weakness (Medium abstraction). It has been observed in 8 real-world CVEs.