mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-14 11:49:04 +01:00
Renamed "encrypted IVs" as "tags" (actual crypto changes to follow).
This commit is contained in:
@@ -11,7 +11,7 @@ public interface CryptoComponent {
|
||||
|
||||
ErasableKey deriveFrameKey(byte[] secret, boolean initiator);
|
||||
|
||||
ErasableKey deriveIvKey(byte[] secret, boolean initiator);
|
||||
ErasableKey deriveTagKey(byte[] secret, boolean initiator);
|
||||
|
||||
ErasableKey deriveMacKey(byte[] secret, boolean initiator);
|
||||
|
||||
@@ -23,8 +23,6 @@ public interface CryptoComponent {
|
||||
|
||||
Cipher getFrameCipher();
|
||||
|
||||
Cipher getIvCipher();
|
||||
|
||||
KeyParser getKeyParser();
|
||||
|
||||
Mac getMac();
|
||||
@@ -34,4 +32,6 @@ public interface CryptoComponent {
|
||||
SecureRandom getSecureRandom();
|
||||
|
||||
Signature getSignature();
|
||||
|
||||
Cipher getTagCipher();
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import net.sf.briar.api.protocol.TransportIndex;
|
||||
public interface BatchConnectionFactory {
|
||||
|
||||
void createIncomingConnection(ConnectionContext ctx,
|
||||
BatchTransportReader r, byte[] encryptedIv);
|
||||
BatchTransportReader r, byte[] tag);
|
||||
|
||||
void createOutgoingConnection(ContactId c, TransportIndex i,
|
||||
BatchTransportWriter w);
|
||||
|
||||
@@ -9,7 +9,7 @@ public interface ConnectionReaderFactory {
|
||||
* initiator's side of a stream-mode connection.
|
||||
*/
|
||||
ConnectionReader createConnectionReader(InputStream in,
|
||||
ConnectionContext ctx, byte[] encryptedIv);
|
||||
ConnectionContext ctx, byte[] tag);
|
||||
|
||||
/**
|
||||
* Creates a connection reader for the responder's side of a stream-mode
|
||||
|
||||
@@ -13,8 +13,7 @@ public interface ConnectionRecogniser {
|
||||
* Asynchronously calls one of the callback's connectionAccepted(),
|
||||
* connectionRejected() or handleException() methods.
|
||||
*/
|
||||
void acceptConnection(TransportId t, byte[] encryptedIv,
|
||||
Callback c);
|
||||
void acceptConnection(TransportId t, byte[] tag, Callback c);
|
||||
|
||||
interface Callback {
|
||||
|
||||
|
||||
@@ -16,5 +16,5 @@ public interface ConnectionWriterFactory {
|
||||
* connection.
|
||||
*/
|
||||
ConnectionWriter createConnectionWriter(OutputStream out, long capacity,
|
||||
ConnectionContext ctx, byte[] encryptedIv);
|
||||
ConnectionContext ctx, byte[] tag);
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ import net.sf.briar.api.protocol.TransportIndex;
|
||||
public interface StreamConnectionFactory {
|
||||
|
||||
void createIncomingConnection(ConnectionContext ctx,
|
||||
StreamTransportConnection s, byte[] encryptedIv);
|
||||
StreamTransportConnection s, byte[] tag);
|
||||
|
||||
void createOutgoingConnection(ContactId c, TransportIndex i,
|
||||
StreamTransportConnection s);
|
||||
|
||||
@@ -8,10 +8,10 @@ public interface TransportConstants {
|
||||
static final int MAX_FRAME_LENGTH = 65536; // 2^16, 64 KiB
|
||||
|
||||
/**
|
||||
* The length in bytes of the encrypted IV that uniquely identifies a
|
||||
* The length in bytes of the pseudo-random tag that uniquely identifies a
|
||||
* connection.
|
||||
*/
|
||||
static final int IV_LENGTH = 16;
|
||||
static final int TAG_LENGTH = 16;
|
||||
|
||||
/**
|
||||
* The minimum connection length in bytes that all transport plugins must
|
||||
|
||||
Reference in New Issue
Block a user