| Package | Description |
|---|---|
| net.i2p.client |
Interfaces and factories for the base I2P SDK used to develop applications that communicate through I2P.
|
| net.i2p.client.impl |
Internal implementation of the I2P client SDK, providing the client
side of the I2CP protocol for applications communicating through I2P.
|
| net.i2p.client.streaming.impl |
Implementation of a TCP-like (reliable, authenticated, in order) set of sockets for communicating over the IP-like (unreliable, unauthenticated, unordered) I2P messages.
|
| net.i2p.crypto |
Core cryptographic primitives and algorithms used throughout I2P.
|
| net.i2p.data.i2np |
This package defines the low-level messages sent between routers,
called Invisible Internet Network Protocol (I2NP).
|
| net.i2p.router.crypto |
Router-specific cryptographic operations and implementations for I2P security.
|
| net.i2p.router.crypto.ratchet |
Implementation of ECIES-X25519-AEAD-Ratchet cryptographic protocol
(I2P proposal 144), providing forward secrecy and enhanced security
for I2P transport communications.
|
| net.i2p.router.message |
Garlic message creation, parsing, and source routing for I2P communications.
|
| net.i2p.router.networkdb.kademlia |
Kademlia DHT implementation and floodfill router functionality for I2P.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent)
End-to-End Crypto is disabled, tags and keys are ignored.
|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
int proto,
int fromPort,
int toPort)
See I2PSessionMuxedImpl for proto/port details.
|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expire)
End-to-End Crypto is disabled, tags and keys are ignored.
|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expire,
int proto,
int fromPort,
int toPort)
See I2PSessionMuxedImpl for proto/port details.
|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expire,
int proto,
int fromPort,
int toPort,
int flags)
See I2PSessionMuxedImpl for proto/port details.
|
boolean |
I2PSession.sendMessage(Destination dest,
byte[] payload,
SessionKey keyUsed,
Set<SessionTag> tagsSent)
End-to-End Crypto is disabled, tags and keys are ignored!
Like sendMessage above, except the key used and the tags sent are exposed to the
application.
|
| Modifier and Type | Method and Description |
|---|---|
void |
I2CPMessageProducer.sendMessage(I2PSessionImpl session,
Destination dest,
long nonce,
byte[] payload,
SessionTag tag,
SessionKey key,
Set<SessionTag> tags,
SessionKey newKey,
long expires)
Package up and send the payload to the router for delivery
|
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
I2PSessionImpl2.sendBestEffort(Destination dest,
byte[] payload,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expires) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
int proto,
int fromport,
int toport) |
boolean |
I2PSessionMuxedImpl.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
int proto,
int fromport,
int toport) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expires)
Unused? see MuxedImpl override
|
boolean |
I2PSessionMuxedImpl.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expires) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expire,
int proto,
int fromport,
int toport) |
boolean |
I2PSessionMuxedImpl.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expires,
int proto,
int fromPort,
int toPort) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expire,
int proto,
int fromport,
int toport,
int flags) |
boolean |
I2PSessionMuxedImpl.sendMessage(Destination dest,
byte[] payload,
int offset,
int size,
SessionKey keyUsed,
Set<SessionTag> tagsSent,
long expires,
int proto,
int fromPort,
int toPort,
int flags) |
boolean |
I2PSessionImpl2.sendMessage(Destination dest,
byte[] payload,
SessionKey keyUsed,
Set<SessionTag> tagsSent) |
void |
I2CPMessageProducer.sendMessage(I2PSessionImpl session,
Destination dest,
long nonce,
byte[] payload,
SessionTag tag,
SessionKey key,
Set<SessionTag> tags,
SessionKey newKey,
long expires)
Package up and send the payload to the router for delivery
|
| Modifier and Type | Method and Description |
|---|---|
Set<SessionTag> |
PacketLocal.getTagsSent()
Deprecated.
should always return null or an empty set
|
| Modifier and Type | Method and Description |
|---|---|
void |
PacketLocal.setTagsSent(Set<SessionTag> tags)
Deprecated.
I2PSession throws out the tags
|
| Modifier and Type | Method and Description |
|---|---|
SessionTag |
SessionKeyManager.consumeNextAvailableTag(PublicKey target,
SessionKey key)
Retrieve the next available session tag for identifying the use of the given
key when communicating with the target.
|
| Modifier and Type | Method and Description |
|---|---|
SessionKey |
SessionKeyManager.consumeTag(SessionTag tag)
Determine if we have received a session key associated with the given session tag,
and if so, discard it (but keep track for frequent dups) and return the decryption
key it was received with (via tagsReceived(...)).
|
| Modifier and Type | Method and Description |
|---|---|
TagSetHandle |
SessionKeyManager.tagsDelivered(PublicKey target,
SessionKey key,
Set<SessionTag> sessionTags)
Take note of the fact that the given sessionTags associated with the key for
encryption to the target have definitely been received at the target (aka call this
method after receiving an ack to a message delivering them)
|
void |
SessionKeyManager.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags)
Accept the given tags and associate them with the given key for decryption,
with the default expiration.
|
void |
SessionKeyManager.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags,
long expire)
Accept the given tags and associate them with the given key for decryption,
with specified expiration.
|
| Modifier and Type | Method and Description |
|---|---|
SessionTag |
DatabaseLookupMessage.getReplyTag()
The included session tag or null if unset
|
| Modifier and Type | Method and Description |
|---|---|
void |
DatabaseLookupMessage.setReplySession(SessionKey encryptKey,
SessionTag encryptTag)
Only worthwhile if sending reply via tunnel
|
| Modifier and Type | Method and Description |
|---|---|
SessionTag |
TransientSessionKeyManager.consumeNextAvailableTag(PublicKey target,
SessionKey key)
Retrieve the next available session tag for identifying the use of the given
key when communicating with the target.
|
| Modifier and Type | Method and Description |
|---|---|
SessionKey |
TransientSessionKeyManager.consumeTag(SessionTag tag)
Determine if we have received a session key associated with the given session tag,
and if so, discard it (but keep track for frequent dups) and return the decryption
key it was received with (via tagsReceived(...)).
|
byte[] |
ElGamalAESEngine.encrypt(byte[] data,
PublicKey target,
SessionKey key,
Set<SessionTag> tagsForDelivery,
SessionTag currentTag,
long paddedSize)
Encrypt the data to the target using the given key and deliver the specified tags
No new session key
This is the one called from GarlicMessageBuilder and is the primary entry point.
|
byte[] |
ElGamalAESEngine.encrypt(byte[] data,
PublicKey target,
SessionKey key,
Set<SessionTag> tagsForDelivery,
SessionTag currentTag,
SessionKey newKey,
long paddedSize)
Encrypt the unencrypted data to the target.
|
| Modifier and Type | Method and Description |
|---|---|
(package private) byte[] |
ElGamalAESEngine.decryptAESBlock(byte[] encrypted,
int offset,
int encryptedLen,
SessionKey key,
byte[] iv,
byte[] sentTag,
Set<SessionTag> foundTags,
SessionKey foundKey)
private byte[] decryptAESBlock(byte encrypted[], SessionKey key, byte iv[],
byte sentTag[], Set foundTags, SessionKey foundKey) throws DataFormatException {
return decryptAESBlock(encrypted, 0, encrypted.length, key, iv, sentTag, foundTags, foundKey);
}
|
byte[] |
ElGamalAESEngine.encrypt(byte[] data,
PublicKey target,
SessionKey key,
Set<SessionTag> tagsForDelivery,
long paddedSize)
Deprecated.
unused
|
byte[] |
ElGamalAESEngine.encrypt(byte[] data,
PublicKey target,
SessionKey key,
Set<SessionTag> tagsForDelivery,
SessionTag currentTag,
long paddedSize)
Encrypt the data to the target using the given key and deliver the specified tags
No new session key
This is the one called from GarlicMessageBuilder and is the primary entry point.
|
byte[] |
ElGamalAESEngine.encrypt(byte[] data,
PublicKey target,
SessionKey key,
Set<SessionTag> tagsForDelivery,
SessionTag currentTag,
SessionKey newKey,
long paddedSize)
Encrypt the unencrypted data to the target.
|
(package private) byte[] |
ElGamalAESEngine.encryptAESBlock(byte[] data,
SessionKey key,
byte[] iv,
Set<SessionTag> tagsForDelivery,
SessionKey newKey,
long paddedSize)
For both scenarios, this method encrypts the AES area using the given key, iv
and making sure the resulting data is at least as long as the paddedSize and
also mod 16 bytes.
|
TagSetHandle |
TransientSessionKeyManager.tagsDelivered(PublicKey target,
SessionKey key,
Set<SessionTag> sessionTags)
Take note of the fact that the given sessionTags associated with the key for
encryption to the target have been sent.
|
void |
TransientSessionKeyManager.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags)
Accept the given tags and associate them with the given key for decryption
|
void |
TransientSessionKeyManager.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags,
long expire)
Accept the given tags and associate them with the given key for decryption
|
| Modifier and Type | Method and Description |
|---|---|
SessionTag |
RatchetSKM.consumeNextAvailableTag(PublicKey target,
SessionKey key) |
SessionTag |
MuxedPQSKM.consumeNextAvailableTag(PublicKey target,
SessionKey key)
ElG only
|
SessionTag |
MuxedSKM.consumeNextAvailableTag(PublicKey target,
SessionKey key)
ElG only
|
| Modifier and Type | Method and Description |
|---|---|
SessionKey |
RatchetSKM.consumeTag(SessionTag tag) |
SessionKey |
MuxedPQSKM.consumeTag(SessionTag tag) |
SessionKey |
MuxedSKM.consumeTag(SessionTag tag) |
| Modifier and Type | Method and Description |
|---|---|
TagSetHandle |
RatchetSKM.tagsDelivered(PublicKey target,
SessionKey key,
Set<SessionTag> sessionTags) |
TagSetHandle |
MuxedPQSKM.tagsDelivered(PublicKey target,
SessionKey key,
Set<SessionTag> sessionTags)
ElG only
|
TagSetHandle |
MuxedSKM.tagsDelivered(PublicKey target,
SessionKey key,
Set<SessionTag> sessionTags)
ElG only
|
void |
RatchetSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags) |
void |
MuxedPQSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags)
ElG only
|
void |
MuxedSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags)
ElG only
|
void |
RatchetSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags,
long expire) |
void |
MuxedPQSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags,
long expire)
ElG only
|
void |
MuxedSKM.tagsReceived(SessionKey key,
Set<SessionTag> sessionTags,
long expire)
ElG only
|
| Modifier and Type | Method and Description |
|---|---|
static GarlicMessage |
GarlicMessageBuilder.buildMessage(RouterContext ctx,
GarlicConfig config,
Set<SessionTag> wrappedTags,
PublicKey target,
SessionKey encryptKey,
SessionTag encryptTag)
ELGAMAL_2048 only.
|
| Modifier and Type | Method and Description |
|---|---|
static GarlicMessage |
GarlicMessageBuilder.buildMessage(RouterContext ctx,
GarlicConfig config,
SessionKey wrappedKey,
Set<SessionTag> wrappedTags,
int numTagsToDeliver,
int lowTagsThreshold,
SessionKeyManager skm)
ELGAMAL_2048 only.
|
static GarlicMessage |
GarlicMessageBuilder.buildMessage(RouterContext ctx,
GarlicConfig config,
SessionKey wrappedKey,
Set<SessionTag> wrappedTags,
int numTagsToDeliver,
SessionKeyManager skm)
ELGAMAL_2048 only
Called by OCMJH
|
static GarlicMessage |
GarlicMessageBuilder.buildMessage(RouterContext ctx,
GarlicConfig config,
SessionKey wrappedKey,
Set<SessionTag> wrappedTags,
SessionKeyManager skm)
Now unused, since we have to generate a reply token first in OCMOSJ but we don't know if tags are required yet.
|
static GarlicMessage |
GarlicMessageBuilder.buildMessage(RouterContext ctx,
GarlicConfig config,
Set<SessionTag> wrappedTags,
PublicKey target,
SessionKey encryptKey,
SessionTag encryptTag)
ELGAMAL_2048 only.
|
(package private) static GarlicMessage |
OutboundClientMessageJobHelper.createGarlicMessage(RouterContext ctx,
long replyToken,
long expiration,
PublicKey recipientPK,
PayloadGarlicConfig dataClove,
Hash from,
Destination dest,
TunnelInfo replyTunnel,
int tagsToSendOverride,
int lowTagsOverride,
SessionKey wrappedKey,
Set<SessionTag> wrappedTags,
boolean requireAck,
LeaseSet bundledReplyLeaseSet,
ReplyCallback callback)
Allow the app to specify the data clove directly, which enables OutboundClientMessage to resend the
same payload (including expiration and unique id) in different garlics (down different tunnels)
This is called from OCMOSJ
|
| Modifier and Type | Field and Description |
|---|---|
SessionTag |
MessageWrapper.OneTimeSession.tag
non-null for ElG
|
| Modifier and Type | Method and Description |
|---|---|
static GarlicMessage |
MessageWrapper.wrap(RouterContext ctx,
I2NPMessage m,
SessionKey encryptKey,
SessionTag encryptTag)
Garlic wrap a message from nobody, destined for an unknown router,
to hide the contents from the IBGW.
|
| Constructor and Description |
|---|
OneTimeSession(SessionKey key,
SessionTag tag) |