From 6e9003be28b6498d3ee19e95b5dc12f0be85c6ec Mon Sep 17 00:00:00 2001 From: zzz Date: Mon, 25 Jun 2012 19:15:48 +0000 Subject: [PATCH] - Proposed new I2CP options for 0.9.2 - I2NP Garlic clove/message clarifications --- www.i2p2/pages/i2cp.html | 28 ++++++++++++++++++++++++++++ www.i2p2/pages/i2np_spec.html | 23 +++++++++++++++++++++-- 2 files changed, 49 insertions(+), 2 deletions(-) diff --git a/www.i2p2/pages/i2cp.html b/www.i2p2/pages/i2cp.html index 32694efc..c12d5133 100644 --- a/www.i2p2/pages/i2cp.html +++ b/www.i2p2/pages/i2cp.html @@ -79,6 +79,7 @@ The following options are traditionally passed to the router via a SessionConfig contained in a CreateSession Message or a ReconfigureSession Message.

+
Router-side Options
Option Recommended Arguments Allowable RangeDefaultDescription
inbound.quantity number from 1 to 3 1 to 162Number of tunnels in. Limit was increased from 6 to 16 in release 0.9; however, numbers higher than 6 are not @@ -116,6 +117,32 @@ a SessionConfig contained in a < If the client is running in the same JVM as a router, this option is not required.
i2cp.passwordstring  For authorization, if required by the router (since 0.8.2). If the client is running in the same JVM as a router, this option is not required. +
crypto.tagsToSend 1-12840Number of ElGamal/AES Session Tags to send at a time (since 0.9.2). + For clients with relatively low bandwidth per-client-pair (IRC, some UDP apps), this may be set lower. +
crypto.lowTagThreshold 1-12830Minimum number of ElGamal/AES Session Tags before we send more (since 0.9.2). + Recommended: approximately tagsToSend * 2/3 +
shouldBundleReplyInfotrue, false trueSet to false to disable ever bundling a reply LeaseSet (since 0.9.2). + For clients that do not publish their LeaseSet, this option must be true + for any reply to be possible. "true" is also recommended for multihomed servers + with long connection times. + +

Setting to "false" may save significant outbound bandwidth, especially if + the client is configured with a large number of inbound tunnels (Leases). + If replies are still required, this may shift the bandwidth burden to + the far-end client and the floodfill. + There are several cases where "false" is may be appropriate: +

  • + Unidirectional communication, no reply required +
  • + LeaseSet is published and higher reply latency is acceptable +
  • + LeaseSet is published, client is a "server", all connections are inbound + so the connecting far-end destination obviously has the leaseset already. + Connections are either short, or it is acceptable for latency on a long-lived + connection to temporarily increase while the other end re-fetches the LeaseSet + after expiration. + HTTP servers may fit these requirements. +
inbound.*   Any other options prefixed with "inbound." are stored in the "unknown options" properties of the inbound tunnel pool's settings.
outbound.*   Any other options prefixed with "outbound." are stored @@ -134,6 +161,7 @@ and will be interpreted if passed to the I2PSession via the I2PClient.createSess The streaming lib should also pass these options through to I2CP.

+
Client-side Options
Option As Of ReleaseRecommended Arguments Allowable RangeDefaultDescription
i2cp.tcp.host    127.0.0.1Router hostname. If the client is running in the same JVM as a router, this option is ignored, and the client connects to that router internally. diff --git a/www.i2p2/pages/i2np_spec.html b/www.i2p2/pages/i2np_spec.html index c3e04f85..9a1a87fb 100644 --- a/www.i2p2/pages/i2np_spec.html +++ b/www.i2p2/pages/i2np_spec.html @@ -2,7 +2,7 @@ {% block title %}I2NP Specification{% endblock %} {% block content %} -Updated January 2012, current as of router version 0.8.12 +Updated June 2012, current as of router version 0.9

I2P Network Protocol (I2NP) Specification

@@ -366,10 +366,17 @@ Certificate :: Always NULL in the current implementation (3 bytes total, all zer See also the garlic routing specification.

  • See also Delivery Instructions definition +
  • + Maximum length is a function of the total length of all the cloves and the + maximum length of the GarlicMessage.
  • In the future, the certificate could possibly be used for a HashCash to "pay" for the routing.
  • - The message is always a DataMessage? + The message can be any I2NP message (including a GarlicMessage, although that is not used in practice). + The messages used in practice are DataMessage, DeliveryStatusMessage, and DatabaseStoreMessage. +
  • + The Clove ID is generally set to a random number on transmit and is checked for + duplicates on receive (same message ID space as top-level Message IDs) @@ -785,12 +792,24 @@ Expiration :: Date (8 bytes)
    • When unencrypted, data contains one or more Garlic Cloves. +
    • + The AES encrypted block is padded to a minimum of 128 bytes; with the 32-byte Session Tag + the minimum size of the encrypted message is 160 bytes; with the 4 length bytes + the minimum size of the Garlic Message is 164 bytes.
    • Actual max length is less than 64 KB; see the I2NP Overview.
    • See also the ElGamal/AES specification.
    • See also the garlic routing specification. +
    • + The 128 byte minimum size of the AES encrypted block is not currently configurable, + however the minimum size of a DataMessage in a GarlicClove in a GarlicMessage, with + overhead, is 128 bytes anyway. A configurable option to increase the minimum size + may be added in the future. +
    • + The message ID is generally set to a random number on transmit and + appears to be ignored on receive.
    • In the future, the certificate could possibly be used for a HashCash to "pay" for the routing.