Package com.mwdle.bitwarden
Class BitwardenCredentialsStore
java.lang.Object
com.cloudbees.plugins.credentials.CredentialsStore
com.mwdle.bitwarden.BitwardenCredentialsStore
- All Implemented Interfaces:
Saveable
,AccessControlled
public class BitwardenCredentialsStore
extends com.cloudbees.plugins.credentials.CredentialsStore
A simple, stateless view of the
BitwardenCredentialsProvider
for the Jenkins UI.
This class's only responsibility is to provide a list of Bitwarden credentials to be displayed in the Jenkins "Credentials" page. It acts as a read-only view and delegates all credential-listing logic to the provider.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
The UI action that makes this store visible in the Jenkins sidebar and credentials list. -
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs the store. -
Method Summary
Modifier and TypeMethodDescriptionboolean
addCredentials
(com.cloudbees.plugins.credentials.domains.Domain domain, com.cloudbees.plugins.credentials.Credentials credentials) Unsupported operation.ItemGroup<?>
List<com.cloudbees.plugins.credentials.Credentials>
getCredentials
(com.cloudbees.plugins.credentials.domains.Domain domain) com.cloudbees.plugins.credentials.CredentialsStoreAction
boolean
hasPermission2
(org.springframework.security.core.Authentication a, Permission permission) boolean
removeCredentials
(com.cloudbees.plugins.credentials.domains.Domain domain, com.cloudbees.plugins.credentials.Credentials credentials) Unsupported operation.boolean
updateCredentials
(com.cloudbees.plugins.credentials.domains.Domain domain, com.cloudbees.plugins.credentials.Credentials current, com.cloudbees.plugins.credentials.Credentials replacement) Unsupported operation.Methods inherited from class com.cloudbees.plugins.credentials.CredentialsStore
_isApplicable, addDomain, addDomain, checkPermission, getACL, getContextDisplayName, getCredentialsDescriptors, getDomainByName, getDomains, getProvider, getProviderOrDie, getRelativeLinkTo, getRelativeLinkToAction, getRelativeLinkToContext, getScopes, hasPermission, hasPermission, isApplicable, isDomainsModifiable, removeDomain, save, updateDomain
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface hudson.security.AccessControlled
checkAnyPermission, hasAnyPermission
-
Constructor Details
-
BitwardenCredentialsStore
Constructs the store.- Parameters:
provider
- The provider that this store will represent in the UI.
-
-
Method Details
-
getContext
- Specified by:
getContext
in classcom.cloudbees.plugins.credentials.CredentialsStore
-
hasPermission2
public boolean hasPermission2(@Nonnull org.springframework.security.core.Authentication a, @Nonnull Permission permission) Delegates permission checks to the Jenkins root ACL.
- Specified by:
hasPermission2
in interfaceAccessControlled
- Overrides:
hasPermission2
in classcom.cloudbees.plugins.credentials.CredentialsStore
-
getStoreAction
public com.cloudbees.plugins.credentials.CredentialsStoreAction getStoreAction()- Overrides:
getStoreAction
in classcom.cloudbees.plugins.credentials.CredentialsStore
-
getDisplayName
- Overrides:
getDisplayName
in classcom.cloudbees.plugins.credentials.CredentialsStore
-
addCredentials
public boolean addCredentials(@Nonnull com.cloudbees.plugins.credentials.domains.Domain domain, @Nonnull com.cloudbees.plugins.credentials.Credentials credentials) Unsupported operation. Credentials must be managed in Bitwarden.- Specified by:
addCredentials
in classcom.cloudbees.plugins.credentials.CredentialsStore
- Returns:
- always
false
.
-
removeCredentials
public boolean removeCredentials(@Nonnull com.cloudbees.plugins.credentials.domains.Domain domain, @Nonnull com.cloudbees.plugins.credentials.Credentials credentials) Unsupported operation. Credentials must be managed in Bitwarden.- Specified by:
removeCredentials
in classcom.cloudbees.plugins.credentials.CredentialsStore
- Returns:
- always
false
.
-
updateCredentials
public boolean updateCredentials(@Nonnull com.cloudbees.plugins.credentials.domains.Domain domain, @Nonnull com.cloudbees.plugins.credentials.Credentials current, @Nonnull com.cloudbees.plugins.credentials.Credentials replacement) Unsupported operation. Credentials must be managed in Bitwarden.- Specified by:
updateCredentials
in classcom.cloudbees.plugins.credentials.CredentialsStore
- Returns:
- always
false
.
-
getCredentials
@Nonnull public List<com.cloudbees.plugins.credentials.Credentials> getCredentials(@Nonnull com.cloudbees.plugins.credentials.domains.Domain domain) Returns the list of credentials to be displayed in the UI. This method delegates to the provider's safe
listCredentials
method.- Specified by:
getCredentials
in classcom.cloudbees.plugins.credentials.CredentialsStore
-