Class Pam4jUserAuthenticator
java.lang.Object
org.apache.drill.exec.rpc.user.security.Pam4jUserAuthenticator
- All Implemented Interfaces:
Closeable
,AutoCloseable
,UserAuthenticator
Implement
UserAuthenticator
based on Pluggable Authentication
Module (PAM) configuration. Configure the PAM profiles using "drill.exec.security.user.auth.pam_profiles" BOOT
option. Ex. value [ "login", "sudo" ] (value is an array of strings).-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
authenticate
(String user, String password) Authenticate the given user and password combination.void
close()
Close the authenticator.void
setup
(DrillConfig drillConfig) Setup for authenticating user credentials.
-
Constructor Details
-
Pam4jUserAuthenticator
public Pam4jUserAuthenticator()
-
-
Method Details
-
setup
Description copied from interface:UserAuthenticator
Setup for authenticating user credentials.- Specified by:
setup
in interfaceUserAuthenticator
- Throws:
DrillbitStartupException
-
authenticate
Description copied from interface:UserAuthenticator
Authenticate the given user and password combination.- Specified by:
authenticate
in interfaceUserAuthenticator
- Throws:
UserAuthenticationException
- if authentication fails for given user and password.
-
close
Description copied from interface:UserAuthenticator
Close the authenticator. Used to release resources. Ex. LDAP authenticator opens connections to LDAP server, such connections resources are released in a safe manner as part of close.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceUserAuthenticator
- Throws:
IOException
-