Projectname large_stringclasses 15
values | Filepath large_stringlengths 4 106 ⌀ | Function large_stringlengths 11 3.45k | Label list |
|---|---|---|---|
Linux Kernel | security/landlock/ruleset.c | static struct landlock_ruleset *create_ruleset(const u32 num_layers) {
struct landlock_ruleset *new_ruleset;
new_ruleset = kzalloc(struct_size(new_ruleset, fs_access_masks, num_layers),
GFP_KERNEL_ACCOUNT);
if (!new_ruleset)
return ERR_PTR(-ENOMEM);
refcount_set(&new_ruleset->usage,... | [
0,
0
] |
Linux Kernel | security/landlock/ruleset.c |
static inline void get_hierarchy(struct landlock_hierarchy *const hierarchy) {
if (hierarchy)
refcount_inc(&hierarchy->usage);
} | [
0,
0
] |
Linux Kernel | security/landlock/ruleset.c | static int inherit_ruleset(struct landlock_ruleset *const parent,
struct landlock_ruleset *const child) {
struct landlock_rule *walker_rule, *next_rule;
int err = 0;
might_sleep();
if (!parent)
return 0;
mutex_lock(&child->lock);
mutex_lock_nested(&parent->lock, SINGLE_DEPTH... | [
1,
0
] |
Linux Kernel | security/landlock/ruleset.c |
static void free_ruleset_work(struct work_struct *const work) {
struct landlock_ruleset *ruleset;
ruleset = container_of(work, struct landlock_ruleset, work_free);
free_ruleset(ruleset);
} | [
0,
0
] |
Linux Kernel | security/landlock/ruleset.c |
void landlock_put_ruleset_deferred(struct landlock_ruleset *const ruleset) {
if (ruleset && refcount_dec_and_test(&ruleset->usage)) {
INIT_WORK(&ruleset->work_free, free_ruleset_work);
schedule_work(&ruleset->work_free);
}
} | [
0,
0
] |
Linux Kernel | security/landlock/ruleset.c | const struct landlock_rule *
landlock_find_rule(const struct landlock_ruleset *const ruleset,
const struct landlock_object *const object) {
const struct rb_node *node;
if (!object)
return NULL;
node = ruleset->root.rb_node;
while (node) {
struct landlock_rule *this = rb_entry(node, s... | [
0,
0
] |
Linux Kernel | security/landlock/syscalls.c | static void build_check_abi(void) {
struct landlock_ruleset_attr ruleset_attr;
struct landlock_path_beneath_attr path_beneath_attr;
size_t ruleset_size, path_beneath_size;
ruleset_size = sizeof(ruleset_attr.handled_access_fs);
BUILD_BUG_ON(sizeof(ruleset_attr) != ruleset_size);
BUILD_BUG_ON(sizeof(ruleset_... | [
1,
0
] |
Linux Kernel | security/landlock/syscalls.c | static ssize_t fop_dummy_write(struct file *const filp,
const char __user *const buf, const size_t size,
loff_t *const ppos) {
return -EINVAL;
} | [
0,
0
] |
Linux Kernel | security/loadpin/loadpin.c |
static void report_load(const char *origin, struct file *file,
char *operation) {
char *cmdline, *pathname;
pathname = kstrdup_quotable_file(file, GFP_KERNEL);
cmdline = kstrdup_quotable_cmdline(current, GFP_KERNEL);
pr_notice("%s %s obj=%s%s%s pid=%d cmdline=%s%s%s\n", origin, operat... | [
1,
0
] |
Linux Kernel | security/loadpin/loadpin.c | static void loadpin_sb_free_security(struct super_block *mnt_sb) {
if (!IS_ERR_OR_NULL(pinned_root) && mnt_sb == pinned_root) {
pinned_root = ERR_PTR(-EIO);
pr_info("umount pinned fs: refusing further loads\n");
}
} | [
0,
0
] |
Linux Kernel | security/loadpin/loadpin.c | static int loadpin_read_file(struct file *file, enum kernel_read_file_id id,
bool contents) {
struct super_block *load_root;
const char *origin = kernel_read_file_id_str(id);
if (!contents)
file = NULL;
/* If the file id is excluded, ignore the pinning. */
if ((unsigned int)... | [
0,
0
] |
Linux Kernel | security/loadpin/loadpin.c |
static int loadpin_load_data(enum kernel_load_data_id id, bool contents) {
return loadpin_read_file(NULL, (enum kernel_read_file_id)id, contents);
} | [
0,
0
] |
Linux Kernel | security/loadpin/loadpin.c | static void __init parse_exclude(void) {
int i, j;
char *cur;
BUILD_BUG_ON(ARRAY_SIZE(exclude_read_files) !=
ARRAY_SIZE(ignore_read_file_id));
BUILD_BUG_ON(ARRAY_SIZE(kernel_read_file_str) <
ARRAY_SIZE(ignore_read_file_id));
for (i = 0; i < ARRAY_SIZE(exclude_read_files); i++) ... | [
0,
0
] |
Linux Kernel | security/loadpin/loadpin.c | static long dm_verity_ioctl(struct file *filp, unsigned int cmd,
unsigned long arg) {
void __user *uarg = (void __user *)arg;
unsigned int fd;
switch (cmd) {
case LOADPIN_IOC_SET_TRUSTED_VERITY_DIGESTS:
if (copy_from_user(&fd, uarg, sizeof(fd)))
return -EFAULT;
return... | [
1,
0
] |
Linux Kernel | security/lockdown/lockdown.c |
static int __init lockdown_lsm_init(void) {
#if defined(CONFIG_LOCK_DOWN_KERNEL_FORCE_INTEGRITY)
lock_kernel_down("Kernel configuration", LOCKDOWN_INTEGRITY_MAX);
#elif defined(CONFIG_LOCK_DOWN_KERNEL_FORCE_CONFIDENTIALITY)
lock_kernel_down("Kernel configuration", LOCKDOWN_CONFIDENTIALITY_MAX);
#endif
security_a... | [
0,
0
] |
Linux Kernel | security/lockdown/lockdown.c |
static int __init lockdown_secfs_init(void) {
struct dentry *dentry;
dentry = securityfs_create_file("lockdown", 0644, NULL, NULL, &lockdown_ops);
return PTR_ERR_OR_ZERO(dentry);
} | [
0,
0
] |
Linux Kernel | security/lsm_audit.c | int ipv4_skb_to_auditdata(struct sk_buff *skb, struct common_audit_data *ad,
u8 *proto) {
int ret = 0;
struct iphdr *ih;
ih = ip_hdr(skb);
ad->u.net->v4info.saddr = ih->saddr;
ad->u.net->v4info.daddr = ih->daddr;
if (proto)
*proto = ih->protocol;
if (ntohs(ih->frag_off) & ... | [
0,
0
] |
Linux Kernel | security/lsm_audit.c |
static inline void print_ipv6_addr(struct audit_buffer *ab,
const struct in6_addr *addr, __be16 port,
char *name1, char *name2) {
if (!ipv6_addr_any(addr))
audit_log_format(ab, " %s=%pI6c", name1, addr);
if (port)
audit_log_format(ab, "... | [
0,
0
] |
Linux Kernel | security/min_addr.c | static void update_mmap_min_addr(void) {
#ifdef CONFIG_LSM_MMAP_MIN_ADDR
if (dac_mmap_min_addr > CONFIG_LSM_MMAP_MIN_ADDR)
mmap_min_addr = dac_mmap_min_addr;
else
mmap_min_addr = CONFIG_LSM_MMAP_MIN_ADDR;
#else
mmap_min_addr = dac_mmap_min_addr;
#endif
} | [
0,
0
] |
Linux Kernel | security/safesetid/lsm.c | static bool id_permitted_for_cred(const struct cred *old, kid_t new_id,
enum setid_type new_type) {
bool permitted;
if (new_type == UID) {
if (uid_eq(new_id.uid, old->uid) || uid_eq(new_id.uid, old->euid) ||
uid_eq(new_id.uid, old->suid))
return true;
} else if... | [
1,
0
] |
Linux Kernel | security/safesetid/securityfs.c |
static void release_ruleset(struct setid_ruleset *pol) {
call_rcu(&pol->rcu, __release_ruleset);
} | [
0,
0
] |
Linux Kernel | security/safesetid/securityfs.c | static int verify_ruleset(struct setid_ruleset *pol) {
int bucket;
struct setid_rule *rule, *nrule;
int res = 0;
hash_for_each(pol->rules, bucket, rule, next) {
if (_setid_policy_lookup(pol, rule->dst_id, INVALID_ID) == SIDPOL_DEFAULT) {
if (pol->type == UID) {
pr_warn("insecure policy detect... | [
0,
0
] |
Linux Kernel | security/safesetid/securityfs.c |
static int __init safesetid_init_securityfs(void) {
int ret;
struct dentry *policy_dir;
struct dentry *uid_policy_file;
struct dentry *gid_policy_file;
if (!safesetid_initialized)
return 0;
policy_dir = securityfs_create_dir("safesetid", NULL);
if (IS_ERR(policy_dir)) {
ret = PTR_ERR(policy_dir... | [
0,
0
] |
Linux Kernel | security/security.c | static void __init set_enabled(struct lsm_info *lsm, bool enabled) {
if (!lsm->enabled) {
if (enabled)
lsm->enabled = &lsm_enabled_true;
else
lsm->enabled = &lsm_enabled_false;
} else if (lsm->enabled == &lsm_enabled_true) {
if (!enabled)
lsm->enabled = &lsm_enabled_false;
} else if... | [
0,
0
] |
Linux Kernel | security/security.c | static bool __init exists_ordered_lsm(struct lsm_info *lsm) {
struct lsm_info **check;
for (check = ordered_lsms; *check; check++)
if (*check == lsm)
return true;
return false;
} | [
0,
0
] |
Linux Kernel | security/security.c |
static void __init lsm_set_blob_size(int *need, int *lbs) {
int offset;
if (*need <= 0)
return;
offset = ALIGN(*lbs, sizeof(void *));
*lbs = offset + *need;
*need = offset;
} | [
1,
0
] |
Linux Kernel | security/security.c | static void __init initialize_lsm(struct lsm_info *lsm) {
if (is_enabled(lsm)) {
int ret;
init_debug("initializing %s\n", lsm->name);
ret = lsm->init();
WARN(ret, "%s failed to initialize: %d\n", lsm->name, ret);
}
} | [
0,
0
] |
Linux Kernel | security/security.c | static void __init ordered_lsm_init(void) {
struct lsm_info **lsm;
ordered_lsms = kcalloc(LSM_COUNT + 1, sizeof(*ordered_lsms), GFP_KERNEL);
if (chosen_lsm_order) {
if (chosen_major_lsm) {
pr_warn("security=%s is ignored because it is superseded by lsm=%s\n",
chosen_major_lsm, chosen_lsm... | [
1,
0
] |
Linux Kernel | security/security.c | static int __init choose_lsm_order(char *str) {
chosen_lsm_order = str;
return 1;
} | [
0,
0
] |
Linux Kernel | security/security.c |
int unregister_blocking_lsm_notifier(struct notifier_block *nb) {
return blocking_notifier_chain_unregister(&blocking_lsm_notifier_chain, nb);
} | [
0,
0
] |
Linux Kernel | security/security.c | static int lsm_task_alloc(struct task_struct *task) {
if (blob_sizes.lbs_task == 0) {
task->security = NULL;
return 0;
}
task->security = kzalloc(blob_sizes.lbs_task, GFP_KERNEL);
if (task->security == NULL)
return -ENOMEM;
return 0;
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_ptrace_access_check(struct task_struct *child, unsigned int mode) {
return call_int_hook(ptrace_access_check, 0, child, mode);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_ptrace_traceme(struct task_struct *parent) {
return call_int_hook(ptrace_traceme, 0, parent);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_quota_on(struct dentry *dentry) {
return call_int_hook(quota_on, 0, dentry);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_bprm_creds_from_file(struct linux_binprm *bprm,
struct file *file) {
return call_int_hook(bprm_creds_from_file, 0, bprm, file);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_fs_context_parse_param(struct fs_context *fc,
struct fs_parameter *param) {
struct security_hook_list *hp;
int trc;
int rc = -ENOPARAM;
hlist_for_each_entry(hp, &security_hook_heads.fs_context_parse_param, list) {
trc = hp->hook.fs_context_parse_param(fc, p... | [
1,
0
] |
Linux Kernel | security/security.c |
int security_sb_eat_lsm_opts(char *options, void **mnt_opts) {
return call_int_hook(sb_eat_lsm_opts, 0, options, mnt_opts);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_sb_pivotroot(const struct path *old_path,
const struct path *new_path) {
return call_int_hook(sb_pivotroot, 0, old_path, new_path);
} | [
0,
0
] |
Linux Kernel | security/security.c | int security_dentry_init_security(struct dentry *dentry, int mode,
const struct qstr *name,
const char **xattr_name, void **ctx,
u32 *ctxlen) {
struct security_hook_list *hp;
int rc;
hlist_for_each_entry(hp, &se... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_old_inode_init_security(struct inode *inode, struct inode *dir,
const struct qstr *qstr, const char **name,
void **value, size_t *len) {
if (unlikely(IS_PRIVATE(inode)))
return -EOPNOTSUPP;
return call_int_hook(inode_init_se... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_path_rename(const struct path *old_dir, struct dentry *old_dentry,
const struct path *new_dir, struct dentry *new_dentry,
unsigned int flags) {
if (unlikely(IS_PRIVATE(d_backing_inode(old_dentry)) ||
(d_is_positive(new_dentry) &&
... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_path_truncate(const struct path *path) {
if (unlikely(IS_PRIVATE(d_backing_inode(path->dentry))))
return 0;
return call_int_hook(path_truncate, 0, path);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_path_chmod(const struct path *path, umode_t mode) {
if (unlikely(IS_PRIVATE(d_backing_inode(path->dentry))))
return 0;
return call_int_hook(path_chmod, 0, path, mode);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_rmdir(struct inode *dir, struct dentry *dentry) {
if (unlikely(IS_PRIVATE(d_backing_inode(dentry))))
return 0;
return call_int_hook(inode_rmdir, 0, dir, dentry);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_mknod(struct inode *dir, struct dentry *dentry, umode_t mode,
dev_t dev) {
if (unlikely(IS_PRIVATE(dir)))
return 0;
return call_int_hook(inode_mknod, 0, dir, dentry, mode, dev);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_rename(struct inode *old_dir, struct dentry *old_dentry,
struct inode *new_dir, struct dentry *new_dentry,
unsigned int flags) {
if (unlikely(IS_PRIVATE(d_backing_inode(old_dentry)) ||
(d_is_positive(new_dentry) &&
... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_readlink(struct dentry *dentry) {
if (unlikely(IS_PRIVATE(d_backing_inode(dentry))))
return 0;
return call_int_hook(inode_readlink, 0, dentry);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_permission(struct inode *inode, int mask) {
if (unlikely(IS_PRIVATE(inode)))
return 0;
return call_int_hook(inode_permission, 0, inode, mask);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_set_acl(struct user_namespace *mnt_userns,
struct dentry *dentry, const char *acl_name,
struct posix_acl *kacl) {
int ret;
if (unlikely(IS_PRIVATE(d_backing_inode(dentry))))
return 0;
ret = call_int_hook(inode_set_acl, 0, mnt_userns, d... | [
0,
0
] |
Linux Kernel | security/security.c |
void security_inode_post_setxattr(struct dentry *dentry, const char *name,
const void *value, size_t size, int flags) {
if (unlikely(IS_PRIVATE(d_backing_inode(dentry))))
return;
call_void_hook(inode_post_setxattr, dentry, name, value, size, flags);
evm_inode_post_setxattr(d... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_getxattr(struct dentry *dentry, const char *name) {
if (unlikely(IS_PRIVATE(d_backing_inode(dentry))))
return 0;
return call_int_hook(inode_getxattr, 0, dentry, name);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_need_killpriv(struct dentry *dentry) {
return call_int_hook(inode_need_killpriv, 0, dentry);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_killpriv(struct user_namespace *mnt_userns,
struct dentry *dentry) {
return call_int_hook(inode_killpriv, 0, mnt_userns, dentry);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_inode_getsecid(struct inode *inode, u32 *secid) {
call_void_hook(inode_getsecid, inode, secid);
} | [
0,
0
] |
Linux Kernel | security/security.c | int security_inode_copy_up_xattr(const char *name) {
struct security_hook_list *hp;
int rc;
hlist_for_each_entry(hp, &security_hook_heads.inode_copy_up_xattr, list) {
rc = hp->hook.inode_copy_up_xattr(name);
if (rc != LSM_RET_DEFAULT(inode_copy_up_xattr))
return rc;
}
return LSM_RET_DEFAULT(in... | [
0,
0
] |
Linux Kernel | security/security.c |
int security_file_lock(struct file *file, unsigned int cmd) {
return call_int_hook(file_lock, 0, file, cmd);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_task_free(struct task_struct *task) {
call_void_hook(task_free, task);
kfree(task->security);
task->security = NULL;
} | [
0,
0
] |
Linux Kernel | security/security.c | void security_cred_free(struct cred *cred) {
if (unlikely(cred->security == NULL))
return;
call_void_hook(cred_free, cred);
kfree(cred->security);
cred->security = NULL;
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_transfer_creds(struct cred *new, const struct cred *old) {
call_void_hook(cred_transfer, new, old);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_kernel_act_as(struct cred *new, u32 secid) {
return call_int_hook(kernel_act_as, 0, new, secid);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_kernel_read_file(struct file *file, enum kernel_read_file_id id,
bool contents) {
int ret;
ret = call_int_hook(kernel_read_file, 0, file, id, contents);
if (ret)
return ret;
return ima_read_file(file, id, contents);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_task_setioprio(struct task_struct *p, int ioprio) {
return call_int_hook(task_setioprio, 0, p, ioprio);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_task_getioprio(struct task_struct *p) {
return call_int_hook(task_getioprio, 0, p);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_task_getscheduler(struct task_struct *p) {
return call_int_hook(task_getscheduler, 0, p);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_msg_msg_free(struct msg_msg *msg) {
call_void_hook(msg_msg_free_security, msg);
kfree(msg->security);
msg->security = NULL;
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_msg_queue_free(struct kern_ipc_perm *msq) {
call_void_hook(msg_queue_free_security, msq);
kfree(msq->security);
msq->security = NULL;
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_msg_queue_msgctl(struct kern_ipc_perm *msq, int cmd) {
return call_int_hook(msg_queue_msgctl, 0, msq, cmd);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_msg_queue_msgsnd(struct kern_ipc_perm *msq, struct msg_msg *msg,
int msqflg) {
return call_int_hook(msg_queue_msgsnd, 0, msq, msg, msqflg);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_shm_free(struct kern_ipc_perm *shp) {
call_void_hook(shm_free_security, shp);
kfree(shp->security);
shp->security = NULL;
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_d_instantiate(struct dentry *dentry, struct inode *inode) {
if (unlikely(inode && IS_PRIVATE(inode)))
return;
call_void_hook(d_instantiate, dentry, inode);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_setprocattr(const char *lsm, const char *name, void *value,
size_t size) {
struct security_hook_list *hp;
hlist_for_each_entry(hp, &security_hook_heads.setprocattr, list) {
if (lsm != NULL && strcmp(lsm, hp->lsm))
continue;
return hp->hook.setprocattr(name, valu... | [
1,
0
] |
Linux Kernel | security/security.c |
int security_ismaclabel(const char *name) {
return call_int_hook(ismaclabel, 0, name);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_secctx_to_secid(const char *secdata, u32 seclen, u32 *secid) {
*secid = 0;
return call_int_hook(secctx_to_secid, 0, secdata, seclen, secid);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_notifysecctx(struct inode *inode, void *ctx, u32 ctxlen) {
return call_int_hook(inode_notifysecctx, 0, inode, ctx, ctxlen);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_inode_setsecctx(struct dentry *dentry, void *ctx, u32 ctxlen) {
return call_int_hook(inode_setsecctx, 0, dentry, ctx, ctxlen);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_socket_post_create(struct socket *sock, int family, int type,
int protocol, int kern) {
return call_int_hook(socket_post_create, 0, sock, family, type, protocol,
kern);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_socket_shutdown(struct socket *sock, int how) {
return call_int_hook(socket_shutdown, 0, sock, how);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_sock_rcv_skb(struct sock *sk, struct sk_buff *skb) {
return call_int_hook(socket_sock_rcv_skb, 0, sk, skb);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb,
u32 *secid) {
return call_int_hook(socket_getpeersec_dgram, -ENOPROTOOPT, sock, skb, secid);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_tun_dev_alloc_security(void **security) {
return call_int_hook(tun_dev_alloc_security, 0, security);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_tun_dev_free_security(void *security) {
call_void_hook(tun_dev_free_security, security);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_tun_dev_create(void) { return call_int_hook(tun_dev_create, 0); } | [
0,
0
] |
Linux Kernel | security/security.c |
int security_tun_dev_attach_queue(void *security) {
return call_int_hook(tun_dev_attach_queue, 0, security);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_xfrm_policy_alloc(struct xfrm_sec_ctx **ctxp,
struct xfrm_user_sec_ctx *sec_ctx, gfp_t gfp) {
return call_int_hook(xfrm_policy_alloc_security, 0, ctxp, sec_ctx, gfp);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_xfrm_policy_free(struct xfrm_sec_ctx *ctx) {
call_void_hook(xfrm_policy_free_security, ctx);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_xfrm_policy_delete(struct xfrm_sec_ctx *ctx) {
return call_int_hook(xfrm_policy_delete_security, 0, ctx);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_xfrm_policy_lookup(struct xfrm_sec_ctx *ctx, u32 fl_secid) {
return call_int_hook(xfrm_policy_lookup, 0, ctx, fl_secid);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_xfrm_decode_session(struct sk_buff *skb, u32 *secid) {
return call_int_hook(xfrm_decode_session, 0, skb, secid, 1);
} | [
0,
0
] |
Linux Kernel | security/security.c |
void security_key_free(struct key *key) { call_void_hook(key_free, key); } | [
0,
0
] |
Linux Kernel | security/security.c | int security_key_getsecurity(struct key *key, char **_buffer) {
*_buffer = NULL;
return call_int_hook(key_getsecurity, 0, key, _buffer);
}
#endif | [
0,
0
] |
Linux Kernel | security/security.c | int security_bpf_prog_alloc(struct bpf_prog_aux *aux) {
return call_int_hook(bpf_prog_alloc_security, 0, aux);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_perf_event_alloc(struct perf_event *event) {
return call_int_hook(perf_event_alloc, 0, event);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_perf_event_read(struct perf_event *event) {
return call_int_hook(perf_event_read, 0, event);
} | [
0,
0
] |
Linux Kernel | security/security.c |
int security_uring_sqpoll(void) { return call_int_hook(uring_sqpoll, 0); } | [
0,
0
] |
Linux Kernel | security/security.c | int security_uring_cmd(struct io_uring_cmd *ioucmd) {
return call_int_hook(uring_cmd, 0, ioucmd);
}
#endif | [
0,
0
] |
Linux Kernel | security/selinux/avc.c | static struct extended_perms_decision *
avc_xperms_decision_lookup(u8 driver, struct avc_xperms_node *xp_node) {
struct avc_xperms_decision_node *xpd_node;
list_for_each_entry(xpd_node, &xp_node->xpd_head, xpd_list) {
if (xpd_node->xpd.driver == driver)
return &xpd_node->xpd;
}
return NULL;
} | [
0,
0
] |
Linux Kernel | security/selinux/avc.c |
static void avc_xperms_free(struct avc_xperms_node *xp_node) {
struct avc_xperms_decision_node *xpd_node, *tmp;
if (!xp_node)
return;
list_for_each_entry_safe(xpd_node, tmp, &xp_node->xpd_head, xpd_list) {
list_del(&xpd_node->xpd_list);
avc_xperms_decision_free(xpd_node);
}
kmem_cache_free(avc_... | [
0,
0
] |
Linux Kernel | security/selinux/avc.c | static inline void
avc_quick_copy_xperms_decision(u8 perm, struct extended_perms_decision *dest,
struct extended_perms_decision *src) {
u8 i = perm >> 5;
dest->used = src->used;
if (dest->used & XPERMS_ALLOWED)
dest->allowed->p[i] = src->allowed->p[i];
if (dest->used & XPERM... | [
1,
0
] |
Linux Kernel | security/selinux/avc.c |
static void avc_node_free(struct rcu_head *rhead) {
struct avc_node *node = container_of(rhead, struct avc_node, rhead);
avc_xperms_free(node->ae.xp_node);
kmem_cache_free(avc_node_cachep, node);
avc_cache_stats_incr(frees);
} | [
0,
0
] |
Linux Kernel | security/selinux/avc.c |
static void avc_node_kill(struct selinux_avc *avc, struct avc_node *node) {
avc_xperms_free(node->ae.xp_node);
kmem_cache_free(avc_node_cachep, node);
avc_cache_stats_incr(frees);
atomic_dec(&avc->avc_cache.active_nodes);
} | [
0,
0
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.