Must contain few mandatory parameters, some optional parameters might be also presented.
Example of client tunnel:
[irc-out]
type = client
address = 127.0.0.1
port = 6668
destination = irc.echelon.i2p
keys = irc.dat
If *keys* is empty, transient keys will be created on every restart. If keys file is not found, new keys will be created and stored into specified file.
Client tunnels might share same local destination, if keys file contains same identity.
Optional parameters:
* address -- local interface tunnel binds to, '127.0.0.1' for connections from local host only, '0.0.0.0' for connections from everywhere. '127.0.0.1' by default.
* signaturetype -- signature type for new keys. 0 (DSA), 1 (ECDSA-P256), 7 (EDDSA). 1 by default
* destinationport -- connect to particular port at destination. 0 by default
So, with example above, if you telnet to 127.0.0.1:6668 on localhost, i2pd will connect to irc.echelon.i2p:6668
Server/generic tunnels
----------------------
Mnemonic: we serving some service to others in network
Example of server tunnel:
[smtp-in]
type = server
host = 127.0.0.1
port = 25
keys = smtp-in.dat
*keys* must be presented, LeaseSet of address from keys file will be published. Server tunnel must use its own local destination.
Optional parameters:
* inport -- what port at local destination server tunnel listens to. Same as *port* by default.
* accesslist -- list of comma-separated of b32 address (without .b32.i2p) allowed to connect. Everybody is allowed by default.
* gzip -- turns internal compression off if set to false. true by default.
* signaturetype -- means signature type for new keys. 0 - DSA, 1- ECDSA-P256, 7 -EDDSA. 1 by default.
* enableuniquelocal -- if true, connection to local address will look like 127.x.x.x where x.x.x is first 3 bytes of incoming connection peer's ident hash. true by default.
Server/http tunnels
-------------------
*http* tunnel works same way as server tunnel, but replace 'Host:' field in HTTP header to address provided in configuration.
Also resolves it if necessary.
Example of http tunnel:
[http-in]
type = http
host = ourwebsite.com
port = 80
keys = our-website.dat
Optional parameters:
* hostoverride -- value to send in 'Host:' header, default: the same as *host* parameter