org.apache.oozie.service
Class ProxyUserService
java.lang.Object
org.apache.oozie.service.ProxyUserService
- All Implemented Interfaces:
- Service
public class ProxyUserService
- extends Object
- implements Service
The ProxyUserService checks if a user of a request has proxyuser privileges.
This check is based on the following criteria:
- The user of the request must be configured as proxy user in Oozie configuration.
- The user of the request must be making the request from a whitelisted host.
- The user of the request must be making the request on behalf of a user of a whitelisted group.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CONF_PREFIX
public static final String CONF_PREFIX
- See Also:
- Constant Field Values
GROUPS
public static final String GROUPS
- See Also:
- Constant Field Values
HOSTS
public static final String HOSTS
- See Also:
- Constant Field Values
ProxyUserService
public ProxyUserService()
getInterface
public Class<? extends Service> getInterface()
- Returns the service interface.
- Specified by:
getInterface
in interface Service
- Returns:
ProxyUserService
init
public void init(Services services)
throws ServiceException
- Initializes the service.
- Specified by:
init
in interface Service
- Parameters:
services
- services singleton initializing the service.
- Throws:
ServiceException
- thrown if the service could not be configured correctly.
validate
public void validate(String proxyUser,
String proxyHost,
String doAsUser)
throws IOException,
AccessControlException
- Verifies a proxyuser.
- Parameters:
proxyUser
- user name of the proxy user.proxyHost
- host the proxy user is making the request from.doAsUser
- user the proxy user is impersonating.
- Throws:
IOException
- thrown if an error during the validation has occurred.
AccessControlException
- thrown if the user is not allowed to perform the proxyuser request.
destroy
public void destroy()
- Destroys the service.
- Specified by:
destroy
in interface Service
Copyright © 2013 Apache Software Foundation. All Rights Reserved.