Lucene search

K
cvelistLinuxCVELIST:CVE-2021-47009
HistoryFeb 28, 2024 - 8:13 a.m.

CVE-2021-47009 KEYS: trusted: Fix memory leak on object td

2024-02-2808:13:28
Linux
www.cve.org
linux kernel
vulnerability
memory leak
fix
clang scan-build
warning
security keys
trusted
tpm1

6.6 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

15.6%

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

KEYS: trusted: Fix memory leak on object td

Two error return paths are neglecting to free allocated object td,
causing a memory leak. Fix this by returning via the error return
path that securely kfree’s td.

Fixes clang scan-build warning:
security/keys/trusted-keys/trusted_tpm1.c:496:10: warning: Potential
memory leak [unix.Malloc]

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "security/keys/trusted-keys/trusted_tpm1.c"
    ],
    "versions": [
      {
        "version": "9d83cc1a1e7f",
        "lessThan": "31c9a4b24d86",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "8cfc8d629421",
        "lessThan": "1c4031014106",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "5df16caada3f",
        "lessThan": "3e24fbd37e72",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "5df16caada3f",
        "lessThan": "83a775d5f9bf",
        "status": "affected",
        "versionType": "git"
      }
    ]
  },
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "affected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "security/keys/trusted-keys/trusted_tpm1.c"
    ],
    "versions": [
      {
        "version": "5.12",
        "status": "affected"
      },
      {
        "version": "0",
        "lessThan": "5.12",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.10.38",
        "lessThanOrEqual": "5.10.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.11.22",
        "lessThanOrEqual": "5.11.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.12.5",
        "lessThanOrEqual": "5.12.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.13",
        "lessThanOrEqual": "*",
        "status": "unaffected",
        "versionType": "original_commit_for_fix"
      }
    ]
  }
]

6.6 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

15.6%