OpenSAML-J 2.4.1-redhat-3

org.opensaml.saml1.binding.encoding
Class BaseSAML1MessageEncoder

java.lang.Object
  extended by org.opensaml.ws.message.encoder.BaseMessageEncoder
      extended by org.opensaml.saml1.binding.encoding.BaseSAML1MessageEncoder
All Implemented Interfaces:
SAMLMessageEncoder, org.opensaml.ws.message.encoder.MessageEncoder
Direct Known Subclasses:
HTTPArtifactEncoder, HTTPPostEncoder, HTTPSOAP11Encoder

public abstract class BaseSAML1MessageEncoder
extends org.opensaml.ws.message.encoder.BaseMessageEncoder
implements SAMLMessageEncoder

Base class for SAML 1 message encoders.


Constructor Summary
BaseSAML1MessageEncoder()
           
 
Method Summary
 List<String> getAllowedURLSchemes()
          Gets the unmodifiable list of schemes allowed to appear in URLs related to the encoded message.
protected  org.opensaml.util.URLBuilder getEndpointURL(SAMLMessageContext messageContext)
          Gets the response URL from the relying party endpoint.
 void setAllowedURLSchemes(String[] schemes)
          Sets the list of list of schemes allowed to appear in URLs related to the encoded message.
protected  void signMessage(SAMLMessageContext messageContext)
          Signs the given SAML message if it a SignableSAMLObject and this encoder has signing credentials.
 
Methods inherited from class org.opensaml.ws.message.encoder.BaseMessageEncoder
doEncode, encode, logEncodedMessage, marshallMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.opensaml.common.binding.encoding.SAMLMessageEncoder
getBindingURI
 
Methods inherited from interface org.opensaml.ws.message.encoder.MessageEncoder
encode, providesMessageConfidentiality, providesMessageIntegrity
 

Constructor Detail

BaseSAML1MessageEncoder

public BaseSAML1MessageEncoder()
Method Detail

getAllowedURLSchemes

public List<String> getAllowedURLSchemes()
Gets the unmodifiable list of schemes allowed to appear in URLs related to the encoded message.

Returns:
list of URL schemes allowed to appear in a message

setAllowedURLSchemes

public void setAllowedURLSchemes(String[] schemes)
Sets the list of list of schemes allowed to appear in URLs related to the encoded message. Note, the appearance of schemes such as 'javascript' may open the system up to attacks (e.g. cross-site scripting attacks).

Parameters:
schemes - URL schemes allowed to appear in a message

getEndpointURL

protected org.opensaml.util.URLBuilder getEndpointURL(SAMLMessageContext messageContext)
                                               throws org.opensaml.ws.message.encoder.MessageEncodingException
Gets the response URL from the relying party endpoint. If the SAML message is a Response and the relying party endpoint contains a response location then that location is returned otherwise the normal endpoint location is returned.

Parameters:
messageContext - current message context
Returns:
response URL from the relying party endpoint
Throws:
org.opensaml.ws.message.encoder.MessageEncodingException - throw if no relying party endpoint is available

signMessage

protected void signMessage(SAMLMessageContext messageContext)
                    throws org.opensaml.ws.message.encoder.MessageEncodingException
Signs the given SAML message if it a SignableSAMLObject and this encoder has signing credentials.

Parameters:
messageContext - current message context
Throws:
org.opensaml.ws.message.encoder.MessageEncodingException - thrown if there is a problem preparing the signature for signing

OpenSAML-J 2.4.1-redhat-3

Copyright © 2006-2012 Internet2. All Rights Reserved.