Skip to content
OpenAdvisories

Weakness (CWE)

CWE-20: Improper Input Validation

Class Mapping discouraged

The product receives input or data, but it does
not validate or incorrectly validates that the input has the
properties that are required to process the data safely and
correctly.

How to prevent it (8 mitigations)
  1. Architecture and Design

    Consider using language-theoretic security (LangSec) techniques that characterize inputs using a formal language and build "recognizers" for that language. This effectively requires parsing to be a distinct layer that effectively enforces a boundary between raw input and internal data representations, instead of allowing parser code to be scattered throughout the program, where it could be subject to errors or inconsistencies that create weaknesses. [REF-1109] [REF-1110] [REF-1111]

  2. Architecture and Design

    Use an input validation framework such as Struts or the OWASP ESAPI Validation API. Note that using a framework does not automatically address all input validation problems; be mindful of weaknesses that could arise from misusing the framework itself (CWE-1173).

  3. Architecture and Design, Implementation

    Understand all the potential areas where untrusted inputs can enter the product, including but not limited to: parameters or arguments, cookies, anything read from the network, environment variables, reverse DNS lookups, query results, request headers, URL components, e-mail, files, filenames, databases, and any external systems that provide data to the application. Remember that such inputs may be obtained indirectly through API calls.

  4. Implementation

    Assume all input is malicious. Use an "accept known good" input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does.

    When performing input validation, consider all potentially relevant properties, including length, type of input, the full range of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, "boat" may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as "red" or "blue."

    Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code's environment changes. This can give attackers enough room to bypass the intended validation. However, denylists can be useful for detecting potential attacks or determining which inputs are so malformed that they should be rejected outright.

  5. Architecture and Design

    For any security checks that are performed on the client side, ensure that these checks are duplicated on the server side, in order to avoid CWE-602. Attackers can bypass the client-side checks by modifying values after the checks have been performed, or by changing the client to remove the client-side checks entirely. Then, these modified values would be submitted to the server.

    Even though client-side checks provide minimal benefits with respect to server-side security, they are still useful. First, they can support intrusion detection. If the server receives input that should have been rejected by the client, then it may be an indication of an attack. Second, client-side error-checking can provide helpful feedback to the user about the expectations for valid input. Third, there may be a reduction in server-side processing time for accidental input errors, although this is typically a small savings.

  6. Implementation

    When your application combines data from multiple sources, perform the validation after the sources have been combined. The individual data elements may pass the validation step but violate the intended restrictions after they have been combined.

  7. Implementation

    Be especially careful to validate all input when invoking code that crosses language boundaries, such as from an interpreted language to native code. This could create an unexpected interaction between the language boundaries. Ensure that you are not violating any of the expectations of the language with which you are interfacing. For example, even though Java may not be susceptible to buffer overflows, providing a large argument in a call to native code might trigger an overflow.

  8. Implementation

    Directly convert your input type into the expected data type, such as using a conversion function that translates a string into a number. After converting to the expected data type, ensure that the input's values fall within the expected range of allowable values and that multi-field consistencies are maintained.

Source: MITRE CWE-20

