FreeBSD kernel kern code
|
#include <sys/cdefs.h>
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/sysproto.h>
#include <sys/capsicum.h>
#include <sys/fcntl.h>
#include <sys/kernel.h>
#include <sys/malloc.h>
#include <sys/mount.h>
#include <sys/vnode.h>
#include <sys/lock.h>
#include <sys/mutex.h>
#include <sys/namei.h>
#include <sys/file.h>
#include <sys/filedesc.h>
#include <sys/proc.h>
#include <sys/sysent.h>
#include <sys/acl.h>
#include <security/audit/audit.h>
#include <security/mac/mac_framework.h>
Go to the source code of this file.
Functions | |
__FBSDID ("$FreeBSD$") | |
CTASSERT (ACL_MAX_ENTRIES >=OLDACL_MAX_ENTRIES) | |
MALLOC_DEFINE (M_ACL, "acl", "Access Control Lists") | |
static int | kern___acl_aclcheck_path (struct thread *td, const char *path, acl_type_t type, struct acl *aclp, int follow) |
static int | kern___acl_delete_path (struct thread *td, const char *path, acl_type_t type, int follow) |
static int | kern___acl_get_path (struct thread *td, const char *path, acl_type_t type, struct acl *aclp, int follow) |
static int | kern___acl_set_path (struct thread *td, const char *path, acl_type_t type, const struct acl *aclp, int follow) |
static int | vacl_set_acl (struct thread *td, struct vnode *vp, acl_type_t type, const struct acl *aclp) |
static int | vacl_get_acl (struct thread *td, struct vnode *vp, acl_type_t type, struct acl *aclp) |
static int | vacl_aclcheck (struct thread *td, struct vnode *vp, acl_type_t type, const struct acl *aclp) |
int | acl_copy_oldacl_into_acl (const struct oldacl *source, struct acl *dest) |
int | acl_copy_acl_into_oldacl (const struct acl *source, struct oldacl *dest) |
static int | acl_copyin (const void *user_acl, struct acl *kernel_acl, acl_type_t type) |
static int | acl_copyout (const struct acl *kernel_acl, void *user_acl, acl_type_t type) |
static int | acl_type_unold (int type) |
static int | vacl_delete (struct thread *td, struct vnode *vp, acl_type_t type) |
int | sys___acl_get_file (struct thread *td, struct __acl_get_file_args *uap) |
int | sys___acl_get_link (struct thread *td, struct __acl_get_link_args *uap) |
int | sys___acl_set_file (struct thread *td, struct __acl_set_file_args *uap) |
int | sys___acl_set_link (struct thread *td, struct __acl_set_link_args *uap) |
int | sys___acl_get_fd (struct thread *td, struct __acl_get_fd_args *uap) |
int | sys___acl_set_fd (struct thread *td, struct __acl_set_fd_args *uap) |
int | sys___acl_delete_file (struct thread *td, struct __acl_delete_file_args *uap) |
int | sys___acl_delete_link (struct thread *td, struct __acl_delete_link_args *uap) |
int | sys___acl_delete_fd (struct thread *td, struct __acl_delete_fd_args *uap) |
int | sys___acl_aclcheck_file (struct thread *td, struct __acl_aclcheck_file_args *uap) |
int | sys___acl_aclcheck_link (struct thread *td, struct __acl_aclcheck_link_args *uap) |
int | sys___acl_aclcheck_fd (struct thread *td, struct __acl_aclcheck_fd_args *uap) |
struct acl * | acl_alloc (int flags) |
void | acl_free (struct acl *aclp) |
__FBSDID | ( | "$FreeBSD$" | ) |
struct acl * acl_alloc | ( | int | flags | ) |
Definition at line 581 of file vfs_acl.c.
References flags, and malloc().
Referenced by acl_nfs4_is_trivial(), vacl_aclcheck(), vacl_get_acl(), and vacl_set_acl().
int acl_copy_acl_into_oldacl | ( | const struct acl * | source, |
struct oldacl * | dest | ||
) |
Definition at line 108 of file vfs_acl.c.
Referenced by acl_copyout().
int acl_copy_oldacl_into_acl | ( | const struct oldacl * | source, |
struct acl * | dest | ||
) |
Definition at line 86 of file vfs_acl.c.
Referenced by acl_copyin().
|
static |
Definition at line 141 of file vfs_acl.c.
References acl_copy_oldacl_into_acl(), and type.
Referenced by vacl_aclcheck(), and vacl_set_acl().
|
static |
Definition at line 165 of file vfs_acl.c.
References acl_copy_acl_into_oldacl(), and type.
Referenced by vacl_get_acl().
void acl_free | ( | struct acl * | aclp | ) |
Definition at line 595 of file vfs_acl.c.
References free().
Referenced by acl_nfs4_is_trivial(), vacl_aclcheck(), vacl_get_acl(), and vacl_set_acl().
|
static |
Definition at line 202 of file vfs_acl.c.
References type.
Referenced by vacl_aclcheck(), vacl_delete(), vacl_get_acl(), and vacl_set_acl().
CTASSERT | ( | ACL_MAX_ENTRIES >= | OLDACL_MAX_ENTRIES | ) |
|
static |
Definition at line 545 of file vfs_acl.c.
References namei(), NDFREE(), path, type, and vacl_aclcheck().
Referenced by sys___acl_aclcheck_file(), and sys___acl_aclcheck_link().
|
static |
Definition at line 488 of file vfs_acl.c.
References namei(), NDFREE(), path, type, and vacl_delete().
Referenced by sys___acl_delete_file(), and sys___acl_delete_link().
|
static |
Definition at line 374 of file vfs_acl.c.
References namei(), NDFREE(), path, type, and vacl_get_acl().
Referenced by sys___acl_get_file(), and sys___acl_get_link().
|
static |
Definition at line 412 of file vfs_acl.c.
References namei(), NDFREE(), path, type, and vacl_set_acl().
Referenced by sys___acl_set_file(), and sys___acl_set_link().
MALLOC_DEFINE | ( | M_ACL | , |
"acl" | , | ||
"Access Control Lists" | |||
) |
int sys___acl_aclcheck_fd | ( | struct thread * | td, |
struct __acl_aclcheck_fd_args * | uap | ||
) |
Definition at line 564 of file vfs_acl.c.
References getvnode(), and vacl_aclcheck().
int sys___acl_aclcheck_file | ( | struct thread * | td, |
struct __acl_aclcheck_file_args * | uap | ||
) |
Definition at line 527 of file vfs_acl.c.
References kern___acl_aclcheck_path().
int sys___acl_aclcheck_link | ( | struct thread * | td, |
struct __acl_aclcheck_link_args * | uap | ||
) |
Definition at line 538 of file vfs_acl.c.
References kern___acl_aclcheck_path().
int sys___acl_delete_fd | ( | struct thread * | td, |
struct __acl_delete_fd_args * | uap | ||
) |
Definition at line 507 of file vfs_acl.c.
References getvnode(), and vacl_delete().
int sys___acl_delete_file | ( | struct thread * | td, |
struct __acl_delete_file_args * | uap | ||
) |
Definition at line 471 of file vfs_acl.c.
References kern___acl_delete_path().
int sys___acl_delete_link | ( | struct thread * | td, |
struct __acl_delete_link_args * | uap | ||
) |
Definition at line 481 of file vfs_acl.c.
References kern___acl_delete_path().
int sys___acl_get_fd | ( | struct thread * | td, |
struct __acl_get_fd_args * | uap | ||
) |
Definition at line 431 of file vfs_acl.c.
References getvnode(), and vacl_get_acl().
int sys___acl_get_file | ( | struct thread * | td, |
struct __acl_get_file_args * | uap | ||
) |
Definition at line 355 of file vfs_acl.c.
References kern___acl_get_path().
int sys___acl_get_link | ( | struct thread * | td, |
struct __acl_get_link_args * | uap | ||
) |
Definition at line 366 of file vfs_acl.c.
References kern___acl_get_path().
int sys___acl_set_fd | ( | struct thread * | td, |
struct __acl_set_fd_args * | uap | ||
) |
Definition at line 451 of file vfs_acl.c.
References getvnode(), and vacl_set_acl().
int sys___acl_set_file | ( | struct thread * | td, |
struct __acl_set_file_args * | uap | ||
) |
Definition at line 393 of file vfs_acl.c.
References kern___acl_set_path().
int sys___acl_set_link | ( | struct thread * | td, |
struct __acl_set_link_args * | uap | ||
) |
Definition at line 404 of file vfs_acl.c.
References kern___acl_set_path().
|
static |
Definition at line 329 of file vfs_acl.c.
References acl_alloc(), acl_copyin(), acl_free(), acl_type_unold(), and type.
Referenced by kern___acl_aclcheck_path(), and sys___acl_aclcheck_fd().
|
static |
Definition at line 298 of file vfs_acl.c.
References acl_type_unold(), type, vn_finished_write(), and vn_start_write().
Referenced by kern___acl_delete_path(), and sys___acl_delete_fd().
|
static |
Definition at line 266 of file vfs_acl.c.
References acl_alloc(), acl_copyout(), acl_free(), acl_type_unold(), and type.
Referenced by kern___acl_get_path(), and sys___acl_get_fd().
|
static |
Definition at line 228 of file vfs_acl.c.
References acl_alloc(), acl_copyin(), acl_free(), acl_type_unold(), type, vn_finished_write(), and vn_start_write().
Referenced by kern___acl_set_path(), and sys___acl_set_fd().