YAACC - UPNP Client and Server
Loading...
Searching...
No Matches
de.yaacc.sendspin.secure.NoiseTransport Class Reference

The transport mode after a Noise handshake: one cipher per direction, a 64 bit counter each. More...

Collaboration diagram for de.yaacc.sendspin.secure.NoiseTransport:
Collaboration graph

Public Member Functions

NoiseSuite suite ()
 
byte[] handshakeHash ()
 The hash of the handshake that made this transport: the prologue of a re-handshake.
 
synchronized byte[] encrypt (byte[] plaintext) throws NoiseException
 
byte[] decrypt (byte[] ciphertext) throws NoiseException
 
void destroy ()
 

Static Public Attributes

static final int MAX_MESSAGE_LENGTH = 65535
 The most a Noise message may hold (Noise, section 3).
 
static final int MAX_PLAINTEXT_LENGTH = MAX_MESSAGE_LENGTH - NoiseSuite.TAG_LENGTH
 The most plaintext one transport message holds: the length less the tag.
 

Detailed Description

The transport mode after a Noise handshake: one cipher per direction, a 64 bit counter each.

A message that does not verify, a repeated or reordered one included (the counter is implicit), ends the connection: the caller closes on a NoiseException. One thread may encrypt and another decrypt at the same time.


The documentation for this class was generated from the following file: