org.apache.wss4j.dom.str
Class STRParserUtil

java.lang.Object
  extended by org.apache.wss4j.dom.str.STRParserUtil

public final class STRParserUtil
extends Object

Some utilities for the STRParsers.


Method Summary
static void checkBinarySecurityBSPCompliance(SecurityTokenReference secRef, BinarySecurity token, BSPEnforcer bspEnforcer)
          Check that the BinarySecurityToken referenced by the SecurityTokenReference argument is BSP compliant.
static void checkEncryptedKeyBSPCompliance(SecurityTokenReference secRef, BSPEnforcer bspEnforcer)
          Check that the EncryptedKey referenced by the SecurityTokenReference argument is BSP compliant.
static void checkSamlTokenBSPCompliance(SecurityTokenReference secRef, SamlAssertionWrapper samlAssertion, BSPEnforcer bspEnforcer)
          Check that the SAML token referenced by the SecurityTokenReference argument is BSP compliant.
static void checkUsernameTokenBSPCompliance(SecurityTokenReference secRef, BSPEnforcer bspEnforcer)
          Check that the Username token referenced by the SecurityTokenReference argument is BSP compliant.
static SamlAssertionWrapper getAssertionFromKeyIdentifier(SecurityTokenReference secRef, Element strElement, RequestData request, WSDocInfo wsDocInfo)
          Get an SamlAssertionWrapper object from parsing a SecurityTokenReference that uses a KeyIdentifier that points to a SAML Assertion.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getAssertionFromKeyIdentifier

public static SamlAssertionWrapper getAssertionFromKeyIdentifier(SecurityTokenReference secRef,
                                                                 Element strElement,
                                                                 RequestData request,
                                                                 WSDocInfo wsDocInfo)
                                                          throws WSSecurityException
Get an SamlAssertionWrapper object from parsing a SecurityTokenReference that uses a KeyIdentifier that points to a SAML Assertion.

Parameters:
secRef - the SecurityTokenReference to the SAML Assertion
strElement - The SecurityTokenReference DOM element
request - The RequestData instance used to obtain configuration
wsDocInfo - The WSDocInfo object that holds previous results
Returns:
an SamlAssertionWrapper object
Throws:
WSSecurityException

checkBinarySecurityBSPCompliance

public static void checkBinarySecurityBSPCompliance(SecurityTokenReference secRef,
                                                    BinarySecurity token,
                                                    BSPEnforcer bspEnforcer)
                                             throws WSSecurityException
Check that the BinarySecurityToken referenced by the SecurityTokenReference argument is BSP compliant.

Parameters:
secRef - The SecurityTokenReference to the BinarySecurityToken
token - The BinarySecurityToken
bspEnforcer - a BSPEnforcer instance to enforce BSP rules
Throws:
WSSecurityException

checkEncryptedKeyBSPCompliance

public static void checkEncryptedKeyBSPCompliance(SecurityTokenReference secRef,
                                                  BSPEnforcer bspEnforcer)
                                           throws WSSecurityException
Check that the EncryptedKey referenced by the SecurityTokenReference argument is BSP compliant.

Parameters:
secRef - The SecurityTokenReference to the BinarySecurityToken
bspEnforcer - a BSPEnforcer instance to enforce BSP rules
Throws:
WSSecurityException

checkSamlTokenBSPCompliance

public static void checkSamlTokenBSPCompliance(SecurityTokenReference secRef,
                                               SamlAssertionWrapper samlAssertion,
                                               BSPEnforcer bspEnforcer)
                                        throws WSSecurityException
Check that the SAML token referenced by the SecurityTokenReference argument is BSP compliant.

Parameters:
secRef - The SecurityTokenReference to the SAML token
samlAssertion - The SAML Token SamlAssertionWrapper object
bspEnforcer - a BSPEnforcer instance to enforce BSP rules
Throws:
WSSecurityException

checkUsernameTokenBSPCompliance

public static void checkUsernameTokenBSPCompliance(SecurityTokenReference secRef,
                                                   BSPEnforcer bspEnforcer)
                                            throws WSSecurityException
Check that the Username token referenced by the SecurityTokenReference argument is BSP compliant.

Parameters:
secRef - The SecurityTokenReference to the Username token
bspEnforcer - a BSPEnforcer instance to enforce BSP rules
Throws:
WSSecurityException


Copyright © 2004–2014 The Apache Software Foundation. All rights reserved.