You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@santuario.apache.org by Stampacchia Francesco <fr...@ttclab.com> on 2009/02/23 10:42:06 UTC
Issue in XML tag decryption
Hi to everyone!
I have a little question about the decryption procedure.
I can easily encrypt and decrypt an XML file using XPath specification (so that
I can encrypt and decrypt only single message parts), but I find, after the
decryption phase, this little problem.
The tag immediatly after the one that I choose to encrypt with XPath shows the
entire xml schema definition (xmlns:....).
Here i'll give you an example:
Plain message:
<msg:Object>
<msg:Data1>255</msg:Data1>
<msg:Data2>255</msg:Data2>
<msg:Data3>255</msg:Data3>
.
.
.
</msg:Object>
I choose to encrypt the following simple XPath: //msg:Object (keep in mind that
I manage xml messages with multiple msg:Object tags)
I can afford with success encryption and decryption, then i get the following:
Decrypted message:
<msg:Object>
<msg:Data1 xmlns:msg="http://www.domain.com/folder/subfolder/Schema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">255</msg:Data1>
<msg:Data2>255</msg:Data2>
<msg:Data3>255</msg:Data3>
.
.
.
</msg:Object>
Now you can see that the message is correctly decrypted but it presents more
informations in the tag that comes immediatly after the one I used as my XPath
expression.
How can I avoid this event?!
Or can it be avoided?!