apparmorfs.c (a9bf8e9fd561ba9ff1f0f2a1d96e439fcedaaaa4) apparmorfs.c (d384b0a1a35f87f0ad70c29518f98f922b1c15cb)
1/*
2 * AppArmor security module
3 *
4 * This file contains AppArmor /sys/kernel/security/apparmor interface functions
5 *
6 * Copyright (C) 1998-2008 Novell/SUSE
7 * Copyright 2009-2010 Canonical Ltd.
8 *

--- 11 unchanged lines hidden (view full) ---

20#include <linux/namei.h>
21#include <linux/capability.h>
22
23#include "include/apparmor.h"
24#include "include/apparmorfs.h"
25#include "include/audit.h"
26#include "include/context.h"
27#include "include/policy.h"
1/*
2 * AppArmor security module
3 *
4 * This file contains AppArmor /sys/kernel/security/apparmor interface functions
5 *
6 * Copyright (C) 1998-2008 Novell/SUSE
7 * Copyright 2009-2010 Canonical Ltd.
8 *

--- 11 unchanged lines hidden (view full) ---

20#include <linux/namei.h>
21#include <linux/capability.h>
22
23#include "include/apparmor.h"
24#include "include/apparmorfs.h"
25#include "include/audit.h"
26#include "include/context.h"
27#include "include/policy.h"
28#include "include/resource.h"
28
29/**
30 * aa_simple_write_to_buffer - common routine for getting policy from user
31 * @op: operation doing the user buffer copy
32 * @userbuf: user buffer to copy data from (NOT NULL)
33 * @alloc_size: size of user buffer (REQUIRES: @alloc_size >= @copy_size)
34 * @copy_size: size of data to copy from user buffer
35 * @pos: position write is at in the file (NOT NULL)

--- 160 unchanged lines hidden (view full) ---

196 AA_FS_FILE_BOOLEAN("change_profile", 1),
197 { }
198};
199
200static struct aa_fs_entry aa_fs_entry_features[] = {
201 AA_FS_DIR("domain", aa_fs_entry_domain),
202 AA_FS_DIR("file", aa_fs_entry_file),
203 AA_FS_FILE_U64("capability", VFS_CAP_FLAGS_MASK),
29
30/**
31 * aa_simple_write_to_buffer - common routine for getting policy from user
32 * @op: operation doing the user buffer copy
33 * @userbuf: user buffer to copy data from (NOT NULL)
34 * @alloc_size: size of user buffer (REQUIRES: @alloc_size >= @copy_size)
35 * @copy_size: size of data to copy from user buffer
36 * @pos: position write is at in the file (NOT NULL)

--- 160 unchanged lines hidden (view full) ---

197 AA_FS_FILE_BOOLEAN("change_profile", 1),
198 { }
199};
200
201static struct aa_fs_entry aa_fs_entry_features[] = {
202 AA_FS_DIR("domain", aa_fs_entry_domain),
203 AA_FS_DIR("file", aa_fs_entry_file),
204 AA_FS_FILE_U64("capability", VFS_CAP_FLAGS_MASK),
205 AA_FS_DIR("rlimit", aa_fs_entry_rlimit),
204 { }
205};
206
207static struct aa_fs_entry aa_fs_entry_apparmor[] = {
208 AA_FS_FILE_FOPS(".load", 0640, &aa_fs_profile_load),
209 AA_FS_FILE_FOPS(".replace", 0640, &aa_fs_profile_replace),
210 AA_FS_FILE_FOPS(".remove", 0640, &aa_fs_profile_remove),
211 AA_FS_DIR("features", aa_fs_entry_features),

--- 142 unchanged lines hidden ---
206 { }
207};
208
209static struct aa_fs_entry aa_fs_entry_apparmor[] = {
210 AA_FS_FILE_FOPS(".load", 0640, &aa_fs_profile_load),
211 AA_FS_FILE_FOPS(".replace", 0640, &aa_fs_profile_replace),
212 AA_FS_FILE_FOPS(".remove", 0640, &aa_fs_profile_remove),
213 AA_FS_DIR("features", aa_fs_entry_features),

--- 142 unchanged lines hidden ---