aboutsummaryrefslogtreecommitdiffstats
path: root/security/integrity
diff options
context:
space:
mode:
authorJames Morris <jmorris@namei.org>2009-09-22 19:43:43 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-23 10:39:29 -0400
commit88e9d34c727883d7d6f02cf1475b3ec98b8480c7 (patch)
tree475f544536d52739e0929e7727cab5124e855a06 /security/integrity
parentb7ed698cc9d556306a4088c238e2ea9311ea2cb3 (diff)
seq_file: constify seq_operations
Make all seq_operations structs const, to help mitigate against revectoring user-triggerable function pointers. This is derived from the grsecurity patch, although generated from scratch because it's simpler than extracting the changes from there. Signed-off-by: James Morris <jmorris@namei.org> Acked-by: Serge Hallyn <serue@us.ibm.com> Acked-by: Casey Schaufler <casey@schaufler-ca.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'security/integrity')
-rw-r--r--security/integrity/ima/ima_fs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/security/integrity/ima/ima_fs.c b/security/integrity/ima/ima_fs.c
index 6bfc7eaebfda..8e9777b76405 100644
--- a/security/integrity/ima/ima_fs.c
+++ b/security/integrity/ima/ima_fs.c
@@ -146,7 +146,7 @@ static int ima_measurements_show(struct seq_file *m, void *v)
146 return 0; 146 return 0;
147} 147}
148 148
149static struct seq_operations ima_measurments_seqops = { 149static const struct seq_operations ima_measurments_seqops = {
150 .start = ima_measurements_start, 150 .start = ima_measurements_start,
151 .next = ima_measurements_next, 151 .next = ima_measurements_next,
152 .stop = ima_measurements_stop, 152 .stop = ima_measurements_stop,
@@ -221,7 +221,7 @@ static int ima_ascii_measurements_show(struct seq_file *m, void *v)
221 return 0; 221 return 0;
222} 222}
223 223
224static struct seq_operations ima_ascii_measurements_seqops = { 224static const struct seq_operations ima_ascii_measurements_seqops = {
225 .start = ima_measurements_start, 225 .start = ima_measurements_start,
226 .next = ima_measurements_next, 226 .next = ima_measurements_next,
227 .stop = ima_measurements_stop, 227 .stop = ima_measurements_stop,