<html><body><div style="color:#000; background-color:#fff; font-family:tahoma, new york, times, serif;font-size:10pt">Thanks Brent! I replaced the code for marshalling with response.getDOM() and everything works fine. <br><br>Thanks again to help me resolve this issue!<br><div><span><br></span></div><div><br></div>  <div style="font-family: tahoma, new york, times, serif; font-size: 10pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <hr size="1">  <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> Brent Putman &lt;putmanb@georgetown.edu&gt;<br> <b><span style="font-weight: bold;">To:</span></b> dev@shibboleth.net <br> <b><span style="font-weight: bold;">Sent:</span></b> Monday, May 13, 2013 4:55 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: error validating signature on Jboss<br> </font> </div> <div class="y_msg_container"><br>
<br>On 5/13/13 7:25 PM, Mitu Singh wrote:<br>&gt; Brent,<br>&gt;<br>&gt; I am endorsing the jars on my server.<br>&gt;<br>&gt; I am printing the response xml using the following code before I<br>&gt; validate the signature:<br>&gt;<br><br>Ah, yes, that would be the problem then.<br><br>&gt;&nbsp; &nbsp; &nbsp; &nbsp;  <br>&gt;<br>&gt; If I comment out the above code, the signature validator validates<br>&gt; corrrectly. Does the above code in anyway modify the Response?<br><br>It doesn't modify the Response per se, but what you are telling it to do<br>is re-marshall the DOM, and that has consequences.&nbsp; As part of<br>marshalling, the DOM tree gets adopted into a new Document, and that<br>causes ID-ness to be lost.&nbsp; I vaguely remembered this coming up before,<br>here's a couple of links I found [1][2].<br><br>The gist is that losing ID-ness on adoption is the expected behavior of<br>Xerces.&nbsp; So when you remarshall, the ID-ness that was set
 by the<br>unmarshaller is being undone by the marshalling process.&nbsp; There's not<br>much we can do about that in OpenSAML, I think.<br><br>So don't do that.&nbsp; :-) Note that if you just want to log the received<br>protocol message, and you are using our decoder, you can just set a<br>special logging category of "PROTOCOL_MESSAGE" to level DEBUG in your<br>logging config, and it will get logged to that category.&nbsp; If not using<br>our decoder, you can also just grab the unmarshalled element directly by<br>using response.getDOM(), avoiding the need to actually explicitly<br>marshall the XMLObject again.<br><br>--Brent<br><br><br>[1] <a href="https://issues.apache.org/jira/browse/XERCESJ-1022" target="_blank">https://issues.apache.org/jira/browse/XERCESJ-1022</a><br>[2]<br>http://apache-xml-project.6118.n7.nabble.com/importNode-adoptNode-and-getElementById-td1526.html<br><br>--<br>To unsubscribe from this list send an email to <a
 ymailto="mailto:dev-unsubscribe@shibboleth.net" href="mailto:dev-unsubscribe@shibboleth.net">dev-unsubscribe@shibboleth.net</a><br><br><br></div> </div> </div>  </div></body></html>