mirror of
https://github.com/oxen-io/session-android.git
synced 2024-12-22 16:07:30 +00:00
We need to force plaintext on key exchange messages.
This commit is contained in:
parent
c5ed820590
commit
93c0fffc31
@ -58,7 +58,7 @@ public class KeyExchangeInitiator {
|
|||||||
LinkedList<Recipient> list = new LinkedList<Recipient>();
|
LinkedList<Recipient> list = new LinkedList<Recipient>();
|
||||||
list.add(recipient);
|
list.add(recipient);
|
||||||
|
|
||||||
MessageSender.send(context, masterSecret, new Recipients(list), -1, message.serialize(), false);
|
MessageSender.send(context, masterSecret, new Recipients(list), -1, message.serialize(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean hasInitiatedSession(Context context, MasterSecret masterSecret, Recipient recipient) {
|
private static boolean hasInitiatedSession(Context context, MasterSecret masterSecret, Recipient recipient) {
|
||||||
|
@ -16,8 +16,9 @@
|
|||||||
*/
|
*/
|
||||||
package org.thoughtcrime.securesms.crypto;
|
package org.thoughtcrime.securesms.crypto;
|
||||||
|
|
||||||
import java.util.LinkedList;
|
import android.content.Context;
|
||||||
import java.util.List;
|
import android.content.Intent;
|
||||||
|
import android.util.Log;
|
||||||
|
|
||||||
import org.bouncycastle.util.Arrays;
|
import org.bouncycastle.util.Arrays;
|
||||||
import org.thoughtcrime.securesms.database.LocalKeyRecord;
|
import org.thoughtcrime.securesms.database.LocalKeyRecord;
|
||||||
@ -30,9 +31,8 @@ import org.thoughtcrime.securesms.service.KeyCachingService;
|
|||||||
import org.thoughtcrime.securesms.sms.MessageSender;
|
import org.thoughtcrime.securesms.sms.MessageSender;
|
||||||
import org.thoughtcrime.securesms.util.Conversions;
|
import org.thoughtcrime.securesms.util.Conversions;
|
||||||
|
|
||||||
import android.content.Context;
|
import java.util.LinkedList;
|
||||||
import android.content.Intent;
|
import java.util.List;
|
||||||
import android.util.Log;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This class processes key exchange interactions.
|
* This class processes key exchange interactions.
|
||||||
@ -110,7 +110,7 @@ public class KeyExchangeProcessor {
|
|||||||
KeyExchangeMessage ourMessage = new KeyExchangeMessage(context, masterSecret, Math.min(Message.SUPPORTED_VERSION, message.getMaxVersion()), localKeyRecord, initiateKeyId);
|
KeyExchangeMessage ourMessage = new KeyExchangeMessage(context, masterSecret, Math.min(Message.SUPPORTED_VERSION, message.getMaxVersion()), localKeyRecord, initiateKeyId);
|
||||||
Log.w("KeyExchangeProcessor", "Responding with key exchange message fingerprint: " + ourMessage.getPublicKey().getFingerprint());
|
Log.w("KeyExchangeProcessor", "Responding with key exchange message fingerprint: " + ourMessage.getPublicKey().getFingerprint());
|
||||||
Log.w("KeyExchangeProcessor", "Which has a local key record fingerprint: " + localKeyRecord.getCurrentKeyPair().getPublicKey().getFingerprint());
|
Log.w("KeyExchangeProcessor", "Which has a local key record fingerprint: " + localKeyRecord.getCurrentKeyPair().getPublicKey().getFingerprint());
|
||||||
MessageSender.send(context, masterSecret, new Recipients(recipients), threadId, ourMessage.serialize(), false);
|
MessageSender.send(context, masterSecret, new Recipients(recipients), threadId, ourMessage.serialize(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
remoteKeyRecord.setCurrentRemoteKey(message.getPublicKey());
|
remoteKeyRecord.setCurrentRemoteKey(message.getPublicKey());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user