aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/audit.h5
-rw-r--r--include/linux/ima.h60
-rw-r--r--include/linux/tpm.h35
3 files changed, 100 insertions, 0 deletions
diff --git a/include/linux/audit.h b/include/linux/audit.h
index 67e5dbfc296..930939abfbc 100644
--- a/include/linux/audit.h
+++ b/include/linux/audit.h
@@ -125,6 +125,11 @@
125#define AUDIT_LAST_KERN_ANOM_MSG 1799 125#define AUDIT_LAST_KERN_ANOM_MSG 1799
126#define AUDIT_ANOM_PROMISCUOUS 1700 /* Device changed promiscuous mode */ 126#define AUDIT_ANOM_PROMISCUOUS 1700 /* Device changed promiscuous mode */
127#define AUDIT_ANOM_ABEND 1701 /* Process ended abnormally */ 127#define AUDIT_ANOM_ABEND 1701 /* Process ended abnormally */
128#define AUDIT_INTEGRITY_DATA 1800 /* Data integrity verification */
129#define AUDIT_INTEGRITY_METADATA 1801 /* Metadata integrity verification */
130#define AUDIT_INTEGRITY_STATUS 1802 /* Integrity enable status */
131#define AUDIT_INTEGRITY_HASH 1803 /* Integrity HASH type */
132#define AUDIT_INTEGRITY_PCR 1804 /* PCR invalidation msgs */
128 133
129#define AUDIT_KERNEL 2000 /* Asynchronous audit record. NOT A REQUEST. */ 134#define AUDIT_KERNEL 2000 /* Asynchronous audit record. NOT A REQUEST. */
130 135
diff --git a/include/linux/ima.h b/include/linux/ima.h
new file mode 100644
index 00000000000..6db30a328d9
--- /dev/null
+++ b/include/linux/ima.h
@@ -0,0 +1,60 @@
1/*
2 * Copyright (C) 2008 IBM Corporation
3 * Author: Mimi Zohar <zohar@us.ibm.com>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, version 2 of the License.
8 */
9
10#include <linux/fs.h>
11
12#ifndef _LINUX_IMA_H
13#define _LINUX_IMA_H
14
15#ifdef CONFIG_IMA
16extern int ima_bprm_check(struct linux_binprm *bprm);
17extern int ima_inode_alloc(struct inode *inode);
18extern void ima_inode_free(struct inode *inode);
19extern int ima_path_check(struct path *path, int mask);
20extern void ima_file_free(struct file *file);
21extern int ima_file_mmap(struct file *file, unsigned long prot);
22extern void ima_shm_check(struct file *file);
23
24#else
25static inline int ima_bprm_check(struct linux_binprm *bprm)
26{
27 return 0;
28}
29
30static inline int ima_inode_alloc(struct inode *inode)
31{
32 return 0;
33}
34
35static inline void ima_inode_free(struct inode *inode)
36{
37 return;
38}
39
40static inline int ima_path_check(struct path *path, int mask)
41{
42 return 0;
43}
44
45static inline void ima_file_free(struct file *file)
46{
47 return;
48}
49
50static inline int ima_file_mmap(struct file *file, unsigned long prot)
51{
52 return 0;
53}
54
55static inline void ima_shm_check(struct file *file)
56{
57 return;
58}
59#endif /* CONFIG_IMA_H */
60#endif /* _LINUX_IMA_H */
diff --git a/include/linux/tpm.h b/include/linux/tpm.h
new file mode 100644
index 00000000000..3338b3f5c21
--- /dev/null
+++ b/include/linux/tpm.h
@@ -0,0 +1,35 @@
1/*
2 * Copyright (C) 2004,2007,2008 IBM Corporation
3 *
4 * Authors:
5 * Leendert van Doorn <leendert@watson.ibm.com>
6 * Dave Safford <safford@watson.ibm.com>
7 * Reiner Sailer <sailer@watson.ibm.com>
8 * Kylene Hall <kjhall@us.ibm.com>
9 * Debora Velarde <dvelarde@us.ibm.com>
10 *
11 * Maintained by: <tpmdd_devel@lists.sourceforge.net>
12 *
13 * Device driver for TCG/TCPA TPM (trusted platform module).
14 * Specifications at www.trustedcomputinggroup.org
15 *
16 * This program is free software; you can redistribute it and/or
17 * modify it under the terms of the GNU General Public License as
18 * published by the Free Software Foundation, version 2 of the
19 * License.
20 *
21 */
22#ifndef __LINUX_TPM_H__
23#define __LINUX_TPM_H__
24
25/*
26 * Chip num is this value or a valid tpm idx
27 */
28#define TPM_ANY_NUM 0xFFFF
29
30#if defined(CONFIG_TCG_TPM)
31
32extern int tpm_pcr_read(u32 chip_num, int pcr_idx, u8 *res_buf);
33extern int tpm_pcr_extend(u32 chip_num, int pcr_idx, const u8 *hash);
34#endif
35#endif