Uses of Class
org.drasyl.crypto.sodium.SessionPair
Packages that use SessionPair
Package
Description
Classes for crypto-related operations.
Libsodium wrappers for the crypto operations of drasyl
The protocol used for communication with remote peers.
Contains classes necessary for encrypted peer/application communication.
-
Uses of SessionPair in org.drasyl.crypto
Methods in org.drasyl.crypto that return SessionPairModifier and TypeMethodDescription<P extends PublicKey,S extends SecretKey>
SessionPairCrypto.generateSessionKeyPair(KeyPair<P, S> myKeyPair, PublicKey receiverPublicKey) Generates session key pair from themyKeyPairandreceiverKeyPair.Methods in org.drasyl.crypto with parameters of type SessionPairModifier and TypeMethodDescriptionbyte[]Crypto.decrypt(byte[] cipher, byte[] authTag, Nonce nonce, SessionPair sessionPair) Decrypt the givencipher, by verify theauthTagas an authentication tag, uses the givennonceand decrypting with the rx part of thesessionPair.byte[]Crypto.encrypt(byte[] message, byte[] authTag, Nonce nonce, SessionPair sessionPair) Encrypts the givenmessage, by addingauthTagas an authentication tag, using the given (hopefully fresh)nonceand encrypting with the tx part of thesessionPair. -
Uses of SessionPair in org.drasyl.crypto.sodium
Methods in org.drasyl.crypto.sodium that return SessionPairModifier and TypeMethodDescriptionDrasylSodiumWrapper.cryptoKxClientSessionKeys(byte[] clientPk, byte[] clientSk, byte[] serverPk) This function computes a pair of shared keys (rx and tx) using the client's public key clientPk, the client's secret key clientSk and the server's public key serverPk.DrasylSodiumWrapper.cryptoKxServerSessionKeys(byte[] serverPk, byte[] serverSk, byte[] clientPk) This function computes a pair of shared keys (rx and tx) using the client's public key clientPk, the server's secret key serverSk and the server's public key serverPk.static SessionPairSessionPair.of(byte[] rx, byte[] tx) -
Uses of SessionPair in org.drasyl.handler.remote.protocol
Methods in org.drasyl.handler.remote.protocol with parameters of type SessionPairModifier and TypeMethodDescriptionFullReadMessage.arm(io.netty.buffer.ByteBuf byteBuf, Crypto cryptoInstance, SessionPair sessionPair) Returns an armed version (ArmedProtocolMessage) of this message for sending it through untrustworthy channels.UnarmedProtocolMessage.arm(Crypto cryptoInstance, SessionPair sessionPair) Returns an armed version (ArmedProtocolMessage) of this message.UnarmedProtocolMessage.armAndRelease(Crypto cryptoInstance, SessionPair sessionPair) Returns an armed version (ArmedProtocolMessage) of this message and then releases this message.ArmedProtocolMessage.disarm(Crypto cryptoInstance, SessionPair sessionPair) Returns a disarmed version (FullReadMessage) of this message.ArmedProtocolMessage.disarmAndRelease(Crypto cryptoInstance, SessionPair sessionPair) Returns a disarmed version (FullReadMessage) of this message and then releases this message. -
Uses of SessionPair in org.drasyl.node.handler.crypto
Methods in org.drasyl.node.handler.crypto that return SessionPairMethods in org.drasyl.node.handler.crypto with parameters of type SessionPairModifier and TypeMethodDescriptionstatic AgreementAgreement.of(AgreementId id, SessionPair sessionPair, long staleAt)