CVE-2025-22063 netlabel: Fix NULL pointer exception caused by CALIPSO on IPv4 sockets
A local attacker can cause a kernel crash by triggering a null pointer dereference in the netlabel CALIPSO module when using IPv4 sockets with IPv6 addresses.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2025-22063?
CVE-2025-22063 is a medium-severity vulnerability in Linux kernel, published on 16 Apr 2025. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
netlabel: Fix NULL pointer exception caused by CALIPSO on IPv4 sockets
When calling netlbl_conn_setattr(), addr->sa_family is used to determine the function behavior. If sk is an IPv4 socket, but the connect function is called with an IPv6 address, the function calipso_sock_setattr() is triggered. Inside this function, the following code is executed:
sk_fullsock(__sk) ? inet_sk(__sk)->pinet6 : NULL;
Since sk is an IPv4 socket, pinet6 is NULL, leading to a null pointer dereference.
This patch fixes the issue by checking if inet6_sk(sk) returns a NULL pointer before accessing pinet6.
Weakness: CWE-476
Which versions are affected by CVE-2025-22063?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2025-22063?
Apply the vendor's patch.
Is CVE-2025-22063 being exploited?
There is no known exploitation of CVE-2025-22063 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as AZL-61451, BELL-CVE-2025-22063, DEBIAN-CVE-2025-22063, GHSA-r764-27jf-q424, ROOT-OS-UBUNTU-2404-CVE-2025-22063, UBUNTU-CVE-2025-22063.