public interface SecurityTokenProvider
This interface defines the methods that must be implemented by security token providers.
Modifier and Type | Interface and Description |
---|---|
static class |
SecurityTokenProvider.FAMILY_TYPE
An enumeration that identifies the family to which the security token provider belongs
|
Modifier and Type | Method and Description |
---|---|
void |
cancelToken(ProtocolContext context)
Cancels the token contained in the specified request context.
|
String |
family()
The family where this security token provider belongs
|
QName |
getSupportedQName()
Provide an optional
QName for configuration |
void |
initialize(Map<String,String> properties)
Initializes the
SecurityTokenProvider using the specified properties map. |
void |
issueToken(ProtocolContext context)
Generates a security token using the information contained in the specified request context and stores the
newly-created
token in the context itself.
|
void |
renewToken(ProtocolContext context)
Renews the security token contained in the specified request context.
|
boolean |
supports(String namespace)
Specify whether this token provider supports a particular namespace
|
String |
tokenType()
Token Type
|
void |
validateToken(ProtocolContext context)
Evaluates the validity of the token contained in the specified request context and sets the result in the context
itself.
|
void initialize(Map<String,String> properties)
Initializes the SecurityTokenProvider
using the specified properties map.
properties
- a Map<String, String>
that contains the properties that have been configured for this
SecurityTokenProvider
.boolean supports(String namespace)
namespace
- a string value representing a namespaceString tokenType()
QName getSupportedQName()
QName
for configurationString family()
FAMILY_TYPE}
void issueToken(ProtocolContext context) throws ProcessingException
Generates a security token using the information contained in the specified request context and stores the newly-created token in the context itself.
context
- the ProtocolContext
to be used when generating the token.WSTrustException
- if an error occurs while creating the security token.ProcessingException
void renewToken(ProtocolContext context) throws ProcessingException
Renews the security token contained in the specified request context. This method is used when a previously generated token has expired, generating a new version of the same token with different expiration semantics.
context
- the ProtocolContext
that contains the token to be renewed.WSTrustException
- if an error occurs while renewing the security token.ProcessingException
void cancelToken(ProtocolContext context) throws ProcessingException
Cancels the token contained in the specified request context. A security token is usually canceled when one wants to make sure that the token will not be used anymore. A security token can't be renewed once it has been canceled.
context
- the ProtocolContext
that contains the token to be canceled.WSTrustException
- if an error occurs while canceling the security token.ProcessingException
void validateToken(ProtocolContext context) throws ProcessingException
Evaluates the validity of the token contained in the specified request context and sets the result in the context itself. The result can be a status, a new token, or both.
context
- the ProtocolContext
that contains the token to be validated.WSTrustException
- if an error occurs while validating the security token.ProcessingException
Copyright © 2017 JBoss by Red Hat. All rights reserved.