public interface TavernaSecurityContext
Modifier and Type | Method and Description |
---|---|
void |
addCredential(Credential toAdd)
Add a credential to the owned set or replaces the old version with the
new one.
|
void |
addTrusted(Trust toAdd)
Add an identity to the trusted set.
|
void |
conveySecurity()
Transfer the security context to the remote system.
|
void |
deleteCredential(Credential toDelete)
Remove a credential from the owned set.
|
void |
deleteTrusted(Trust toDelete)
Remove an identity from the trusted set.
|
Credential[] |
getCredentials() |
SecurityContextFactory |
getFactory() |
UsernamePrincipal |
getOwner() |
Set<String> |
getPermittedDestroyers()
Describe the names of the users (as extracted from their
Principal objects) that may destroy the run or manipulate its
lifetime. |
Set<String> |
getPermittedReaders()
Describe the names of the users (as extracted from their
Principal objects) that may read from the run (including its
files). |
Set<String> |
getPermittedUpdaters()
Describe the names of the users (as extracted from their
Principal objects) that may update the run (including writing to
files). |
Trust[] |
getTrusted() |
void |
initializeSecurityFromContext(org.springframework.security.core.context.SecurityContext securityContext)
Establish the security context from how the owning workflow run was
created.
|
void |
initializeSecurityFromRESTContext(javax.ws.rs.core.HttpHeaders headers)
Establish the security context from how the owning workflow run was
created.
|
void |
initializeSecurityFromSOAPContext(MessageContext context)
Establish the security context from how the owning workflow run was
created.
|
void |
setPermittedDestroyers(Set<String> destroyers)
Sets the collection of names of users (as extracted from their
Principal objects) that may destroy the run or manipulate its
lifetime. |
void |
setPermittedReaders(Set<String> readers)
Sets the collection of names of users (as extracted from their
Principal objects) that may read from the run (including its
files). |
void |
setPermittedUpdaters(Set<String> updaters)
Sets the collection of names of users (as extracted from their
Principal objects) that may update the run (including writing to
its files). |
void |
validateCredential(Credential c)
Tests if the credential is valid.
|
void |
validateTrusted(Trust t)
Tests if the trusted identity descriptor is valid.
|
UsernamePrincipal getOwner()
Set<String> getPermittedDestroyers()
Principal
objects) that may destroy the run or manipulate its
lifetime.void setPermittedDestroyers(Set<String> destroyers)
Principal
objects) that may destroy the run or manipulate its
lifetime.destroyers
- The names of the users who may use destroy operations.Set<String> getPermittedUpdaters()
Principal
objects) that may update the run (including writing to
files).void setPermittedUpdaters(Set<String> updaters)
Principal
objects) that may update the run (including writing to
its files).updaters
- The names of the users who may use update operations.Set<String> getPermittedReaders()
Principal
objects) that may read from the run (including its
files).void setPermittedReaders(Set<String> readers)
Principal
objects) that may read from the run (including its
files).readers
- The names of the users who may use read operations.Credential[] getCredentials()
void addCredential(Credential toAdd)
toAdd
- The credential to add.void deleteCredential(Credential toDelete)
toDelete
- The credential to remove.void validateCredential(Credential c) throws InvalidCredentialException
Credential
object.c
- The credential object to validate.InvalidCredentialException
- If it is invalid.Trust[] getTrusted()
void addTrusted(Trust toAdd)
toAdd
- The identity to add.void deleteTrusted(Trust toDelete)
toDelete
- The identity to remove.void validateTrusted(Trust t) throws InvalidCredentialException
t
- The trusted identity descriptor to check.InvalidCredentialException
- If it is invalid.void initializeSecurityFromContext(org.springframework.security.core.context.SecurityContext securityContext) throws Exception
securityContext
- The security context associated with the request that caused
the workflow to be created.Exception
- If anything goes wrong.void initializeSecurityFromSOAPContext(MessageContext context)
context
- The full information about the request that caused the
workflow to be created.void initializeSecurityFromRESTContext(javax.ws.rs.core.HttpHeaders headers)
headers
- The full information about the request that caused the
workflow to be created.void conveySecurity() throws GeneralSecurityException, IOException, ImplementationException
IOException
- If the communication fails.GeneralSecurityException
- If the assembly of the context fails.ImplementationException
- If the local worker has problems with creating the realized
security context.SecurityContextFactory getFactory()
Copyright © 2015–2018 The Apache Software Foundation. All rights reserved.