public class Crypto
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
Crypto.ChannelCipher
Interface for a ChannelCipher instance that may be associated with a Channel.
|
static class |
Crypto.CipherParams
A class encapsulating the client-specifiable parameters for
the cipher.
|
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_ALGORITHM |
static int |
DEFAULT_BLOCKLENGTH |
static int |
DEFAULT_KEYLENGTH |
| Constructor and Description |
|---|
Crypto() |
| Modifier and Type | Method and Description |
|---|---|
static Crypto.ChannelCipher |
getCipher(ChannelOptions opts)
Internal; get a ChannelCipher instance based on the given ChannelOptions
|
static Crypto.CipherParams |
getDefaultParams()
Obtain a default CipherParams.
|
static Crypto.CipherParams |
getDefaultParams(byte[] key)
Obtain a default CipherParams.
|
static Crypto.CipherParams |
getParams(java.lang.String algorithm,
byte[] key) |
static Crypto.CipherParams |
getParams(java.lang.String algorithm,
int keyLength) |
public static final java.lang.String DEFAULT_ALGORITHM
public static final int DEFAULT_KEYLENGTH
public static final int DEFAULT_BLOCKLENGTH
public static Crypto.CipherParams getDefaultParams()
public static Crypto.CipherParams getDefaultParams(byte[] key)
public static Crypto.CipherParams getParams(java.lang.String algorithm, int keyLength)
public static Crypto.CipherParams getParams(java.lang.String algorithm, byte[] key) throws java.security.NoSuchAlgorithmException
java.security.NoSuchAlgorithmExceptionpublic static Crypto.ChannelCipher getCipher(ChannelOptions opts) throws AblyException
opts - AblyException