I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 647eca97 authored by zzz's avatar zzz
Browse files

More proposal 147 updates

parent ecb69fbc
No related branches found
No related tags found
No related merge requests found
{% extends "global/layout.html" %}
{% block title %}{% trans %}The Network Database{% endtrans %}{% endblock %}
{% block lastupdated %}{% trans %}January 2019{% endtrans %}{% endblock %}
{% block accuratefor %}0.9.38{% endblock %}
{% block lastupdated %}{% trans %}August 2019{% endtrans %}{% endblock %}
{% block accuratefor %}0.9.42{% endblock %}
{% block content %}
<h2>{% trans %}Overview{% endtrans %}</h2>
......@@ -88,6 +88,17 @@ Above the minimum threshold, the advertised bandwidth is not used or trusted any
in the router, except for display in the user interface and for debugging and network analysis.
{%- endtrans %}</p>
<p>Valid NetID numbers:</p>
<table><tr><th>Usage<th>NetID Number
<tr><td>Reserved<td>0
<tr><td>Reserved<td>1
<tr><td>Current Network (default)<td>2
<tr><td>Reserved Future Networks<td>3 - 15
<tr><td>Forks and Test Networks<td>16 - 254
<tr><td>Reserved<td>255
</table>
<h3>{% trans %}Additional Options{% endtrans %}</h3>
<p>{% trans stats=i2pconv('stats.i2p') -%}
......
......@@ -88,7 +88,7 @@ Add the following specification for valid network id values:
================================== ==============
Payload Block Type NetID Number
Usage NetID Number
================================== ==============
Reserved 0
Reserved 1
......@@ -139,9 +139,9 @@ New:
HMAC-MD5(encryptedPayload + IV + (payloadLength ^ protocolVersion ^ ((netid - 2) << 8)), macKey)
'+' means append, '^' means exclusive-or, '<<' means left shift.
payloadLength is a 2 byte unsigned integer
protocolVersion is one byte 0x00
netid is a 1 byte unsigned integer
payloadLength is a two byte unsigned integer, big endian
protocolVersion is two bytes 0x0000, big endian
netid is a two byte unsigned integer, big endian, legal values are 2-254
{% endhighlight %}
......
......@@ -43,7 +43,7 @@ where '+' means append and '^' means exclusive-or.
The IV is generated randomly for each packet. The encryptedPayload is the
encrypted version of the message starting with the flag byte
(encrypt-then-MAC). The payloadLength used in the MAC is a 2 byte unsigned
integer. Note that protocolVersion is 0, so the exclusive-or is a no-op. The
integer, big endian. Note that protocolVersion is 0, so the exclusive-or is a no-op. The
macKey is either the introduction key or is constructed from the exchanged DH
key (see details below), as specified for each message below.
......@@ -54,11 +54,12 @@ The payload itself (that is, the message starting with the flag byte) is
AES256/CBC encrypted with the IV and the sessionKey, with replay prevention
addressed within its body, explained below.
The protocolVersion is a 2 byte unsigned integer and is currently set to 0.
The protocolVersion is a 2 byte unsigned integer, big endian, and is currently set to 0.
Peers using a different protocol version will not be able to communicate with
this peer, though earlier versions not using this flag are.
The exclusive OR of ((netid - 2) << 8) is used to quickly identify cross-network connections.
The netid is a 2 byte unsigned integer, big endian, and is currently set to 2.
As of 0.9.42. See proposal 147 for more information.
As the current network ID is 2, this is a no-op for the current network and is backward compatible.
Any connections from test networks should have a different ID and will fail the HMAC.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment