CVE-2025-40018
Vulnerability Summary
Timeline
Description
In the Linux kernel, the following vulnerability has been resolved: ipvs: Defer ip_vs_ftp unregister during netns cleanup On the netns cleanup path, __ip_vs_ftp_exit() may unregister ip_vs_ftp before connections with valid cp->app pointers are flushed, leading to a use-after-free. Fix this by introducing a global `exiting_module` flag, set to true in ip_vs_ftp_exit() before unregistering the pernet subsystem. In __ip_vs_ftp_exit(), skip ip_vs_ftp unregister if called during netns cleanup (when exiting_module is false) and defer it to __ip_vs_cleanup_batch(), which unregisters all apps after all connections are flushed. If called during module exit, unregister ip_vs_ftp immediately.
CVSS Metrics
- v3.1•HIGH•Score: 7.8CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS Trends
Current EPSS score: 0.14%• Percentile: 4%
Affected Systems
- debian•linux
< 5.10.247-1 | < 6.1.158-1 | < 6.12.57-1 | < 6.17.6-1
- debian•linux-6.1
< 6.1.158-1~deb11u1
- ubuntu•linux
all | < 4.4.0-276.310 | < 4.15.0-245.257 | < 5.4.0-224.244 | < 5.15.0-164.174 | < 6.8.0-90.91 | < 6.17.0-8.8
- ubuntu•linux-allwinner-5.19
all
- ubuntu•linux-aws
< 4.4.0-1150.156 | < 4.4.0-1188.203 | < 4.15.0-1187.200 | < 5.4.0-1153.163 | < 5.15.0-1098.105 | < 6.8.0-1044.46 | < 6.17.0-1005.5
- ubuntu•linux-aws-5.0
all
- ubuntu•linux-aws-5.11
all
- ubuntu•linux-aws-5.13
all
- ubuntu•linux-aws-5.15
< 5.15.0-1098.105~20.04.1
- ubuntu•linux-aws-5.19
all
- ubuntu•linux-aws-5.3
all
- ubuntu•linux-aws-5.4
< 5.4.0-1153.163~18.04.1
- ubuntu•linux-aws-5.8
all
- ubuntu•linux-aws-6.14
< 6.14.0-1018.18~24.04.1
- ubuntu•linux-aws-6.2
all
- ubuntu•linux-aws-6.5
all
- ubuntu•linux-aws-6.8
< 6.8.0-1044.46~22.04.1
- ubuntu•linux-aws-fips
< 4.15.0-2125.131 | all | < 5.4.0-1153.163+fips1 | < 5.15.0-1098.105+fips1 | < 6.8.0-1044.46+fips1
- ubuntu•linux-aws-hwe
< 4.15.0-1187.200~16.04.1
- ubuntu•linux-azure
< 4.15.0-1195.210~14.04.1 | < 4.15.0-1195.210~16.04.1 | all | < 5.4.0-1156.163 | < 5.15.0-1102.111 | < 6.8.0-1044.50 | < 6.17.0-1006.6
- ubuntu•linux-azure-4.15
< 4.15.0-1195.210
- ubuntu•linux-azure-5.11
all
- ubuntu•linux-azure-5.13
all
- ubuntu•linux-azure-5.15
< 5.15.0-1102.111~20.04.1
- ubuntu•linux-azure-5.19
all
- ubuntu•linux-azure-5.3
all
- ubuntu•linux-azure-5.4
< 5.4.0-1156.163~18.04.1
- ubuntu•linux-azure-5.8
all
- ubuntu•linux-azure-6.11
all
- ubuntu•linux-azure-6.14
< 6.14.0-1017.17~24.04.1
- ubuntu•linux-azure-6.2
all
- ubuntu•linux-azure-6.5
all
- ubuntu•linux-azure-6.8
< 6.8.0-1044.50~22.04.1
- ubuntu•linux-azure-edge
all
- ubuntu•linux-azure-fde
all | all | all | all
- ubuntu•linux-azure-fde-5.19
all
- ubuntu•linux-azure-fde-6.14
all
- ubuntu•linux-azure-fde-6.2
all
- ubuntu•linux-azure-fde-6.8
all
- ubuntu•linux-azure-fips
< 4.15.0-2104.110 | all | < 5.4.0-1157.164+fips1 | < 5.15.0-1102.111+fips1 | < 6.8.0-1044.50+fips1
- ubuntu•linux-azure-nvidia
< 6.8.0-1029.32
- ubuntu•linux-azure-nvidia-6.14
all
- ubuntu•linux-bluefield
all | < 5.4.0-1112.119 | < 5.15.0-1082.84 | < 6.8.0-1014.18
- ubuntu•linux-fips
< 4.4.0-1120.127 | all | < 4.15.0-1142.154 | < 5.4.0-1127.137 | < 5.15.0-164.174+fips1 | < 6.8.0-90.91+fips1
- ubuntu•linux-gcp
< 4.15.0-1180.197~16.04.1 | all | < 5.4.0-1156.165 | < 5.15.0-1098.107 | < 6.8.0-1045.48 | < 6.17.0-1005.5
- ubuntu•linux-gcp-4.15
< 4.15.0-1180.197
- ubuntu•linux-gcp-5.11
all
- ubuntu•linux-gcp-5.13
all
- ubuntu•linux-gcp-5.15
< 5.15.0-1098.107~20.04.1
- ubuntu•linux-gcp-5.19
all
Showing first 50 affected entries in server-rendered view.
References (47)
- https://git.kernel.org/stable/c/8a6ecab3847c213ce2855b0378e63ce839085de3
- https://git.kernel.org/stable/c/421b1ae1574dfdda68b835c15ac4921ec0030182
- https://git.kernel.org/stable/c/1d79471414d7b9424d699afff2aa79fff322f52d
- https://git.kernel.org/stable/c/53717f8a4347b78eac6488072ad8e5adbaff38d9
- https://git.kernel.org/stable/c/8cbe2a21d85727b66d7c591fd5d83df0d8c4f757
- https://git.kernel.org/stable/c/dc1a481359a72ee7e548f1f5da671282a7c13b8f
- https://git.kernel.org/stable/c/a343811ef138a265407167294275201621e9ebb2
- https://git.kernel.org/stable/c/134121bfd99a06d44ef5ba15a9beb075297c0821
- https://ubuntu.com/security/CVE-2025-40018
- https://www.cve.org/CVERecord?id=CVE-2025-40018
- https://git.kernel.org/linus/134121bfd99a06d44ef5ba15a9beb075297c0821
- https://ubuntu.com/security/notices/USN-7907-1
- https://ubuntu.com/security/notices/USN-7907-2
- https://ubuntu.com/security/notices/USN-7907-3
- https://ubuntu.com/security/notices/USN-7907-4
- https://ubuntu.com/security/notices/USN-7920-1
- https://ubuntu.com/security/notices/USN-7921-1
- https://ubuntu.com/security/notices/USN-7922-1
- https://ubuntu.com/security/notices/USN-7922-2
- https://ubuntu.com/security/notices/USN-7928-1
- https://ubuntu.com/security/notices/USN-7928-2
- https://ubuntu.com/security/notices/USN-7928-3
- https://ubuntu.com/security/notices/USN-7907-5
- https://ubuntu.com/security/notices/USN-7930-1
- https://ubuntu.com/security/notices/USN-7930-2
- https://ubuntu.com/security/notices/USN-7931-1
- https://ubuntu.com/security/notices/USN-7931-2
- https://ubuntu.com/security/notices/USN-7931-3
- https://ubuntu.com/security/notices/USN-7934-1
- https://ubuntu.com/security/notices/USN-7920-2
- https://ubuntu.com/security/notices/USN-7935-1
- https://ubuntu.com/security/notices/USN-7936-1
- https://ubuntu.com/security/notices/USN-7937-1
- https://ubuntu.com/security/notices/USN-7938-1
- https://ubuntu.com/security/notices/USN-7939-1
- https://ubuntu.com/security/notices/USN-7939-2
- https://ubuntu.com/security/notices/USN-7940-1
- https://ubuntu.com/security/notices/USN-7921-2
- https://ubuntu.com/security/notices/USN-7922-3
- https://ubuntu.com/security/notices/USN-7928-4
- https://ubuntu.com/security/notices/USN-7931-4
- https://ubuntu.com/security/notices/USN-7922-4
- https://ubuntu.com/security/notices/USN-7928-5
- https://ubuntu.com/security/notices/USN-7931-5
- https://ubuntu.com/security/notices/USN-7940-2
- https://ubuntu.com/security/notices/USN-7922-5
- https://security-tracker.debian.org/tracker/CVE-2025-40018