Hi Marshall Shao, thanks for reporting this bug and its fix. I was able to look into this myself as well. Issue exists in both jammy and noble kernels and introduced with the following commit (basically audit_log_object_context never works for the happy path because of this).
c45f92d3c95e9a242c0b22e2f7f24e4f319391dd (noble) UBUNTU: SAUCE: apparmor4.0.0 [17/90]: LSM stacking v39: LSM: Use lsmcontext in security_secid_to_secctx BugLink: http://bugs.launchpad.net/bugs/2028253 Replace the (secctx,seclen) pointer pair with a single lsmcontext pointer to allow return of the LSM identifier along with the context and context length. This allows security_release_secctx() to know how to release the context. Callers have been modified to use or save the returned data from the new structure. security_secid_to_secctx() will now return the length value on success instead of 0. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2123815 Title: Ubuntu 24.04.2: error in audit_log_object_context keep printing in the kernel and console To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2123815/+subscriptions -- ubuntu-bugs mailing list [email protected] https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
