Module org.elasticsearch.security
Class ApiKeyService.ApiKeyCredentials
java.lang.Object
org.elasticsearch.xpack.security.authc.ApiKeyService.ApiKeyCredentials
- All Implemented Interfaces:
Closeable,AutoCloseable,AuthenticationToken
- Enclosing class:
ApiKeyService
public static final class ApiKeyService.ApiKeyCredentials
extends Object
implements AuthenticationToken, Closeable
-
Constructor Summary
ConstructorsConstructorDescriptionApiKeyCredentials(String id, SecureString key, ApiKey.Type expectedType) ApiKeyCredentials(String id, SecureString key, ApiKey.Type expectedType, String certificateIdentity) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidclose()The identity (Subject DistinguishedName) of the X.509 certificate that was provided by the client alongside the API during authenticate.
-
Constructor Details
-
ApiKeyCredentials
-
ApiKeyCredentials
public ApiKeyCredentials(String id, SecureString key, ApiKey.Type expectedType, @Nullable String certificateIdentity)
-
-
Method Details
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
principal
- Specified by:
principalin interfaceAuthenticationToken
-
credentials
- Specified by:
credentialsin interfaceAuthenticationToken
-
clearCredentials
public void clearCredentials()- Specified by:
clearCredentialsin interfaceAuthenticationToken
-
getExpectedType
-
getCertificateIdentity
The identity (Subject DistinguishedName) of the X.509 certificate that was provided by the client alongside the API during authenticate. At the time of writing, the only place where this is used is for cross cluster request signing
-