Class AuthResult
java.lang.Object
org.apache.hadoop.hbase.security.access.AuthResult
Represents the result of an authorization check for logging and error reporting.
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionprivate final Permission.Action
private boolean
private final Map<byte[],
? extends Collection<?>> private final byte[]
private final String
private AuthResult.Params
private final byte[]
private String
private final String
private final TableName
private final User
-
Constructor Summary
ConstructorDescriptionAuthResult
(boolean allowed, String request, String reason, User user, Permission.Action action, String namespace) AuthResult
(boolean allowed, String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) AuthResult
(boolean allowed, String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) -
Method Summary
Modifier and TypeMethodDescriptionstatic AuthResult
static AuthResult
allow
(String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) static AuthResult
allow
(String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) static AuthResult
static AuthResult
deny
(String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) static AuthResult
deny
(String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) byte[]
byte[]
getUser()
boolean
void
setAllowed
(boolean allowed) void
private static String
toFamiliesString
(Map<byte[], ? extends Collection<?>> families, byte[] family, byte[] qual) toString()
-
Field Details
-
allowed
-
namespace
-
table
-
action
-
request
-
reason
-
user
-
params
-
family
-
qualifier
-
families
-
-
Constructor Details
-
AuthResult
public AuthResult(boolean allowed, String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) -
AuthResult
public AuthResult(boolean allowed, String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) -
AuthResult
public AuthResult(boolean allowed, String request, String reason, User user, Permission.Action action, String namespace)
-
-
Method Details
-
isAllowed
-
getUser
-
getReason
-
getTableName
-
getFamily
-
getQualifier
-
getAction
-
getRequest
-
getParams
-
setAllowed
-
setReason
-
toFamiliesString
private static String toFamiliesString(Map<byte[], ? extends Collection<?>> families, byte[] family, byte[] qual) -
toContextString
-
toString
-
allow
public static AuthResult allow(String request, String reason, User user, Permission.Action action, String namespace) -
allow
public static AuthResult allow(String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) -
allow
public static AuthResult allow(String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) -
deny
public static AuthResult deny(String request, String reason, User user, Permission.Action action, String namespace) -
deny
public static AuthResult deny(String request, String reason, User user, Permission.Action action, TableName table, byte[] family, byte[] qualifier) -
deny
public static AuthResult deny(String request, String reason, User user, Permission.Action action, TableName table, Map<byte[], ? extends Collection<?>> families) -
toFamilyString
-