2 .\" This file is part of libsmack
3 .\" Copyright (C) 2012 Intel Corporation
5 .\" This library is free software; you can redistribute it and/or
6 .\" modify it under the terms of the GNU Lesser General Public License
7 .\" version 2.1 as published by the Free Software Foundation.
9 .\" This library is distributed in the hope that it will be useful, but
10 .\" WITHOUT ANY WARRANTY; without even the implied warranty of
11 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 .\" Lesser General Public License for more details.
14 .\" You should have received a copy of the GNU Lesser General Public
15 .\" License along with this library; if not, write to the Free Software
16 .\" Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
20 .\" Brian McGillion <brian.mcgillion@intel.com>
22 .TH "SMACKACCESS" "1" "03/05/2012" "smack-utils 1\&.0"
24 smackaccess \- Determine if a rule is permitted by the current Smack policy
26 .B smackaccess <subject> <object> <access_type>
29 allows for the caller to test if a process has access to another object and the type of access that is granted.
32 The context of the process that will be doing the access request
34 The context of the filesystem object or process that is going to be accessed
36 The type of access that will be requested e.g. "rwaxt", which respectively refer to read, write, append, execute and transmute.
38 On success the result of the test will be printed, 1 indicates that the rule is permitted by the policy and 0 indicates that such an action would fail.
42 returns 0 and 1 on failure.