mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 19:29:06 +01:00
Merge branch '117-qr-contacts' into 'master'
BQP with QR codes This MR implements BQP for key agreement over short-range transports. It also implements the Android UI for using BQP with QR codes. Closes #117. See merge request !84
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
/** An event that is broadcast when a BQP protocol aborts. */
|
||||
public class KeyAgreementAbortedEvent extends Event {
|
||||
|
||||
private final boolean remoteAborted;
|
||||
|
||||
public KeyAgreementAbortedEvent(boolean remoteAborted) {
|
||||
this.remoteAborted = remoteAborted;
|
||||
}
|
||||
|
||||
public boolean didRemoteAbort() {
|
||||
return remoteAborted;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
/** An event that is broadcast when a BQP connection cannot be created. */
|
||||
public class KeyAgreementFailedEvent extends Event {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
import org.briarproject.api.keyagreement.KeyAgreementResult;
|
||||
|
||||
/** An event that is broadcast when a BQP protocol completes. */
|
||||
public class KeyAgreementFinishedEvent extends Event {
|
||||
|
||||
private final KeyAgreementResult result;
|
||||
|
||||
public KeyAgreementFinishedEvent(KeyAgreementResult result) {
|
||||
this.result = result;
|
||||
}
|
||||
|
||||
public KeyAgreementResult getResult() {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
import org.briarproject.api.keyagreement.Payload;
|
||||
|
||||
/** An event that is broadcast when a BQP task is listening. */
|
||||
public class KeyAgreementListeningEvent extends Event {
|
||||
|
||||
private final Payload localPayload;
|
||||
|
||||
public KeyAgreementListeningEvent(Payload localPayload) {
|
||||
this.localPayload = localPayload;
|
||||
}
|
||||
|
||||
public Payload getLocalPayload() {
|
||||
return localPayload;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
/** An event that is broadcast when a BQP protocol completes. */
|
||||
public class KeyAgreementStartedEvent extends Event {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
package org.briarproject.api.event;
|
||||
|
||||
/**
|
||||
* An event that is broadcast when a BQP protocol is waiting on the remote
|
||||
* peer to start.
|
||||
*/
|
||||
public class KeyAgreementWaitingEvent extends Event {
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user