aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/audit.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/audit.h')
-rw-r--r--kernel/audit.h31
1 files changed, 17 insertions, 14 deletions
diff --git a/kernel/audit.h b/kernel/audit.h
index 208687be4f30..91e7071c4d2c 100644
--- a/kernel/audit.h
+++ b/kernel/audit.h
@@ -84,10 +84,7 @@ extern int audit_compare_dname_path(const char *dname, const char *path,
84 int *dirlen); 84 int *dirlen);
85extern struct sk_buff * audit_make_reply(int pid, int seq, int type, 85extern struct sk_buff * audit_make_reply(int pid, int seq, int type,
86 int done, int multi, 86 int done, int multi,
87 void *payload, int size); 87 const void *payload, int size);
88extern void audit_send_reply(int pid, int seq, int type,
89 int done, int multi,
90 void *payload, int size);
91extern void audit_panic(const char *message); 88extern void audit_panic(const char *message);
92 89
93struct audit_netlink_list { 90struct audit_netlink_list {
@@ -103,21 +100,27 @@ extern struct mutex audit_filter_mutex;
103extern void audit_free_rule_rcu(struct rcu_head *); 100extern void audit_free_rule_rcu(struct rcu_head *);
104extern struct list_head audit_filter_list[]; 101extern struct list_head audit_filter_list[];
105 102
103extern struct audit_entry *audit_dupe_rule(struct audit_krule *old);
104
106/* audit watch functions */ 105/* audit watch functions */
107extern unsigned long audit_watch_inode(struct audit_watch *watch); 106#ifdef CONFIG_AUDIT_WATCH
108extern dev_t audit_watch_dev(struct audit_watch *watch);
109extern void audit_put_watch(struct audit_watch *watch); 107extern void audit_put_watch(struct audit_watch *watch);
110extern void audit_get_watch(struct audit_watch *watch); 108extern void audit_get_watch(struct audit_watch *watch);
111extern int audit_to_watch(struct audit_krule *krule, char *path, int len, u32 op); 109extern int audit_to_watch(struct audit_krule *krule, char *path, int len, u32 op);
112extern int audit_add_watch(struct audit_krule *krule); 110extern int audit_add_watch(struct audit_krule *krule, struct list_head **list);
113extern void audit_remove_watch(struct audit_watch *watch); 111extern void audit_remove_watch_rule(struct audit_krule *krule);
114extern void audit_remove_watch_rule(struct audit_krule *krule, struct list_head *list);
115extern void audit_inotify_unregister(struct list_head *in_list);
116extern char *audit_watch_path(struct audit_watch *watch); 112extern char *audit_watch_path(struct audit_watch *watch);
117extern struct list_head *audit_watch_rules(struct audit_watch *watch); 113extern int audit_watch_compare(struct audit_watch *watch, unsigned long ino, dev_t dev);
118 114#else
119extern struct audit_entry *audit_dupe_rule(struct audit_krule *old, 115#define audit_put_watch(w) {}
120 struct audit_watch *watch); 116#define audit_get_watch(w) {}
117#define audit_to_watch(k, p, l, o) (-EINVAL)
118#define audit_add_watch(k, l) (-EINVAL)
119#define audit_remove_watch_rule(k) BUG()
120#define audit_watch_path(w) ""
121#define audit_watch_compare(w, i, d) 0
122
123#endif /* CONFIG_AUDIT_WATCH */
121 124
122#ifdef CONFIG_AUDIT_TREE 125#ifdef CONFIG_AUDIT_TREE
123extern struct audit_chunk *audit_tree_lookup(const struct inode *); 126extern struct audit_chunk *audit_tree_lookup(const struct inode *);