##// END OF EJS Templates
Moved signatures block to the model block. All the signed content is in the 'content' block now. Removed edit time, previous and next posts links from the XML sync output because they can be computed from the post itself and can be changed locally for foreign posts (which breaks the signature)
Moved signatures block to the model block. All the signed content is in the 'content' block now. Removed edit time, previous and next posts links from the XML sync output because they can be computed from the post itself and can be changed locally for foreign posts (which breaks the signature)

File last commit:

r838:2b96b9e7 decentral
r838:2b96b9e7 decentral
Show More
response_get.xml
45 lines | 1.5 KiB | application/xml | XmlLexer
<?xml version="1.1" encoding="UTF-8" ?>
<response>
<!--
Valid statuses are 'success' and 'error'.
-->
<status>success</status>
<models>
<model name="post">
<!--
Content tag is the data that is signed by signatures and must
not be changed for the post from other node.
-->
<content>
<id key="id1" type="ecdsa" local-id="1" />
<title>13</title>
<text>Thirteen</text>
<thread>id1/12</thread>
<pub-time>12</pub-time>
</content>
<!--
There can be several signatures for one model. At least one
signature must be made with the key used in global ID.
-->
<signatures>
<signature key="id1" type="ecdsa" value="dhefhtreh" />
<signature key="id45" type="ecdsa" value="dsgfgdhefhtreh" />
</signatures>
</model>
<model name="post">
<content>
<id key="id1" type="ecdsa" local-id="id2" />
<title>13</title>
<text>Thirteen</text>
<pub-time>12</pub-time>
<edit-time>13</edit-time>
<tags>
<tag>tag1</tag>
</tags>
</content>
<signatures>
<signature key="id2" type="ecdsa" value="dehdfh" />
</signatures>
</model>
</models>
</response>