Class WSConstants


  • public class WSConstants
    extends java.lang.Object
    Constants in WS-Security spec.
    • Field Detail

      • SOAPMESSAGE_NS11

        public static final java.lang.String SOAPMESSAGE_NS11
        See Also:
        Constant Field Values
      • USERNAMETOKEN_NS

        public static final java.lang.String USERNAMETOKEN_NS
        See Also:
        Constant Field Values
      • SAML_ASSERTION_ID

        public static final java.lang.String SAML_ASSERTION_ID
        See Also:
        Constant Field Values
      • USERNAME_TOKEN_LN

        public static final java.lang.String USERNAME_TOKEN_LN
        See Also:
        Constant Field Values
      • TIMESTAMP_TOKEN_LN

        public static final java.lang.String TIMESTAMP_TOKEN_LN
        See Also:
        Constant Field Values
      • PASSWORD_TYPE_ATTR

        public static final java.lang.String PASSWORD_TYPE_ATTR
        See Also:
        Constant Field Values
      • SIGNATURE_CONFIRMATION_LN

        public static final java.lang.String SIGNATURE_CONFIRMATION_LN
        See Also:
        Constant Field Values
      • WSS_SAML_ASSERTION

        public static final java.lang.String WSS_SAML_ASSERTION
        See Also:
        Constant Field Values
      • URIS_SOAP_ENV

        public static final java.lang.String[] URIS_SOAP_ENV
      • URI_SOAP11_NEXT_ACTOR

        public static final java.lang.String URI_SOAP11_NEXT_ACTOR
        See Also:
        Constant Field Values
      • URI_SOAP12_NEXT_ROLE

        public static final java.lang.String URI_SOAP12_NEXT_ROLE
        See Also:
        Constant Field Values
      • URI_SOAP12_NONE_ROLE

        public static final java.lang.String URI_SOAP12_NONE_ROLE
        See Also:
        Constant Field Values
      • URI_SOAP12_ULTIMATE_ROLE

        public static final java.lang.String URI_SOAP12_ULTIMATE_ROLE
        See Also:
        Constant Field Values
      • ATTR_MUST_UNDERSTAND

        public static final java.lang.String ATTR_MUST_UNDERSTAND
        See Also:
        Constant Field Values
      • PW_DIGEST

        public static final java.lang.String PW_DIGEST
        Sets the UserNameToken method to use a password digest to send the password information

        This is a required method as defined by WS Specification, Username token profile.

        See Also:
        Constant Field Values
      • PW_TEXT

        public static final java.lang.String PW_TEXT
        Sets the UserNameToken method to send the password in clear

        This is a required method as defined by WS Specification, Username token profile.

        See Also:
        Constant Field Values
      • KEYTRANSPORT_RSA15

        public static final java.lang.String KEYTRANSPORT_RSA15
        Sets the encryption method to encrypt the symmetric data encryption key with the RSA algoritm.

        This is a required method as defined by XML encryption.

        See Also:
        Constant Field Values
      • KEYTRANSPORT_RSAOEP

        public static final java.lang.String KEYTRANSPORT_RSAOEP
        Sets the encryption method to encrypt the symmetric data encryption key with the RSA algoritm.

        This is a required method as defined by XML encryption.

        NOTE: This algorithm is not yet supported by WSS4J

        See Also:
        Constant Field Values
      • TRIPLE_DES

        public static final java.lang.String TRIPLE_DES
        Sets the encryption method to use triple DES as the symmetric algorithm to encrypt data.

        This is a required method as defined by XML encryption. The String to use in WSDD file (in accordance to w3c specifications:
        http://www.w3.org/2001/04/xmlenc#tripledes-cbc

        See Also:
        Constant Field Values
      • AES_128

        public static final java.lang.String AES_128
        Sets the encryption method to use AES with 128 bit key as the symmetric algorithm to encrypt data.

        This is a required method as defined by XML encryption. The String to use in WSDD file (in accordance to w3c specifications:
        http://www.w3.org/2001/04/xmlenc#aes128-cbc

        See Also:
        Constant Field Values
      • AES_256

        public static final java.lang.String AES_256
        Sets the encryption method to use AES with 256 bit key as the symmetric algorithm to encrypt data.

        This is a required method as defined by XML encryption. The String to use in WSDD file (in accordance to w3c specifications:
        http://www.w3.org/2001/04/xmlenc#aes256-cbc

        See Also:
        Constant Field Values
      • AES_192

        public static final java.lang.String AES_192
        Sets the encryption method to use AES with 192 bit key as the symmetric algorithm to encrypt data.

        This is a optional method as defined by XML encryption. The String to use in WSDD file (in accordance to w3c specifications:
        http://www.w3.org/2001/04/xmlenc#aes192-cbc

        See Also:
        Constant Field Values
      • DSA

        public static final java.lang.String DSA
        Sets the signature method to use DSA with SHA1 (DSS) to sign data.

        This is a required method as defined by XML signature.

        See Also:
        Constant Field Values
      • RSA

        public static final java.lang.String RSA
        Sets the signature method to use RSA with SHA to sign data.

        This is a recommended method as defined by XML signature.

        See Also:
        Constant Field Values
      • C14N_OMIT_COMMENTS

        public static final java.lang.String C14N_OMIT_COMMENTS
        See Also:
        Constant Field Values
      • C14N_WITH_COMMENTS

        public static final java.lang.String C14N_WITH_COMMENTS
        See Also:
        Constant Field Values
      • C14N_EXCL_OMIT_COMMENTS

        public static final java.lang.String C14N_EXCL_OMIT_COMMENTS
        See Also:
        Constant Field Values
      • C14N_EXCL_WITH_COMMENTS

        public static final java.lang.String C14N_EXCL_WITH_COMMENTS
        See Also:
        Constant Field Values
      • BST_DIRECT_REFERENCE

        public static final int BST_DIRECT_REFERENCE
        Sets the signing method to send the signing certificate as a BinarySecurityToken.

        The signing method takes the signing certificate, converts it to a BinarySecurityToken, puts it in the security header, and inserts a Reference to the binary security token into the wsse:SecurityReferenceToken. Thus the whole signing certificate is transfered to the receiver. The X509 profile recommends to use ISSUER_SERIAL instead of sending the whole certificate.

        Please refer to WS Security specification X509 profile, chapter 3.3.2 and to WS Security specification, chapter 7.2

        Note: only local refernces to BinarySecurityToken are supported

        See Also:
        Constant Field Values
      • ISSUER_SERIAL

        public static final int ISSUER_SERIAL
        Sets the signing or the encryption method to send the issuer name and the serial number of a certificate to the receiver.

        In contrast to BST_DIRECT_REFERENCE only the issuer name and the serial number of the signiung certificate are sent to the receiver. This reduces the amount of data being sent. The ecnryption method uses the public key associated with this certificate to encrypt the symmetric key used to encrypt data.

        Please refer to WS Security specification X509 profile, chapter 3.3.3

        See Also:
        Constant Field Values
      • X509_KEY_IDENTIFIER

        public static final int X509_KEY_IDENTIFIER
        Sets the encryption method to send the certificate used to encrypt the symmetric key.

        The encryption method uses the public key associated with this certificate to encrypr the symmetric key used to encrypt data. The certificate is converted into a KeyIdentfier token and sent to the receiver. Thus the complete certificate data is transfered to receiver. The X509 profile recommends to use ISSUER_SERIAL instead of sending the whole certificate.

        Please refer to WS Security specification X509 profile, chapter 7.3

        See Also:
        Constant Field Values
      • SKI_KEY_IDENTIFIER

        public static final int SKI_KEY_IDENTIFIER
        Sets the signing method to send a SubjectKeyIdentifier to identify the signing certificate.

        Refer to WS Security specification X509 profile, chapter 3.3.1 This identification token is not yet fully tested by WSS4J. The WsDoAllSender does not include the X.509 certificate as BinarySecurityToken in the request message.

        See Also:
        Constant Field Values
      • EMBEDDED_KEYNAME

        public static final int EMBEDDED_KEYNAME
        Embeds a keyinfo/key name into the EncryptedData element.

        Refer to WS Security specification X509 profile

        See Also:
        Constant Field Values
      • EMBED_SECURITY_TOKEN_REF

        public static final int EMBED_SECURITY_TOKEN_REF
        Embeds a keyinfo/wsse:SecurityTokenReference into EncryptedData element.
        See Also:
        Constant Field Values
      • UT_SIGNING

        public static final int UT_SIGNING
        UT_SIGNING is used interally only to set a specific Signature behaviour. The signing token is constructed from values in the UsernameToken according to WS-Trust specification.
        See Also:
        Constant Field Values
      • THUMBPRINT_IDENTIFIER

        public static final int THUMBPRINT_IDENTIFIER
        THUMPRINT_IDENTIFIER is used to set the specific key identifier ThumbprintSHA1. This identifier uses the SHA-1 digest of a security token to identify the security token. Please refer to chapter 7.2 of the OASIS WSS 1.1 specification.
        See Also:
        Constant Field Values
      • WSE_DERIVED_KEY_LEN

        public static final int WSE_DERIVED_KEY_LEN
        Length of UsernameToken derived key used by .NET WSE to sign a message.
        See Also:
        Constant Field Values
      • LABEL_FOR_DERIVED_KEY

        public static final java.lang.String LABEL_FOR_DERIVED_KEY
        See Also:
        Constant Field Values
    • Constructor Detail

      • WSConstants

        public WSConstants()