forked from I2P_Developers/i2p.i2p
I2CP: Fix encrypted leaseset for ECIES and dual-key encryption, and for offline keys
This commit is contained in:
@@ -99,14 +99,8 @@ class RequestLeaseSetMessageHandler extends HandlerImpl {
|
||||
protected boolean requiresLS2(I2PSessionImpl session) {
|
||||
if (!session.supportsLS2())
|
||||
return false;
|
||||
if (session.isOffline())
|
||||
return true;
|
||||
String s = session.getOptions().getProperty(PROP_LS_ENCTYPE);
|
||||
if (s != null) {
|
||||
if (!s.equals("0") && !s.equals("ELGAMAL_2048"))
|
||||
return true;
|
||||
}
|
||||
s = session.getOptions().getProperty(PROP_LS_TYPE);
|
||||
// we do this check first because we must set _ls2Type regardless
|
||||
String s = session.getOptions().getProperty(PROP_LS_TYPE);
|
||||
if (s != null) {
|
||||
try {
|
||||
int type = Integer.parseInt(s);
|
||||
@@ -119,6 +113,13 @@ class RequestLeaseSetMessageHandler extends HandlerImpl {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if (session.isOffline())
|
||||
return true;
|
||||
s = session.getOptions().getProperty(PROP_LS_ENCTYPE);
|
||||
if (s != null) {
|
||||
if (!s.equals("0") && !s.equals("ELGAMAL_2048"))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
2020-12-23 zzz
|
||||
* Crypto: Increase ratchet tag window
|
||||
* I2CP: Fix encrypted leaseset for ECIES and offline keys
|
||||
|
||||
2020-12-22 zzz
|
||||
* Console:
|
||||
|
||||
@@ -18,7 +18,7 @@ public class RouterVersion {
|
||||
/** deprecated */
|
||||
public final static String ID = "Monotone";
|
||||
public final static String VERSION = CoreVersion.VERSION;
|
||||
public final static long BUILD = 8;
|
||||
public final static long BUILD = 9;
|
||||
|
||||
/** for example "-test" */
|
||||
public final static String EXTRA = "";
|
||||
|
||||
Reference in New Issue
Block a user