All data in JSON format is presented in this RFC with explicit typing.
All data in JSON format is presented in this RFC with explicit typing.
...
@@ -393,6 +406,83 @@ Signed document declaring all the endpoints of a peer.
...
@@ -393,6 +406,83 @@ Signed document declaring all the endpoints of a peer.
The document is represented by an array of bytes containing (peer_card_size + 2) bytes.
The document is represented by an array of bytes containing (peer_card_size + 2) bytes.
to sign the document it is necessary to calculate the hash sha256 of this bytes array then to sign the hash obtained with the issuer's private key.
to sign the document it is necessary to calculate the hash sha256 of this bytes array then to sign the hash obtained with the issuer's private key.
### Peer card Raw format
Approximate description :
VERSION:CURRENCY:NODE_ID:PUBLIC_KEY:BLOCKSTAMP
ENDPOINT 1
...
ENDPOINT n
SIGNATURE
_/!\ This description is approximate, it allows you to quickly understand the format but is not authoritative for developing a code to parse the format exactly. If you want to develop a code using this format, please refer to its PEG grammar._
_/!\ This description is approximate, it allows you to quickly understand the format but is not authoritative for developing a code to parse the format exactly. If you want to develop a code using this format, please refer to its PEG grammar._
All WS2Pv2 documents are necessarily in Binary Format. When document binarization is coded in Duniter-ts, then it will be necessary to define a common binary format for each document. For performance reasons, we will probably opt for the format in which each document is signed.
All WS2Pv2 documents are necessarily in Binary Format. When document binarization is coded in Duniter-ts, then it will be necessary to define a common binary format for each document. For performance reasons, we will probably opt for the format in which each document is signed.