7.8high
ipvs: Defer ip_vs_ftp unregister during netns cleanup
- Severity
- 7.8high CVSS:3.1 by Linux
- Exploit likelihood
- 0.15% (higher than 4% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Linux
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.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Linux Linux | from 61b1ab4583e275af216c8454b9256de680499b19 before 8a6ecab3847c213ce2855b0378e63ce839085de3, from 61b1ab4583e275af216c8454b9256de680499b19 before 421b1ae1574dfdda68b835c15ac4921ec0030182, from 61b1ab4583e275af216c8454b9256de680499b19 before 1d79471414d7b9424d699afff2aa79fff322f52d, from 61b1ab4583e275af216c8454b9256de680499b19 before 53717f8a4347b78eac6488072ad8e5adbaff38d9, from 61b1ab4583e275af216c8454b9256de680499b19 before 8cbe2a21d85727b66d7c591fd5d83df0d8c4f757, from 61b1ab4583e275af216c8454b9256de680499b19 before dc1a481359a72ee7e548f1f5da671282a7c13b8f, from 61b1ab4583e275af216c8454b9256de680499b19 before a343811ef138a265407167294275201621e9ebb2, from 61b1ab4583e275af216c8454b9256de680499b19 before 134121bfd99a06d44ef5ba15a9beb075297c0821 and 1 more Not affected: before 2.6.39, from 5.4.301 up to 5.4.*, from 5.10.246 up to 5.10.*, from 5.15.195 up to 5.15.*, from 6.1.156 up to 6.1.*, from 6.6.112 up to 6.6.* | CVE List |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.
What each source says
CVE List
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.
NVD (es)
En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: ipvs: Aplazar la anulación de registro de ip_vs_ftp durante la limpieza de netns En la ruta de limpieza de netns, __ip_vs_ftp_exit() puede anular el registro de ip_vs_ftp antes de que se vacíen las conexiones con punteros cp->app válidos, lo que lleva a un uso después de liberación. Esto se soluciona introduciendo una bandera global 'exiting_module', establecida en verdadero en ip_vs_ftp_exit() antes de anular el registro del subsistema pernet. En __ip_vs_ftp_exit(), omitir la anulación de registro de ip_vs_ftp si se llama durante la limpieza de netns (cuando 'exiting_module' es falso) y aplazarla a __ip_vs_cleanup_batch(), que anula el registro de todas las aplicaciones después de que se vacían todas las conexiones. Si se llama durante la salida del módulo, anular el registro de ip_vs_ftp inmediatamente.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2025-40018 changed 2026-10-15 | CVE Terms of Use |
| NVD | CVE-2025-40018 changed 2026-10-19 | Public domain |