axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christian Geuer-Pollmann <>
Subject Re: XML Security Job Offer: Axis Connector
Date Fri, 11 Jan 2002 10:00:20 GMT

--On Donnerstag, 10. Januar 2002 22:01 -0800 "Theodore W. Leung" 
<> wrote:

> So I thought to fix this by getting the env as a DOM  again, but then I
> need to create a new signature using that DOM.  And that does't seem to
> be working.  I need a way to create just an empty signature element and
> add that as a header before creating the signature value.

When you call XMLSignature.sign(), the Signature locates the Noes to be 
signed based on it's own position, so if you create a signature for "#Body" 
it tries to traverse the tree in which itself is. If the signature is not 
part of a tree (header.getElement().appendChild(signature.getElement()) was 
not called), then the traversal fails. You must ensure that signature and 
signed contents are "connected" via the DOM before you call sign().


View raw message