---
id: CVE-2022-50201
title: 'selinux: fix memleak in security_read_state_kernel()'
summary: |-
  In the Linux kernel, the following vulnerability has been resolved:

  selinux: fix memleak in security_read_state_kernel()

  In this function, it directly returns the result of __security_read_policy
  without freeing the allocated memory in…
severity: none
vendor: Linux
product: Linux
affected:
  - >-
    Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 <
    c877c5217145bda8fd95f506bf42f8d981afa57d
  - >-
    Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 <
    f3cd7562c0a6774fc62d79654482014020e574f5
  - >-
    Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 <
    1fc1f72aad2070d34022d0823e4cf09706b53f25
  - >-
    Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 <
    73de1befcc53a7c68b0c5e76b9b5ac41c517760f
  - Linux 5.12
ssvc:
  exploitation: none
  automatable: 'no'
  technicalImpact: partial
  timestamp: '2026-11-05T20:06:48.659486Z'
published: '2025-06-18'
updated: '2026-11-05'
sourceUpdated: '2026-11-05T20:10:28.710Z'
source: CVEORG
sourceUrl: 'https://www.cve.org/CVERecord?id=CVE-2022-50201'
references:
  - url: 'https://git.kernel.org/stable/c/c877c5217145bda8fd95f506bf42f8d981afa57d'
  - url: 'https://git.kernel.org/stable/c/f3cd7562c0a6774fc62d79654482014020e574f5'
  - url: 'https://git.kernel.org/stable/c/1fc1f72aad2070d34022d0823e4cf09706b53f25'
  - url: 'https://git.kernel.org/stable/c/73de1befcc53a7c68b0c5e76b9b5ac41c517760f'
tags:
  - cve.org
epss: 0.00245
epssPercentile: 0.15841
ingestedAt: '2026-11-05T22:38:31.703Z'
---

## Overview

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

selinux: fix memleak in security_read_state_kernel()

In this function, it directly returns the result of __security_read_policy
without freeing the allocated memory in *data, cause memory leak issue,
so free the memory if __security_read_policy failed.

[PM: subject line tweak]

## Affected

- `Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 < c877c5217145bda8fd95f506bf42f8d981afa57d`
- `Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 < f3cd7562c0a6774fc62d79654482014020e574f5`
- `Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 < 1fc1f72aad2070d34022d0823e4cf09706b53f25`
- `Linux >= fdd1ffe8a812b1109388e4bc389e57b2695ad095 < 73de1befcc53a7c68b0c5e76b9b5ac41c517760f`
- `Linux 5.12`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
