本文整理汇总了C++中MAC_CHECK函数的典型用法代码示例。如果您正苦于以下问题:C++ MAC_CHECK函数的具体用法?C++ MAC_CHECK怎么用?C++ MAC_CHECK使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了MAC_CHECK函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: mac_exc_action_check_exception_send
int
mac_exc_action_check_exception_send(struct task *victim_task, struct exception_action *action)
{
int error = 0;
struct proc *p = get_bsdtask_info(victim_task);
struct label *bsd_label = NULL;
struct label *label = NULL;
if (p != NULL) {
// Create a label from the still existing bsd process...
label = bsd_label = mac_exc_action_label_alloc();
MAC_PERFORM(exc_action_label_update, p, bsd_label);
} else {
// ... otherwise use the crash label on the task.
label = get_task_crash_label(victim_task);
}
if (label == NULL) {
MAC_MACH_UNEXPECTED("mac_exc_action_check_exception_send: no exc_action label for proc %p", p);
return EPERM;
}
MAC_CHECK(exc_action_check_exception_send, label, action, action->label);
if (bsd_label != NULL) {
mac_exc_action_label_free(bsd_label);
}
return (error);
}
示例2: mac_file_check_change_offset
int
mac_file_check_change_offset(struct ucred *cred, struct fileglob *fg)
{
int error;
MAC_CHECK(file_check_change_offset, cred, fg, fg->fg_label);
return (error);
}
示例3: mac_kext_check_load
int
mac_kext_check_load(kauth_cred_t cred, const char *identifier) {
int error;
MAC_CHECK(kext_check_load, cred, identifier);
return (error);
}
示例4: mac_file_check_receive
int
mac_file_check_receive(struct ucred *cred, struct fileglob *fg)
{
int error;
MAC_CHECK(file_check_receive, cred, fg, fg->fg_label);
return (error);
}
示例5: mac_iokit_check_device
int
mac_iokit_check_device(char *devtype, struct mac_module_data *mdata)
{
int error;
MAC_CHECK(iokit_check_device, devtype, mdata);
return (error);
}
示例6: mac_file_check_ioctl
int
mac_file_check_ioctl(struct ucred *cred, struct fileglob *fg, u_int cmd)
{
int error;
MAC_CHECK(file_check_ioctl, cred, fg, fg->fg_label, cmd);
return (error);
}
示例7: mac_file_check_dup
int
mac_file_check_dup(struct ucred *cred, struct fileglob *fg, int newfd)
{
int error;
MAC_CHECK(file_check_dup, cred, fg, fg->fg_label, newfd);
return (error);
}
示例8: mac_file_check_create
int
mac_file_check_create(struct ucred *cred)
{
int error;
MAC_CHECK(file_check_create, cred);
return (error);
}
示例9: mac_file_check_lock
int
mac_file_check_lock(struct ucred *cred, struct fileglob *fg, int op,
struct flock *fl)
{
int error;
MAC_CHECK(file_check_lock, cred, fg, fg->fg_label, op, fl);
return (error);
}
示例10: mac_file_check_set
int
mac_file_check_set(struct ucred *cred, struct fileglob *fg, char *buf,
int buflen)
{
int error;
MAC_CHECK(file_check_set, cred, fg, buf, buflen);
return (error);
}
示例11: mac_check_port_hold_receive
int
mac_check_port_hold_receive(struct label *task, struct label *port)
{
int error;
MAC_CHECK(check_port_hold_receive, task, port);
return (error);
}
示例12: mac_check_port_receive
int
mac_check_port_receive(struct label *task, struct label *sender)
{
int error;
MAC_CHECK(check_port_receive, task, sender);
return (error);
}
示例13: mac_file_check_fcntl
int
mac_file_check_fcntl(struct ucred *cred, struct fileglob *fg, int cmd,
user_long_t arg)
{
int error;
MAC_CHECK(file_check_fcntl, cred, fg, fg->fg_label, cmd, arg);
return (error);
}
示例14: mac_check_port_copy_send
int
mac_check_port_copy_send(struct label *task, struct label *port)
{
int error;
MAC_CHECK(check_port_copy_send, task, port);
return (error);
}
示例15: mac_sysvsem_check_semget
int
mac_sysvsem_check_semget(struct ucred *cred, struct semid_kernel *semakptr)
{
int error;
MAC_CHECK(sysvsem_check_semget, cred, semakptr, semakptr->label);
return (error);
}