[xmlsec] How to get namespace prefix on the signature XML-elements

P.Q.Hung hungpq at volny.cz
Tue Dec 16 02:48:22 PST 2003


Hi,
please see my comment below.

>You get <Signature xmlns="http://...."/> thus the element *has* correct
>namespace. The namespace prefix does not matter at all and using
><XXX> instead of <dsig:XXX> saves 5 bytes per element. Not much but
>still good :)
>Currently xmlsec has no way of changing the prefix and I just don't know
>why one can need it,

XML is designed to be human readable, machine processable, not to save data.
There are some element inside Signature that may be extensible and may be
under
other namespace. If Signature is only a part of of some framework, it
usually has
it own prefix. Of course, there is a way to work around and use default
namespace
instead of the namespace determined by the prefix, but it looks strange in
compare with
other application that does the same thing. For example, WS-Security usually
use "ds"
prefix for Signature and inside KeyInfo element may be some element under
different namespace.

IMHO, adding prefix to xmlSecLib signature is not so big problem. I guess
max. two hours work??? :-)
--
P.Q.Hung




More information about the xmlsec mailing list