public class ZrtpUserCallback extends Object
| Constructor and Description |
|---|
ZrtpUserCallback() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkSASSignature(byte[] sasHash)
ZRTP core calls this method to request a SAS signature check.
|
void |
confirmGoClear()
Inform the user that ZRTP received "go clear" message from its peer.
|
void |
secureOff()
Inform user interface that security is not active any more.
|
void |
secureOn(String cipher)
Inform user interface that security is active now.
|
void |
showMessage(ZrtpCodes.MessageSeverity sev,
EnumSet<?> subCode)
Show some information to user.
|
void |
showSAS(String sas,
boolean verified)
Show the Short Authentication String (SAS) on user interface.
|
void |
signSAS(byte[] sasHash)
ZRTP core calls this method to request a SAS signature.
|
void |
zrtpAskEnrollment(ZrtpCodes.InfoEnrollment info)
ZRTP core calls this method to inform about a PBX enrollment request.
|
void |
zrtpInformEnrollment(ZrtpCodes.InfoEnrollment info)
ZRTP core calls this method to inform about PBX enrollment result.
|
void |
zrtpNegotiationFailed(ZrtpCodes.MessageSeverity severity,
EnumSet<?> subCode)
ZRTP core calls this if the negotiation failed.
|
void |
zrtpNotSuppOther()
ZRTP core calls this method if the other side does not support ZRTP.
|
public void secureOn(String cipher)
cipher - Name and mode of cipher used to encrypt the SRTP streampublic void secureOff()
public void showSAS(String sas, boolean verified)
sas - The string containing the SAS.verified - If verified is true then SAS was verified by both
parties during a previous call, otherwise it is set to false.public void confirmGoClear()
public void showMessage(ZrtpCodes.MessageSeverity sev, EnumSet<?> subCode)
ZrtpCodes#MessageSeverity. The
UI may use this indicator to highlight messages or alike.
Depending on the severity code the EnumSet subcode parameter contains
one enumeration of either ZrtpCodes#InfoCodes, ZrtpCodes#WarningCodes,
ZrtpCodes#SevereCodes, or ZrtpCodes#ZrtpErrorCodes. The
ZrtpCodes#ZrtpErrorCodes enumeration has a public value field that
contains the ZRTP error code as defined in the ZRTP specification.sev - Severity of the message.subCode - The subcode identifying the reason.ZrtpCodes.MessageSeveritypublic void zrtpNegotiationFailed(ZrtpCodes.MessageSeverity severity, EnumSet<?> subCode)
severity - This defines the message's severitysubCode - The subcode identifying the reason.public void zrtpNotSuppOther()
public void zrtpAskEnrollment(ZrtpCodes.InfoEnrollment info)
info - Give some information to the user about the PBX requesting an
enrollment.public void zrtpInformEnrollment(ZrtpCodes.InfoEnrollment info)
info - Give some information to the user about the result of an
enrollment.public void signSAS(byte[] sasHash)
setSignatureData() to set the resulting
signature in the ZRTP protocol. Refer to chapter 7.2 of RFC 6189.sasHash - The SAS hash to sign.public boolean checkSASSignature(byte[] sasHash)
getSignatureData()of
ZrtpQueue to get the signature data and to perform the signature check.
Refer to chapter 7.2 of RFC 6189 (ZRTP specification).
NOTEsasHash - The sasHash that was signed by the other peer.Copyright © 2020. All rights reserved.