public class SymKey extends Object
| Constructor and Description |
|---|
SymKey() |
| Modifier and Type | Method and Description |
|---|---|
static Key |
buildKey(String algname,
byte[] enc,
int off,
int len) |
static byte[] |
decrypt(Key key,
AlgorithmParameters algp,
byte[] ciphertxt,
int off,
int len) |
static byte[] |
decryptPBE(char[] passwd,
byte[] ciphertxt,
int off,
int len) |
static byte[] |
encrypt(Key key,
AlgorithmParameters algp,
byte[] plaintxt,
int off,
int len) |
static byte[] |
encryptPBE(char[] passwd,
byte[] plaintxt,
int off,
int len) |
static Key |
generateKey(String algname,
int keysize) |
public static Key generateKey(String algname, int keysize) throws NoSuchAlgorithmException
NoSuchAlgorithmExceptionpublic static byte[] encrypt(Key key, AlgorithmParameters algp, byte[] plaintxt, int off, int len) throws GeneralSecurityException
GeneralSecurityExceptionpublic static byte[] decrypt(Key key, AlgorithmParameters algp, byte[] ciphertxt, int off, int len) throws GeneralSecurityException
GeneralSecurityExceptionpublic static byte[] encryptPBE(char[] passwd,
byte[] plaintxt,
int off,
int len)
throws GeneralSecurityException,
UnsupportedEncodingException
public static byte[] decryptPBE(char[] passwd,
byte[] ciphertxt,
int off,
int len)
throws GeneralSecurityException,
UnsupportedEncodingException
Copyright 2010-2018 Grey Software (Yusef Badri). All Rights Reserved.