Author: coheigea
Date: Fri Apr  1 13:03:24 2011
New Revision: 1087692

URL: http://svn.apache.org/viewvc?rev=1087692&view=rev
Log:
Added a method to return the wsu:Id of a SecurityTokenReference, and store a 
constructed SAML Assertion element.

Modified:
    
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/message/token/SecurityTokenReference.java
    
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/saml/ext/AssertionWrapper.java

Modified: 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/message/token/SecurityTokenReference.java
URL: 
http://svn.apache.org/viewvc/webservices/wss4j/trunk/src/main/java/org/apache/ws/security/message/token/SecurityTokenReference.java?rev=1087692&r1=1087691&r2=1087692&view=diff
==============================================================================
--- 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/message/token/SecurityTokenReference.java
 (original)
+++ 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/message/token/SecurityTokenReference.java
 Fri Apr  1 13:03:24 2011
@@ -759,6 +759,14 @@ public class SecurityTokenReference {
     public void setID(String id) {
         element.setAttributeNS(WSConstants.WSU_NS, WSConstants.WSU_PREFIX + 
":Id", id);
     }
+    
+    /**
+     * Get the id
+     * @return the wsu ID of the element
+     */
+    public String getID() {
+        return element.getAttributeNS(WSConstants.WSU_NS, "Id");
+    }
 
     /**
      * return the string representation.

Modified: 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/saml/ext/AssertionWrapper.java
URL: 
http://svn.apache.org/viewvc/webservices/wss4j/trunk/src/main/java/org/apache/ws/security/saml/ext/AssertionWrapper.java?rev=1087692&r1=1087691&r2=1087692&view=diff
==============================================================================
--- 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/saml/ext/AssertionWrapper.java
 (original)
+++ 
webservices/wss4j/trunk/src/main/java/org/apache/ws/security/saml/ext/AssertionWrapper.java
 Fri Apr  1 13:03:24 2011
@@ -366,7 +366,8 @@ public class AssertionWrapper {
      * @return Element
      */
     public Element toDOM(Document doc) throws WSSecurityException {
-        return OpenSAMLUtil.toDom(xmlObject, doc);
+        assertionElement = OpenSAMLUtil.toDom(xmlObject, doc);
+        return assertionElement;
     }
 
     /**


Reply via email to