CVE Vulnerabilities

CVE-2023-2431

Improper Validation of Specified Type of Input

Published: Jun 16, 2023 | Modified: Dec 12, 2024
CVSS 3.x
5.5
MEDIUM
Source:
NVD
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
CVSS 2.x
RedHat/V2
RedHat/V3
3.4 LOW
CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:L/I:L/A:N
Ubuntu
MEDIUM

A security issue was discovered in Kubelet that allows pods to bypass the seccomp profile enforcement. Pods that use localhost type for seccomp profile but specify an empty profile field, are affected by this issue. In this scenario, this vulnerability allows the pod to run in unconfined (seccomp disabled) mode. This bug affects Kubelet.

Weakness

The product receives input that is expected to be of a certain type, but it does not validate or incorrectly validates that the input is actually of the expected type.

Affected Software

Name Vendor Start Version End Version
Kubernetes Kubernetes * 1.24.14 (excluding)
Kubernetes Kubernetes 1.25.0 (including) 1.25.10 (excluding)
Kubernetes Kubernetes 1.26.0 (including) 1.26.5 (excluding)
Kubernetes Kubernetes 1.27.0 (including) 1.27.2 (excluding)
Red Hat OpenShift Container Platform 4.13 RedHat openshift4-wincw/windows-machine-config-rhel9-operator:8.1.0-24 *
Kubernetes Ubuntu bionic *
Kubernetes Ubuntu kinetic *
Kubernetes Ubuntu lunar *
Kubernetes Ubuntu mantic *
Kubernetes Ubuntu trusty *
Kubernetes Ubuntu upstream *
Kubernetes Ubuntu xenial *

Extended Description

When input does not comply with the expected type, attackers could trigger unexpected errors, cause incorrect actions to take place, or exploit latent vulnerabilities that would not be possible if the input conformed with the expected type. This weakness can appear in type-unsafe programming languages, or in programming languages that support casting or conversion of an input to another type.

Potential Mitigations

  • 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.

References