summaryrefslogtreecommitdiff
path: root/drivers/dkms/ipoe/src
diff options
context:
space:
mode:
authorDenys Fedoryshchenko <denys.f@collabora.com>2026-07-07 01:13:29 +0300
committerDenys Fedoryshchenko <denys.f@collabora.com>2026-07-07 01:15:06 +0300
commite12b38501be622c9c8e030de86a28721d797e542 (patch)
treefc8abfb28edc5672d6ef3c80ada558d6722a699a /drivers/dkms/ipoe/src
parent7a7ab323158a63f222698f85179090e3b6030b96 (diff)
downloadaccel-ppp-e12b38501be622c9c8e030de86a28721d797e542.tar.gz
accel-ppp-e12b38501be622c9c8e030de86a28721d797e542.zip
ipoe: fix username string leak on early session teardown
The ipoe-level ses->username always holds an allocated string (_strdup of ifname/calling-station-id, u_inet_ntoa buffer or lua result), but ipoe_session_free() never released it. Ownership is normally transferred in auth_result() via ap_session_set_username(), so the string was leaked whenever a session died before auth_result() ran: termination while starting, PWDB_WAIT never completing, or ipoe_create_interface() failure. The create-interface failure path also leaked the freshly allocated local copy outright, since it returned before the string was stored anywhere. Store the string in ses->username as soon as it is obtained and free it in ipoe_session_free(). auth_result() clears ses->username before handing ownership to ap_session_set_username(), so no double free is possible. Reported-by: Louis Scalbert (#101)
Diffstat (limited to 'drivers/dkms/ipoe/src')
0 files changed, 0 insertions, 0 deletions