mirror of
https://github.com/torvalds/linux.git
synced 2026-11-25 16:02:57 +00:00
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation version 2 of the license extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 315 file(s). Signed-off-by: Thomas Gleixner <[email protected]> Reviewed-by: Allison Randal <[email protected]> Reviewed-by: Armijn Hemel <[email protected]> Cc: [email protected] Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
24 lines
552 B
C
24 lines
552 B
C
// SPDX-License-Identifier: GPL-2.0-only
|
|
/*
|
|
* Copyright (C) 2011 IBM Corporation
|
|
*
|
|
* Author:
|
|
* Mimi Zohar <[email protected]>
|
|
*/
|
|
|
|
#include <linux/xattr.h>
|
|
#include <linux/evm.h>
|
|
|
|
int posix_xattr_acl(const char *xattr)
|
|
{
|
|
int xattr_len = strlen(xattr);
|
|
|
|
if ((strlen(XATTR_NAME_POSIX_ACL_ACCESS) == xattr_len)
|
|
&& (strncmp(XATTR_NAME_POSIX_ACL_ACCESS, xattr, xattr_len) == 0))
|
|
return 1;
|
|
if ((strlen(XATTR_NAME_POSIX_ACL_DEFAULT) == xattr_len)
|
|
&& (strncmp(XATTR_NAME_POSIX_ACL_DEFAULT, xattr, xattr_len) == 0))
|
|
return 1;
|
|
return 0;
|
|
}
|