diff options
author | James Morris <jmorris@namei.org> | 2009-12-09 03:01:03 -0500 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2009-12-09 03:01:03 -0500 |
commit | 1ad1f10cd915744bbe52b19423653b38287d827d (patch) | |
tree | ae072aace36b45a55d80b8cbf1b6d92523a88ea0 /security/tomoyo/file.c | |
parent | 08e3daff217059c84c360cc71212686e0a7995af (diff) | |
parent | 2b876f95d03e226394b5d360c86127cbefaf614b (diff) |
Merge branch 'master' into next
Diffstat (limited to 'security/tomoyo/file.c')
-rw-r--r-- | security/tomoyo/file.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/security/tomoyo/file.c b/security/tomoyo/file.c index 2d10f98fc551..482f0e7ed997 100644 --- a/security/tomoyo/file.c +++ b/security/tomoyo/file.c | |||
@@ -1118,27 +1118,6 @@ static int tomoyo_check_single_path_permission2(struct tomoyo_domain_info * | |||
1118 | } | 1118 | } |
1119 | 1119 | ||
1120 | /** | 1120 | /** |
1121 | * tomoyo_check_file_perm - Check permission for sysctl()'s "read" and "write". | ||
1122 | * | ||
1123 | * @domain: Pointer to "struct tomoyo_domain_info". | ||
1124 | * @filename: Filename to check. | ||
1125 | * @perm: Mode ("read" or "write" or "read/write"). | ||
1126 | * Returns 0 on success, negative value otherwise. | ||
1127 | */ | ||
1128 | int tomoyo_check_file_perm(struct tomoyo_domain_info *domain, | ||
1129 | const char *filename, const u8 perm) | ||
1130 | { | ||
1131 | struct tomoyo_path_info name; | ||
1132 | const u8 mode = tomoyo_check_flags(domain, TOMOYO_MAC_FOR_FILE); | ||
1133 | |||
1134 | if (!mode) | ||
1135 | return 0; | ||
1136 | name.name = filename; | ||
1137 | tomoyo_fill_path_info(&name); | ||
1138 | return tomoyo_check_file_perm2(domain, &name, perm, "sysctl", mode); | ||
1139 | } | ||
1140 | |||
1141 | /** | ||
1142 | * tomoyo_check_exec_perm - Check permission for "execute". | 1121 | * tomoyo_check_exec_perm - Check permission for "execute". |
1143 | * | 1122 | * |
1144 | * @domain: Pointer to "struct tomoyo_domain_info". | 1123 | * @domain: Pointer to "struct tomoyo_domain_info". |