702 results · Clear filters · Feed

  • Critical 9.3

    Improper Sanitization of Branch Name Leads to Arbitrary Code Injection

    tj-actions/branch-names is a Github action to retrieve branch or tag names with support for all events. The `tj-actions/branch-names` GitHub Actions improperly references the `github.event.pull_request.head.ref` and `github.head_ref` context variables within …

  • Critical 9.1

    Ability to DoS the testing infrastructure by overwriting files

    TestingPlatform is a testing platform for Internet Security Standards. Prior to version 2.1.1, user input is not filtered correctly. Nmap options are accepted. In this particular case, the option to create log files is accepted in addition to a host name (and…

  • Critical 9.8

    An issue in RedisGraph v.2.12.10 allows an attacker to execute arbitrary code and cause a denial of service via a craft…

  • Critical 9.0

    Improper Input Validation in Core

    Memory corruption in core services when Diag handler receives a command to configure event listeners.

  • Critical 9.3

    Improper Input Validation in Core

    Memory Corruption in Core during syscall for Sectools Fuse comparison feature.

  • Critical 9.9

    1E-Exchange-DisplayMessage instruction allows for arbitrary code execution

    The 1E-Exchange-DisplayMessageinstruction that is part of the End-User Interaction product pack available on the 1E Exchange does not properly validate the Caption or Message parameters, which allows for a specially crafted input to perform arbitrary code exe…

  • Critical 9.9

    1E-Exchange-CommandLinePing instruction before v18.1 allows for arbitrary code execution

    The 1E-Exchange-CommandLinePing instruction that is part of the Network product pack available on the 1E Exchange does not properly validate the input parameter, which allows for a specially crafted input to perform arbitrary code execution with SYSTEM permis…

  • Critical 9.9

    1E-Exchange-URLResponseTime instruction before v20.1 allows arbitrary code execution

    The 1E-Exchange-URLResponseTime instruction that is part of the Network product pack available on the 1E Exchange does not properly validate the URL parameter, which allows for a specially crafted input to perform arbitrary code execution with SYSTEM permissi…

  • Critical 10.0

    GLPI vulnerable to unallowed PHP script execution

    GLPI is a free asset and IT management software package. Starting in version 10.0.7 and prior to version 10.0.10, an unverified object instantiation allows one to upload malicious PHP files to unwanted directories. Depending on web server configuration and av…

  • Critical 9.1

    Improper Input Validation in mintplex-labs/anything-llm

    Improper Input Validation in GitHub repository mintplex-labs/anything-llm prior to 0.1.0.

  • Critical 10.0

    CSRF Token Reuse Vulnerability in fiber

    Fiber is an express inspired web framework written in Go. A Cross-Site Request Forgery (CSRF) vulnerability has been identified in the application, which allows an attacker to inject arbitrary values and forge malicious requests on behalf of a user. This vuln…

  • Critical 9.8

    Microsoft Message Queuing (MSMQ) Remote Code Execution Vulnerability

    Microsoft Message Queuing (MSMQ) Remote Code Execution Vulnerability

  • Critical 9.8

    Dell SmartFabric Storage Software version 1.3 and lower contain an improper input validation vulnerability. A remote un…

  • Critical 9.1

    Hydra's committed UTxOs at Commit validator and UTxOs at Initial validator can be spent arbitrarily by anyone

    Hydra is the layer-two scalability solution for Cardano. Users of the Hydra head protocol send the UTxOs they wish to commit into the Hydra head first to the `commit` validator, where they remain until they are either collected into the `head` validator or th…

  • Critical 10.0
    CVE-2023-22515 Exploited · Ransomware Public exploit Scanner template EPSS 99%

    Atlassian has been made aware of an issue reported by a handful of customers where external attackers may have exploite…

    KEV Oct 5, 2023
  • Critical 9.9
    CVE-2023-3710 Public exploit Scanner template EPSS 49%

    Printer web page invalid command execution

    Improper Input Validation vulnerability in Honeywell PM43 on 32 bit, ARM (Printer web page modules) allows Command Injection.This issue affects PM43 versions prior to P10.19.050004. Update to the latest available firmware version of the respective printers to…

  • Critical 9.8
    CVE-2023-2071 EPSS 17%

    FactoryTalk View Machine Edition Vulnerable to Remote Code Execution

    Rockwell Automation FactoryTalk View Machine Edition on the PanelView Plus, improperly verifies user’s input, which allows unauthenticated attacker to achieve remote code executed via crafted malicious packets.  The device has the functionality, through a CIP…

  • Critical 9.1

    Adobe Commerce post-auth improper input validation leads to remote code execution

    Adobe Commerce versions 2.4.3-p1 (and earlier) and 2.3.7-p2 (and earlier) are affected by an improper input validation vulnerability. Exploitation of this issue does not require user interaction and could result in a post-authentication arbitrary code executi…

  • Critical 9.8

    Apache Axis 1.x (EOL) may allow RCE when untrusted input is passed to getService

    ** UNSUPPORTED WHEN ASSIGNED ** When integrating Apache Axis 1.x in an application, it may not have been obvious that looking up a service through "ServiceFactory.getService" allows potentially dangerous lookup mechanisms such as LDAP. When passing untrusted …

  • Critical 9.9

    Authenticated Remote Command Execution in Danfoss AK-SM800A

    Due to improper input validation, an authenticated remote attacker could execute arbitrary commands on the target system.

  • Critical 9.8
    CVE-2023-2917 Public exploit EPSS 72%

    Rockwell Automation ThinManager Thinserver Software Vulnerable to Input Validation Vulnerability

    The Rockwell Automation Thinmanager Thinserver is impacted by an improper input validation vulnerability.  Due to an improper input validation, a path traversal vulnerability exists, via the filename field, when the ThinManager processes a certain function. I…

  • Critical 9.8

    SES's dynamic import and spread operator provides possible path to arbitrary exfiltration and execution

    SES is a JavaScript environment that allows safe execution of arbitrary programs in Compartments. In version 0.18.0 prior to 0.18.7, 0.17.0 prior to 0.17.1, 0.16.0 prior to 0.16.1, 0.15.0 prior to 0.15.24, 0.14.0 prior to 0.14.5, an 0.13.0 prior to 0.13.5, th…

  • Critical 9.1

    TLS 1.3 client issue handling malicious server when not including a KSE and PSK extension

    If a TLS 1.3 client gets neither a PSK (pre shared key) extension nor a KSE (key share extension) when connecting to a malicious server, a default predictable buffer gets used for the IKM (Input Keying Material) value when generating the session master secret…

  • Critical 9.8

    Microsoft Message Queuing (MSMQ) Remote Code Execution Vulnerability

    Microsoft Message Queuing (MSMQ) Remote Code Execution Vulnerability

  • Critical 9.8

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

  • Critical 9.8

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

  • Critical 9.8

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

    Windows Routing and Remote Access Service (RRAS) Remote Code Execution Vulnerability

  • Critical 9.8

    Apache Airflow Hive Provider Beeline RCE with Principal

    Improper Input Validation vulnerability in Apache Software Foundation Apache Airflow Hive Provider. This issue affects Apache Airflow Apache Hive Provider: before 6.1.1. Before version 6.1.1 it was possible to bypass the security check to RCE via principal pa…

  • Critical 9.6

    A vulnerability in the change password functionality of Cisco Expressway Series and Cisco TelePresence Video Communicat…

  • Critical 9.6

    Cisco Expressway Series and Cisco TelePresence Video Communication Server Privilege Escalation Vulnerabilities

    Multiple vulnerabilities in Cisco Expressway Series and Cisco TelePresence Video Communication Server (VCS) could allow an authenticated attacker with Administrator-level read-only credentials to elevate their privileges to Administrator with read-write crede…

  • Critical 9.8

    Windows Pragmatic General Multicast (PGM) Remote Code Execution Vulnerability

    Windows Pragmatic General Multicast (PGM) Remote Code Execution Vulnerability

  • Critical 9.8
    CVE-2023-34152 Public exploit

    A vulnerability was found in ImageMagick. This security flaw cause a remote code execution vulnerability in OpenBlob wi…

  • Critical 9.8

    CKAN remote code execution and private information access via crafted resource ids

    CKAN is an open-source data management system for powering data hubs and data portals. Multiple vulnerabilities have been discovered in Ckan which may lead to remote code execution. An arbitrary file write in `resource_create` and `package_update` actions, us…

  • Critical 9.4
    CVE-2023-2868 Exploited Public exploit EPSS 87%

    Remote Code injection in Barracuda Email Security Gateway

    A remote command injection vulnerability exists in the Barracuda Email Security Gateway (appliance form factor only) product effecting versions 5.1.3.001-9.2.0.006. The vulnerability arises out of a failure to comprehensively sanitize the processing of .tar f…

    KEV May 26, 2023
  • Critical 9.8

    Multiple parsing problems in the Apache Sling Commons JSON module

    Improper input validation in the Apache Sling Commons JSON bundle allows an attacker to trigger unexpected errors by supplying specially-crafted input. The org.apache.sling.commons.json bundle has been deprecated as of March 2017 and should not be used anymor…

  • Critical 9.1

    Improper Input Validation in Web Interface

    An Improper Input Validation vulnerability in the Schweitzer Engineering Laboratories Real-Time Automation Controller (SEL RTAC) Web Interface could allow a remote authenticated attacker to execute arbitrary code. See SEL Service Bulletin dated 2022-11-15 for…

  • Critical 9.1

    Improper Input Validation in Web Interface

    An Improper Input Validation vulnerability in the Schweitzer Engineering Laboratories Real-Time Automation Controller (SEL RTAC) Web Interface could allow a remote authenticated attacker to execute arbitrary code. See SEL Service Bulletin dated 2022-11-15 for…

  • Critical 9.8

    Apache bRPC: ServerOptions.pid_file may cause arbitrary code execution

    Security vulnerability in Apache bRPC <1.5.0 on all platforms allows attackers to execute arbitrary code via ServerOptions::pid_file. An attacker that can influence the ServerOptions pid_file parameter with which the bRPC server is started can execute arbitra…

  • Critical 9.8

    Django bypasses validation when using one form field to upload multiple files

    In Django 3.2 before 3.2.19, 4.x before 4.1.9, and 4.2 before 4.2.1, it was possible to bypass validation when using one form field to upload multiple files. This multiple upload has never been supported by forms.FileField or forms.ImageField (only the last u…

  • Critical 9.1

    Apache StreamPark (incubating): Logic error causing any account reset

    Apache StreamPark 1.0.0 before 2.0.0 When the user successfully logs in, to modify his profile, the username will be passed to the server-layer as a parameter, but not verified whether the user name is the currently logged user and whether the user is legal, …