Lucene search

K
cvelistLinuxCVELIST:CVE-2024-35962
HistoryMay 20, 2024 - 9:41 a.m.

CVE-2024-35962 netfilter: complete validation of user input

2024-05-2009:41:53
Linux
www.cve.org
5
linux kernel
vulnerability
netfilter
validation
user input
commit
handlers
copy_from_sockptr
unsafe
optlen
xt_alloc_table_info
check

AI Score

6.4

Confidence

Low

EPSS

0

Percentile

10.3%

In the Linux kernel, the following vulnerability has been resolved:

netfilter: complete validation of user input

In my recent commit, I missed that do_replace() handlers
use copy_from_sockptr() (which I fixed), followed
by unsafe copy_from_sockptr_offset() calls.

In all functions, we can perform the @optlen validation
before even calling xt_alloc_table_info() with the following
check:

if ((u64)optlen < (u64)tmp.size + sizeof(tmp))
return -EINVAL;

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "net/ipv4/netfilter/arp_tables.c",
      "net/ipv4/netfilter/ip_tables.c",
      "net/ipv6/netfilter/ip6_tables.c"
    ],
    "versions": [
      {
        "version": "0f038242b77d",
        "lessThan": "cf4bc359b761",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "440e948cf0ef",
        "lessThan": "97dab36e57c6",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "18aae2cb87e5",
        "lessThan": "c760089aa982",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "81d51b9b7c95",
        "lessThan": "89242d9584c3",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "58f2bfb789e6",
        "lessThan": "562b7245131f",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "0c83842df40f",
        "lessThan": "65acf6e0501a",
        "status": "affected",
        "versionType": "git"
      }
    ]
  },
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "net/ipv4/netfilter/arp_tables.c",
      "net/ipv4/netfilter/ip_tables.c",
      "net/ipv6/netfilter/ip6_tables.c"
    ],
    "versions": [
      {
        "version": "5.10.215",
        "lessThan": "5.10.216",
        "status": "affected",
        "versionType": "custom"
      },
      {
        "version": "5.15.154",
        "lessThan": "5.15.156",
        "status": "affected",
        "versionType": "custom"
      },
      {
        "version": "6.1.85",
        "lessThan": "6.1.87",
        "status": "affected",
        "versionType": "custom"
      },
      {
        "version": "6.6.26",
        "lessThan": "6.6.28",
        "status": "affected",
        "versionType": "custom"
      },
      {
        "version": "6.8.5",
        "lessThan": "6.8.7",
        "status": "affected",
        "versionType": "custom"
      }
    ]
  }
]

AI Score

6.4

Confidence

Low

EPSS

0

Percentile

10.3%