Unverified Commit 14fa87be authored by Éloïs's avatar Éloïs
Browse files

add headV2 api field details

parent a7b7d5c7
......@@ -34,10 +34,11 @@ WS2P is exclusively based on websocket technology.
### Endpoint format
In the peer card : `WS2P uuid host port path`
In the peer card : `API uuid host port path`
Resolved in* : `ws://host:port/path`
*If the port is `443`, the `wss://` protocol will be used.
api := Field indicating api type. The only two types are `WS2P` and `WS2PTOR`.
uuid := Random sequence of 8 hexadecimal characters. (This uuid, coupled with the public key, makes it possible to identify a Duniter node in a unique way.)
host := Domain name or ipv4 or ipv6 (it is not possible to declare both an ipv4 and an ipv6, for this it is necessary to use a domain name.)
port := Mandatory. Must be an integer. (_By convention, port 20900 is used for currency g1-test and port 20901 for currency g1._)
......@@ -243,16 +244,16 @@ Accepted since duniter-ts **v1.6.9**, relayed fully since duniter-ts **v1.6.15**
_Nodes with versions lower than 1.6.15 bounce a degraded version of the head, only `message` and `sig` fields are relayed._
sig : "TPh2A3NS8cHj8yrJk1Yeldx2H6bPEp46cFAGZXKfxJcNgXL2sWrlirhIOlp8pkUFSrwDawWY1zO1jlgUqMvlAg==",
sigV2: "ta1lRrWsjGcYHcLdS75JgEW5B8ByRetFVUVVpakKNJBirhRe8HcYUHEOM7xj/+gUQGGOit6Gm5Q/lsvfsngWAQ==",
step: 0
#### message & messageV2 fields
API = `WS2P`
API := field indicating the network layer type and giving some information about the Network configuration. (See section "API field" for details)
PUBKEY := public key of the issuer node of this head
BLOCKSTAMP = `blockNumber-Hash`
......@@ -263,6 +264,24 @@ POW_PREFIX := nonce prefix for proof of work (manually fixed by the user)
FREE_MEMBER_ROOM := Number of incoming connection requests that can still be accepted from member nodes (FREE_MIROR_ROOM - Number of incoming connections established by non-priority mirror nodes).
FREE_MIROR_ROOM := An integer indicating the number of incoming connections that the node can still receive.
##### API field
general scheme : `WS2P[PrivateConf][PublicConf]`
We have 4 types of WS2P Private:
OCA : clear all
OTM : tor mixed
OTA : tor all
OTS : tor strict
And two types of WS2P Public :
IC clear endpoint
IT tor endpoint
The WS2P Private conf is prefixed with an O and the ws2p public conf with an I, so the classic nodes will be of type `WS2POCAIC`.
If WS2P Public is disabled, the [PublicConf] part is absent : `WS2POCA`
#### sig & sigv2 fields
sig: ed25519 signature of the message field in base64.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment