Class GitHubAuthentication
java.lang.Object
org.springframework.vault.authentication.GitHubAuthentication
- All Implemented Interfaces:
AuthenticationStepsFactory,ClientAuthentication
public class GitHubAuthentication
extends Object
implements ClientAuthentication, AuthenticationStepsFactory
GitHub's authentication method can be used to authenticate with Vault using a GitHub
personal access token.
- Since:
- 3.2
- Author:
- Nanne Baars, Mark Paluch
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGitHubAuthentication(GitHubAuthenticationOptions options, RestClient client) GitHubAuthentication(GitHubAuthenticationOptions options, RestOperations restOperations) -
Method Summary
Modifier and TypeMethodDescriptionstatic AuthenticationStepsCreates aAuthenticationStepsfor GitHub authentication givenGitHubAuthenticationOptions.Get theAuthenticationStepsdescribing an authentication flow.login()Return aVaultToken.
-
Constructor Details
-
GitHubAuthentication
- Parameters:
options- must not be null.restOperations- must not be null.
-
GitHubAuthentication
- Parameters:
options- must not be null.client- must not be null.- Since:
- 4.0
-
-
Method Details
-
createAuthenticationSteps
Creates aAuthenticationStepsfor GitHub authentication givenGitHubAuthenticationOptions.- Parameters:
options- must not be null.- Returns:
AuthenticationStepsfor github authentication.
-
getAuthenticationSteps
Description copied from interface:AuthenticationStepsFactoryGet theAuthenticationStepsdescribing an authentication flow.- Specified by:
getAuthenticationStepsin interfaceAuthenticationStepsFactory- Returns:
- the
AuthenticationStepsdescribing an authentication flow.
-
login
Description copied from interface:ClientAuthenticationReturn aVaultToken. This method can optionally log into Vault to obtain atoken.- Specified by:
loginin interfaceClientAuthentication- Returns:
- a
VaultToken. - Throws:
VaultException
-