Uses of Class
org.drasyl.handler.remote.protocol.Nonce
Package
Description
Classes for crypto-related operations.
The protocol used for communication with remote peers.
Contains classes necessary for encrypted peer/application communication.
-
Uses of Nonce in org.drasyl.crypto
Modifier and TypeMethodDescriptionbyte[]
Crypto.decrypt
(byte[] cipher, byte[] authTag, Nonce nonce, SessionPair sessionPair) Decrypt the givencipher
, by verify theauthTag
as an authentication tag, uses the givennonce
and decrypting with the rx part of thesessionPair
.byte[]
Crypto.encrypt
(byte[] message, byte[] authTag, Nonce nonce, SessionPair sessionPair) Encrypts the givenmessage
, by addingauthTag
as an authentication tag, using the given (hopefully fresh)nonce
and encrypting with the tx part of thesessionPair
. -
Uses of Nonce in org.drasyl.handler.remote.protocol
Modifier and TypeMethodDescriptionabstract Nonce
PublicHeader.getNonce()
RemoteMessage.getNonce()
static Nonce
Nonce.of
(byte[] bytes) static Nonce
static Nonce
Nonce.of
(ImmutableByteArray bytes) static Nonce
Nonce.randomNonce()
Static factory to retrieve a randomly generatedNonce
.Modifier and TypeMethodDescriptionstatic AcknowledgementMessage
AcknowledgementMessage.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, long time) Creates new acknowledgement message.static ApplicationMessage
ApplicationMessage.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, io.netty.buffer.ByteBuf payload) Creates new application message.static ArmedProtocolMessage
ArmedProtocolMessage.of
(Nonce nonce, HopCount hopCount, int networkId, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, io.netty.buffer.ByteBuf bytes) Creates an armed message.static DiscoveryMessage
DiscoveryMessage.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, long time, long joinTime) Creates new application message.static PublicHeader
PublicHeader.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork) static UnarmedProtocolMessage
UnarmedProtocolMessage.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, io.netty.buffer.ByteBuf bytes) Creates an unarmed message.static UniteMessage
UniteMessage.of
(HopCount hopCount, boolean isArmed, int networkId, Nonce nonce, DrasylAddress recipient, DrasylAddress sender, ProofOfWork proofOfWork, DrasylAddress address, InetAddress inetAddress, UnsignedShort port) Creates new unit message. -
Uses of Nonce in org.drasyl.node.handler.crypto
Modifier and TypeMethodDescriptionstatic ArmHeader
ArmHeader.of
(AgreementId agreementId, Nonce nonce, io.netty.buffer.ByteBuf data) protected Object
ModifierConstructorDescriptionArmHeader
(AgreementId agreementId, Nonce nonce, io.netty.buffer.ByteBuf data)