I start with this document:
<env:Envelope 
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";><env:Body><elem>aa</elem></env:Body></env:Envelope>

I encrypt the <elem> element and immediately decrypt it. The resulting document 
has an extra namespace declaration:
<env:Envelope 
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";><env:Body><elem 
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";>aa</elem></env:Body></env:Envelope>

The funny thing is, if I encrypt two sibling <elem> elements, only the first 
one has the extra namespace declaration.
I tried with xmlsec 1.4.5 and 1.5.1

Is this a bug or the expected behavior?

Attachment: TestExtraXmlns.java
Description: TestExtraXmlns.java

Reply via email to