CVE-2026-45887

af_unix: Fix memleak of newsk in unix_stream_connect().

State
Published
Severity
Not scored
Published
May 27, 2026
Updated
May 27, 2026
Reserved
May 13, 2026

Read the record on cve.org

Description

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

af_unix: Fix memleak of newsk in unix_stream_connect().

When prepare_peercred() fails in unix_stream_connect(), unix_release_sock() is not called for newsk, and the memory is leaked.

Let's move prepare_peercred() before unix_create1().

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • fd0a109a0f6b7524543d17520da92a44a9f5343c to before 365996a2b14d07caa9e33d367b67ea26c09d89b4Affected
  • fd0a109a0f6b7524543d17520da92a44a9f5343c to before a5d95d7caba0160fb7b2b8d2bd96d5a1be861d9fAffected
  • fd0a109a0f6b7524543d17520da92a44a9f5343c to before 6884028cd7f275f8bcb854a347265cb1fb0e4beaAffected
LinuxLinux
  • 6.16Affected
  • before 6.16Not affected
  • 6.18.14 through 6.18.*Not affected
  • 6.19.4 through 6.19.*Not affected
  • 7.0 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.