Re: [PATCH v2] ksmbd: fail SET_INFO when the security descriptor cannot be stored

From: Namjae Jeon

Date: Thu Nov 19 2026 - 06:27:37 EST


On Thu, Nov 19, 2026 at 3:51 PM Ian Bridges <icb@xxxxxxxxxxxx> wrote:
>
> SET_INFO reports success even when ksmbd cannot store the new security
> descriptor. The old descriptor has already been removed, so the file
> falls back to POSIX permissions. Deny ACEs in the new descriptor are
> lost. This can happen when the descriptor exceeds the filesystem's
> xattr capacity.
>
> Return the storage error to the client. Report -E2BIG as
> STATUS_DISK_FULL, like -ENOSPC and -EFBIG, and report -ENOMEM as
> STATUS_INSUFFICIENT_RESOURCES. Both errors previously fell through to
> STATUS_INVALID_INFO_CLASS. These mappings apply to all SET_INFO
> classes.
>
> Preserve success for filesystems that do not support the xattr. Also
> preserve the best-effort store for CREATE, where the file has already
> been created.
>
> Fixes: e2f34481b24d ("cifsd: add server-side procedures for SMB3")
> Cc: stable@xxxxxxxxxxxxxxx
> Signed-off-by: Ian Bridges <icb@xxxxxxxxxxxx>
Applied it to #ksmbd-for-next.
Thanks!