Forwarded message 1
The Y4 test case mentioned in
http://www.w3.org/Signature/2002/02/01-exc-c14n-interop.html
has some some cases e.g. see c14n-6.txt which only signs namespace
elements without the enclosing element using a tricky XPath.
Here is the input XML
<foo:Root xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xml:lang="en-ie">
<bar:Something>
<foo:Nothing>
<foo:Something>
<bar:Something>
<foo:Something>
<foo:Nothing>
<foo:Something>
<baz:Something />
</foo:Something>
</foo:Nothing>
</foo:Something>
</bar:Something>
</foo:Something>
</foo:Nothing>
</bar:Something>
</foo>
Here is the XPath
ancestor-or-self::bar:Something and
(count(parent::node()/namespace::*) =
count(parent::node()/namespace::* | self::node()))
Output of canonicalization is
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
xmlns="http://example.org/" xmlns:bar="http://example.org/bar"
xmlns:baz="http://example.org/baz" xmlns:foo="http://example.org/foo"
This should close my ACTION-381
Pratik