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

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

I2CP: Prevent sending message to a local meta destination

parent ce6551da
No related branches found
No related tags found
No related merge requests found
...@@ -445,6 +445,15 @@ class ClientManager { ...@@ -445,6 +445,15 @@ class ClientManager {
Job j = new DistributeLocal(toDest, runner, sender, fromDest, payload, msgId, messageNonce); Job j = new DistributeLocal(toDest, runner, sender, fromDest, payload, msgId, messageNonce);
//_ctx.jobQueue().addJob(j); //_ctx.jobQueue().addJob(j);
j.runJob(); j.runJob();
} else if (!_metaDests.isEmpty() && _metaDests.contains(toDest)) {
// meta dests don't have runners but are local, and you can't send to them
ClientConnectionRunner sender = getRunner(fromDest);
if (sender == null) {
// sender went away
return;
}
int rc = MessageStatusMessage.STATUS_SEND_FAILURE_BAD_LEASESET;
sender.updateMessageDeliveryStatus(fromDest, msgId, messageNonce, rc);
} else { } else {
// remote. w00t // remote. w00t
if (_log.shouldLog(Log.DEBUG)) if (_log.shouldLog(Log.DEBUG))
...@@ -764,7 +773,7 @@ class ClientManager { ...@@ -764,7 +773,7 @@ class ClientManager {
if (_log.shouldLog(Log.WARN)) if (_log.shouldLog(Log.WARN))
_log.warn("Message received but we don't have a connection to " _log.warn("Message received but we don't have a connection to "
+ dest + "/" + _msg.getDestinationHash() + dest + "/" + _msg.getDestinationHash()
+ " currently. DROPPED"); + " currently. DROPPED", new Exception());
} }
} }
} }
......
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