Commit f578c08ec959cb0cdadf02bdc9689a4df3e9b9d4

Authored by Mimi Zohar
1 parent 0e5a247cb3

ima: increase iint flag size

In preparation for hook specific appraise status results, increase
the iint flags size.

Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
Signed-off-by: Dmitry Kasatkin <dmitry.kasatkin@intel.com>

Showing 1 changed file with 12 additions and 12 deletions Side-by-side Diff

security/integrity/integrity.h
... ... @@ -16,19 +16,19 @@
16 16 #include <crypto/sha.h>
17 17  
18 18 /* iint action cache flags */
19   -#define IMA_MEASURE 0x0001
20   -#define IMA_MEASURED 0x0002
21   -#define IMA_APPRAISE 0x0004
22   -#define IMA_APPRAISED 0x0008
23   -/*#define IMA_COLLECT 0x0010 do not use this flag */
24   -#define IMA_COLLECTED 0x0020
25   -#define IMA_AUDIT 0x0040
26   -#define IMA_AUDITED 0x0080
  19 +#define IMA_MEASURE 0x00000001
  20 +#define IMA_MEASURED 0x00000002
  21 +#define IMA_APPRAISE 0x00000004
  22 +#define IMA_APPRAISED 0x00000008
  23 +/*#define IMA_COLLECT 0x00000010 do not use this flag */
  24 +#define IMA_COLLECTED 0x00000020
  25 +#define IMA_AUDIT 0x00000040
  26 +#define IMA_AUDITED 0x00000080
27 27  
28 28 /* iint cache flags */
29   -#define IMA_ACTION_FLAGS 0xff00
30   -#define IMA_DIGSIG 0x0100
31   -#define IMA_DIGSIG_REQUIRED 0x0200
  29 +#define IMA_ACTION_FLAGS 0xff000000
  30 +#define IMA_DIGSIG 0x01000000
  31 +#define IMA_DIGSIG_REQUIRED 0x02000000
32 32  
33 33 #define IMA_DO_MASK (IMA_MEASURE | IMA_APPRAISE | IMA_AUDIT)
34 34 #define IMA_DONE_MASK (IMA_MEASURED | IMA_APPRAISED | IMA_AUDITED \
... ... @@ -50,7 +50,7 @@
50 50 struct rb_node rb_node; /* rooted in integrity_iint_tree */
51 51 struct inode *inode; /* back pointer to inode in question */
52 52 u64 version; /* track inode changes */
53   - unsigned short flags;
  53 + unsigned long flags;
54 54 struct evm_ima_xattr_data ima_xattr;
55 55 enum integrity_status ima_status:4;
56 56 enum integrity_status evm_status:4;