object LdapUtils extends Logging
Static utility methods related to LDAP authentication module.
- Alphabetic
- By Inheritance
- LdapUtils
- Logging
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
createCandidatePrincipals(conf: KyuubiConf, user: String): Array[String]
Creates a list of principals to be used for user authentication.
Creates a list of principals to be used for user authentication.
- conf
Kyuubi configuration
- user
username
- returns
a list of user's principals
-
def
debug(message: ⇒ Any, t: Throwable): Unit
- Definition Classes
- Logging
-
def
debug(message: ⇒ Any): Unit
- Definition Classes
- Logging
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
error(message: ⇒ Any): Unit
- Definition Classes
- Logging
-
def
error(message: ⇒ Any, t: Throwable): Unit
- Definition Classes
- Logging
-
def
extractBaseDn(dn: String): String
Extracts a base DN from the provided distinguished name.
Extracts a base DN from the provided distinguished name.
Example:
"ou=CORP,dc=mycompany,dc=com" is the base DN for "cn=user1,ou=CORP,dc=mycompany,dc=com"- dn
distinguished name
- returns
base DN
-
def
extractFirstRdn(dn: String): String
Extracts the first Relative Distinguished Name (RDN).
Extracts the first Relative Distinguished Name (RDN).
Example:
For DN "cn=user1,ou=CORP,dc=mycompany,dc=com" this method will return "cn=user1"- dn
distinguished name
- returns
first RDN
-
def
extractUserName(userDn: String): String
Extracts username from user DN.
Extracts username from user DN.
Examples:LdapUtils.extractUserName("UserName") = "UserName" LdapUtils.extractUserName("UserName@mycorp.com") = "UserName" LdapUtils.extractUserName("cn=UserName,dc=mycompany,dc=com") = "UserName" -
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getShortName(rdn: String): String
Gets value part of the first attribute in the provided RDN.
Gets value part of the first attribute in the provided RDN.
Example:
For RDN "cn=user1,ou=CORP" this method will return "user1"- rdn
Relative Distinguished Name
- returns
value part of the first attribute
-
def
getUserName(user: String): String
Get the username part in the provided user.
Get the username part in the provided user.
Example:
For user "user1@mycorp.com" this method will return "user1"- user
user
- returns
the username part in the provided user
-
def
hasDomain(userName: String): Boolean
Check for a domain part in the provided username.
Check for a domain part in the provided username.
Example:
LdapUtils.hasDomain("user1@mycorp.com") = true LdapUtils.hasDomain("user1") = false- userName
username
- returns
true if
userNamecontains@<domain>part
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
info(message: ⇒ Any, t: Throwable): Unit
- Definition Classes
- Logging
-
def
info(message: ⇒ Any): Unit
- Definition Classes
- Logging
-
def
initializeLoggerIfNecessary(isInterpreter: Boolean): Unit
- Attributes
- protected
- Definition Classes
- Logging
-
def
isDn(name: String): Boolean
Detects DN names.
Detects DN names.
Example:
LdapUtils.isDn("cn=UserName,dc=mycompany,dc=com") = true LdapUtils.isDn("user1") = false- name
name to be checked
- returns
true if the provided name is a distinguished name
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
logger: Logger
- Attributes
- protected
- Definition Classes
- Logging
-
def
loggerName: String
- Attributes
- protected
- Definition Classes
- Logging
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
parseDnPatterns(conf: KyuubiConf, confKey: OptionalConfigEntry[String]): Array[String]
Reads and parses DN patterns from Kyuubi configuration.
Reads and parses DN patterns from Kyuubi configuration.
If no patterns are provided in the configuration, then the base DN will be used.- conf
Kyuubi configuration
- confKey
configuration key to be read
- returns
a list of DN patterns
- See also
KyuubiConf.AUTHENTICATION_LDAP_BASE_DN
KyuubiConf.AUTHENTICATION_LDAP_GUID_KEY
KyuubiConf.AUTHENTICATION_LDAP_GROUP_DN_PATTERN
KyuubiConf.AUTHENTICATION_LDAP_USER_DN_PATTERN
-
def
patternsToBaseDns(patterns: Array[String]): Array[String]
Converts a collection of Distinguished Name patterns to a collection of base DNs.
Converts a collection of Distinguished Name patterns to a collection of base DNs.
- patterns
Distinguished Name patterns
- returns
a list of base DNs
- See also
KyuubiConf.AUTHENTICATION_LDAP_GROUP_DN_PATTERN
KyuubiConf.AUTHENTICATION_LDAP_USER_DN_PATTERN
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
warn(message: ⇒ Any, t: Throwable): Unit
- Definition Classes
- Logging
-
def
warn(message: ⇒ Any): Unit
- Definition Classes
- Logging