Skip to content

Commit

Permalink
Merge tag 'audit-pr-20221107' of git://git.kernel.org/pub/scm/linux/k…
Browse files Browse the repository at this point in the history
…ernel/git/pcmoore/audit

Pull audit fix from Paul Moore:
 "A small audit patch to fix an instance of undefined behavior in a
  shift operator caused when shifting a signed value too far, the same
  case as the lsm patch merged previously.

  While the fix is trivial and I can't imagine it causing a problem in a
  backport, I'm not explicitly marking it for stable on the off chance
  that there is some system out there which is relying on some wonky
  unexpected behavior which this patch could break; *if* it does break,
  IMO it's better that to happen in a minor or -rcX release and not in a
  stable backport"

* tag 'audit-pr-20221107' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit:
  audit: fix undefined behavior in bit shift for AUDIT_BIT
  • Loading branch information
torvalds committed Nov 8, 2022
2 parents f49b2d8 + 986d93f commit f141df3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/uapi/linux/audit.h
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@
#define AUDIT_MAX_KEY_LEN 256
#define AUDIT_BITMASK_SIZE 64
#define AUDIT_WORD(nr) ((__u32)((nr)/32))
#define AUDIT_BIT(nr) (1 << ((nr) - AUDIT_WORD(nr)*32))
#define AUDIT_BIT(nr) (1U << ((nr) - AUDIT_WORD(nr)*32))

#define AUDIT_SYSCALL_CLASSES 16
#define AUDIT_CLASS_DIR_WRITE 0
Expand Down

0 comments on commit f141df3

Please sign in to comment.