org.apache.cassandra.auth
Interface IAuthority2

All Superinterfaces:
IAuthority

public interface IAuthority2
extends IAuthority


Method Summary
 void grant(AuthenticatedUser granter, Permission permission, java.lang.String to, CFName resource, boolean grantOption)
          GRANT ON TO [WITH GRANT OPTION];
 org.apache.cassandra.thrift.CqlResult listPermissions(java.lang.String username)
          LIST GRANTS FOR ; Not 'SHOW' because it's reserved for CQLsh for commands like 'show cluster'
 void revoke(AuthenticatedUser revoker, Permission permission, java.lang.String from, CFName resource)
          REVOKE ON FROM ;
 void setup()
          Setup is called each time upon system startup
 
Methods inherited from interface org.apache.cassandra.auth.IAuthority
authorize, validateConfiguration
 

Method Detail

setup

void setup()
Setup is called each time upon system startup


grant

void grant(AuthenticatedUser granter,
           Permission permission,
           java.lang.String to,
           CFName resource,
           boolean grantOption)
           throws org.apache.cassandra.thrift.InvalidRequestException
GRANT ON TO [WITH GRANT OPTION];

Parameters:
granter - The user who grants the permission
permission - The specific permission
to - Grantee of the permission
resource - The resource which is affect by permission change
grantOption - Does grantee has a permission to grant the same kind of permission on this particular resource?
Throws:
org.apache.cassandra.thrift.InvalidRequestException - upon parameter misconfiguration or internal error.

revoke

void revoke(AuthenticatedUser revoker,
            Permission permission,
            java.lang.String from,
            CFName resource)
            throws org.apache.cassandra.thrift.InvalidRequestException
REVOKE ON FROM ;

Parameters:
revoker - The user know requests permission revoke
permission - The permission to revoke
from - The user to revoke permission from.
resource - The resource affected by permission change.
Throws:
org.apache.cassandra.thrift.InvalidRequestException - upon parameter misconfiguration or internal error.

listPermissions

org.apache.cassandra.thrift.CqlResult listPermissions(java.lang.String username)
                                                      throws org.apache.cassandra.thrift.InvalidRequestException
LIST GRANTS FOR ; Not 'SHOW' because it's reserved for CQLsh for commands like 'show cluster'

Parameters:
username - The username to look for permissions.
Returns:
All of the permission of this particular user.
Throws:
org.apache.cassandra.thrift.InvalidRequestException - upon parameter misconfiguration or internal error.


Copyright © 2012 The Apache Software Foundation