Package com.iwebpp.crypto
Class TweetNaclFast.Box
java.lang.Object
com.iwebpp.crypto.TweetNaclFast.Box
- Enclosing class:
- TweetNaclFast
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbyte[]
after
(byte[] message, int moff, int mlen) byte[]
after
(byte[] message, int moff, int mlen, byte[] theNonce) byte[]
before()
byte[]
box
(byte[] message) byte[]
box
(byte[] message, byte[] theNonce) byte[]
box
(byte[] message, int moff) byte[]
box
(byte[] message, int moff, byte[] theNonce) byte[]
box
(byte[] message, int moff, int mlen) byte[]
box
(byte[] message, int moff, int mlen, byte[] theNonce) long
getNonce()
long
static TweetNaclFast.Box.KeyPair
keyPair()
static TweetNaclFast.Box.KeyPair
keyPair_fromSecretKey
(byte[] secretKey) byte[]
open
(byte[] box) byte[]
open
(byte[] box, byte[] theNonce) byte[]
open
(byte[] box, int boxoff) byte[]
open
(byte[] box, int boxoff, byte[] theNonce) byte[]
open
(byte[] box, int boxoff, int boxlen) byte[]
open
(byte[] box, int boxoff, int boxlen, byte[] theNonce) byte[]
open_after
(byte[] box, int boxoff, int boxlen) byte[]
open_after
(byte[] box, int boxoff, int boxlen, byte[] theNonce) void
setNonce
(long nonce)
-
Field Details
-
publicKeyLength
public static final int publicKeyLength- See Also:
-
secretKeyLength
public static final int secretKeyLength- See Also:
-
nonceLength
public static final int nonceLength- See Also:
-
zerobytesLength
public static final int zerobytesLength- See Also:
-
boxzerobytesLength
public static final int boxzerobytesLength- See Also:
-
overheadLength
public static final int overheadLength- See Also:
-
-
Constructor Details
-
Box
public Box(byte[] theirPublicKey, byte[] mySecretKey) -
Box
public Box(byte[] theirPublicKey, byte[] mySecretKey, long nonce)
-
-
Method Details
-
setNonce
public void setNonce(long nonce) -
getNonce
public long getNonce() -
incrNonce
public long incrNonce() -
box
public byte[] box(byte[] message) -
box
public byte[] box(byte[] message, int moff) -
box
public byte[] box(byte[] message, int moff, int mlen) -
box
public byte[] box(byte[] message, byte[] theNonce) -
box
public byte[] box(byte[] message, int moff, byte[] theNonce) -
box
public byte[] box(byte[] message, int moff, int mlen, byte[] theNonce) -
open
public byte[] open(byte[] box) -
open
public byte[] open(byte[] box, int boxoff) -
open
public byte[] open(byte[] box, int boxoff, int boxlen) -
open
public byte[] open(byte[] box, byte[] theNonce) -
open
public byte[] open(byte[] box, int boxoff, byte[] theNonce) -
open
public byte[] open(byte[] box, int boxoff, int boxlen, byte[] theNonce) -
before
public byte[] before() -
after
public byte[] after(byte[] message, int moff, int mlen) -
after
public byte[] after(byte[] message, int moff, int mlen, byte[] theNonce) -
open_after
public byte[] open_after(byte[] box, int boxoff, int boxlen) -
open_after
public byte[] open_after(byte[] box, int boxoff, int boxlen, byte[] theNonce) -
keyPair
-
keyPair_fromSecretKey
-