CVE-2026-143143: ipvs: Defer application parent freeing until after RCU readers
In the Linux kernel, the following vulnerability has been resolved:
ipvs: Defer application parent freeing until after RCU readers
unregisteripvsapp() removes each incarnation from its protocol list and uses callrcu() to defer freeing it, but frees the parent application immediately. An RCU reader that already found an incarnation can still access the parent through inc->app in ipvsappincget().
During FTP helper module unload, the following interleaving is possible:
CPU 0 (RCU reader) CPU 1 (module unload) tcpappconnbind() find inc in protocol list unregisteripvsapp() ipvsappincrelease(inc) listdelrcu(&inc->plist) callrcu(&inc->rcuhead, ...) kfree(a) ipvsappincget(inc) trymoduleget(inc->app->module)
The helper module is already going away, so trymoduleget() would fail, but evaluating its argument first reads the freed parent. The subsequent rcubarrier() in pernet unregistration cannot protect this earlier free. KASAN reported:
BUG: KASAN: slab-use-after-free in ipvsappincget+0x7c/0x90 Call Trace: ipvsappincget+0x7c/0x90 tcpappconnbind+0x1bc/0x290 ipvsconnnew+0x1915/0x20d0 ipvsschedule+0x697/0xea0 tcpconnschedule+0x489/0x820 ipvsinhook+0x7bf/0x1f40 Allocated by task 88: kmemdupnoprof+0x20/0x50 registeripvsapp+0x12d/0x2c0 ipvsftpinit+0x56/0x160 [ipvsftp] Freed by task 104: kfree+0x131/0x3c0 unregisteripvsapp+0x2f4/0x5b0 unregisterpernetoperations+0x232/0x490 unregisterpernetsubsys+0x1c/0x30 dosysdeletemodule+0x346/0x510
Use kfreercu() with the existing rcuhead to keep the parent alive until these readers finish. Successful helper references already prevent normal module unload, and incarnation RCU callbacks do not access the parent.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
Use kfree_rcu() with the existing rcu_head to defer freeing the parent application until RCU readers finish.
Event History
Frequently Asked Questions
What conditions are required to trigger this issue?
The race requires an RCU reader to find an IPVS application incarnation while that application is being unregistered. The described trigger occurs during FTP helper module unload, when a concurrent connection path reaches tcp_app_conn_bind() and accesses inc->app after the parent application has been freed.
Who is most likely exposed?
Systems using Linux kernel IPVS application helpers are implicated, particularly where the FTP helper module can be unloaded while IPVS is concurrently processing TCP connections. The issue is a use-after-free in the IPVS application incarnation handling path.
How can administrators tell whether the issue has occurred?
The reported symptom is a KASAN slab-use-after-free warning in ip_vs_app_inc_get(). The provided call trace includes tcp_app_conn_bind(), ip_vs_conn_new(), ip_vs_schedule(), and tcp_conn_schedule().
Is a delayed RCU cleanup during network namespace unregistration sufficient protection?
No. The description states that the subsequent rcu_barrier() in per-network-namespace unregistration cannot protect the earlier freeing of the parent application.