ksmbd: Fix dangling pointer in krb_authenticate
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 0626e6641f6b467447c81dd7678a69c66f7746cf · < 1e440d5b25b7efccb3defe542a73c51005799a5f| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
ksmbd: Fix dangling pointer in krb_authenticate
krb_authenticate frees sess->user and does not set the pointer to NULL. It calls ksmbd_krb5_authenticate to reinitialise sess->user but that function may return without doing so. If that happens then smb2_sess_setup, which calls krb_authenticate, will be accessing free'd memory when it later uses sess->user.
From the CVE record · Linux
In the Linux kernel's ksmbd component, krb_authenticate frees a session user pointer without clearing it. If Kerberos authentication returns without reinitializing that pointer, a subsequent SMB session setup can access freed memory. This occurs during authentication; the input does not establish whether an attacker needs prior access or user interaction.
Engineers running the Linux kernel with ksmbd should check their versions; affected versions were not provided.