public final class SOAPMessageSecurityProvider
extends java.lang.Object
Class that allows to secure and encrypt the SOAP requests.
Project:Library for the integration with the services of @Firma, eVisor and TS@.
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
AUTHENTICATION_CERTIFICATE
Constant attribute that identifies the Web Services Security X.509 Certificate Token Profile, used to secure the SOAP messages.
|
static java.lang.String |
AUTHENTICATION_SAML
Constant attribute that identifies the Web Services Security SAML Token Profile, used to secure the SOAP messages.
|
static java.lang.String |
AUTHENTICATION_USER_PASSWORD
Constant attribute that identifies the Web Services Security UsernameToken Profile, used to secure the SOAP messages.
|
static java.lang.String |
INCLUSION_METHOD_DIRECT
Constant attribute that identifies the direct inclusion mode (BinarySecurityToken) of the X.509 certificate for the Web Services Security X.509
Certificate Token Profile.
|
static java.lang.String |
INCLUSION_METHOD_IDENTIFIER
Constant attribute that identifies the subject key identifier inclusion mode (KeyIdentifier) of the X.509 certificate for the Web Services
Security X.509 Certificate Token Profile.
|
static java.lang.String |
INCLUSION_METHOD_ISSUERSERIALNUMBER
Constant attribute that identifies the issuer and serial number inclusion mode (X509IssuerSerial) of the X.509 certificate for the Web Services
Security X.509 Certificate Token Profile.
|
static java.lang.String |
SAML_HOLDER_OF_KEY
Constant attribute that identifies the holder-of-key mandatory subject confirmation method for the Web Services Security SAML Token Profile.
|
static java.lang.String |
SAML_SENDER_VOUCHEZ
Constant attribute that identifies the sender-vouchez mandatory subject confirmation method for the Web Services Security SAML Token Profile.
|
static java.lang.String |
TAG_ALIAS
Constant attribute that identifies the tag to replace with the alias of the symmetric key to encrypt the SOAP requests.
|
static java.lang.String |
TAG_ENCRYPT
Constant attribute that identifies the tag to replace with the value of the symmetric key to encrypt the SOAP requests.
|
static java.lang.String |
TAG_PASSWORD
Constant attribute that identifies the tag to replace with the value of the password to secure the SOAP requests with UsernameToken.
|
static java.lang.String |
TAG_REFERENCE_TYPE
Constant attribute that identifies the tag to replace with the inclusion mode of the certificate used to secure the SOAP requests with X.509
Certificate Token.
|
static java.lang.String |
TAG_USER
Constant attribute that identifies the tag to replace with the value of the user to secure the SOAP requests with UsernameToken.
|
static java.lang.String |
XML_SAMLTOKEN_HOK
Constant attribute that represents the security header to secure the SOAP requests with SAML Token (holder-of-key).
|
static java.lang.String |
XML_SAMLTOKEN_SV
Constant attribute that represents the security header to secure the SOAP requests with SAML Token (sender-vouchez).
|
static java.lang.String |
XML_SYMMETRIC_KEY
Constant attribute that represents the tag to encrypt the SOAP requests with symmetric key.
|
static java.lang.String |
XML_USERNAMETOKEN
Constant attribute that represents the security header to secure the SOAP requests with UsernameToken.
|
static java.lang.String |
XML_X509CERTIFICATETOKEN
Constant attribute that represents the security header to secure the SOAP requests with X.509 Certificate Token.
|
static java.lang.String |
XML_XWSS
Constant attribute that represents the security header to secure the SOAP messages.
|
| Modifier and Type | Method and Description |
|---|---|
static java.io.InputStream |
generateInputStream(java.lang.String xmlInput)
Method that obtains an
InputStream from a String. |
static java.io.InputStream |
generateXMLSAMLToken(java.lang.String mandatorySubjectConfirmationMethod,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
Method that obtains an
InputStream as the security header to secure a SOAP message with SAML Token. |
static java.io.InputStream |
generateXMLUserNameToken(java.lang.String userName,
java.lang.String userPassword,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
Method that obtains an
InputStream as the security header to secure a SOAP message with UsernameToken. |
static java.io.InputStream |
generateXMLX509CertificateToken(java.lang.String certificateInclussionMode,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
Method that obtains an
InputStream as the security header to secure a SOAP message with X.509 Certificate Token. |
public static final java.lang.String AUTHENTICATION_USER_PASSWORD
public static final java.lang.String AUTHENTICATION_CERTIFICATE
public static final java.lang.String AUTHENTICATION_SAML
public static final java.lang.String INCLUSION_METHOD_DIRECT
public static final java.lang.String INCLUSION_METHOD_IDENTIFIER
public static final java.lang.String INCLUSION_METHOD_ISSUERSERIALNUMBER
public static final java.lang.String SAML_HOLDER_OF_KEY
public static final java.lang.String SAML_SENDER_VOUCHEZ
public static final java.lang.String TAG_ENCRYPT
public static final java.lang.String TAG_USER
public static final java.lang.String TAG_PASSWORD
public static final java.lang.String TAG_ALIAS
public static final java.lang.String TAG_REFERENCE_TYPE
public static final java.lang.String XML_USERNAMETOKEN
public static final java.lang.String XML_SYMMETRIC_KEY
public static final java.lang.String XML_X509CERTIFICATETOKEN
public static final java.lang.String XML_SAMLTOKEN_HOK
public static final java.lang.String XML_SAMLTOKEN_SV
public static final java.lang.String XML_XWSS
public static java.io.InputStream generateXMLUserNameToken(java.lang.String userName,
java.lang.String userPassword,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
InputStream as the security header to secure a SOAP message with UsernameToken.userName - Parameter that represents the user name.userPassword - Parameter that represents the user password.useSymmetricKey - Parameter that indicates if to use symmetric key to encrypt the SOAP message (true), or not (false).symmetricKeyAlias - Parameter that represents the alias of the symmetric key used to encrypt the SOAP message.InputStream as the security header to secure a SOAP message with UsernameToken.public static java.io.InputStream generateXMLX509CertificateToken(java.lang.String certificateInclussionMode,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
InputStream as the security header to secure a SOAP message with X.509 Certificate Token.certificateInclussionMode - Parameter that represents the certificate inclusion mode.useSymmetricKey - Parameter that indicates if to use symmetric key to encrypt the SOAP message (true), or not (false).symmetricKeyAlias - Parameter that represents the alias of the symmetric key used to encrypt the SOAP message.InputStream as the security header to secure a SOAP message with X.509 Certificate Token.public static java.io.InputStream generateXMLSAMLToken(java.lang.String mandatorySubjectConfirmationMethod,
boolean useSymmetricKey,
java.lang.String symmetricKeyAlias)
InputStream as the security header to secure a SOAP message with SAML Token.mandatorySubjectConfirmationMethod - Parameter that represents the mandatory subject confirmation method.useSymmetricKey - Parameter that indicates if to use symmetric key to encrypt the SOAP message (true), or not (false).symmetricKeyAlias - Parameter that represents the alias of the symmetric key used to encrypt the SOAP message.InputStream as the security header to secure a SOAP message with SAML Token.public static java.io.InputStream generateInputStream(java.lang.String xmlInput)
InputStream from a String.xmlInput - Parameter that represents the source String.InputStream.