Xoxa-c  0.3.1
Normalizer/Parser for XML
 All Data Structures Files Functions Variables Typedefs Enumerations Pages
Xoxa-C
Author
Norman Gray http://nxg.me.uk

The Xoxa library implements a normalization procedure for XML files, which generates a well-defined normalized form which is simple to generate and is largely reversible, and which can be signed by GPG or other cryptographic mechanisms in a natural way.

This documentation is for version 0.3.1, "2015-05-17".

Note: This is still beta code. Some functionality is implemented only in the C version of the code and not the Java version, or vice versa. The interface may yet change.


The procedure turns the XML:

<doc>
<p class='foo'>Hello</p>
  <p> there
chum
</p>
</doc>

into the normalised form:

(doc
Aclass foo
(p
-Hello
)p
(p
- there chum
)p
)doc

This normalised form can then be signed, and the signature reinserted into the original XML, or else included as the parsed XML is passed downstream.

The following document has the same normalised form as the earlier one, but includes a PGP signature block which can be used to verify it:

<doc><p class="foo">Hello</p><p> there
        chum </p>
<?signature algorithm='pgp' armor='-----BEGIN PGP SIGNATURE-----
....
-----END PGP SIGNATURE-----'?></doc>

The signature PI

The XML may include a processing instruction (PI) of the form <?signature ... ?>, which indicates a signature for the normalised form of the output, not including the signature PI. This PI has a ‘data’ payload consisting of a sequence of key-value pairs, where each value is enclosed in double quotes. The only keys defined so far are:

Other details

The procedure is defined in detail in [paper reference to come]. For more information, see the project web page.