org.polyglotted.crypto.api
Interface Crypto

All Known Implementing Classes:
AbstractCrypto, AesDecrypter, AesEncrypter, RsaDecrypter, RsaEncrypter

public interface Crypto

Marker interface for all RSA crtpto classes

Author:
Shankar Vasudevan

Field Summary
static String AES_ALGORITHM
           
static String RSA_ALGORITHM
           
 
Method Summary
 byte[] crypt(byte[] bytes)
          Perform encrypt or decrypt action
 String crypt(String text)
          Perform encrypt or decrypt action
 String getAlgorithm()
           
 Cipher getCipher()
           
 

Field Detail

RSA_ALGORITHM

static final String RSA_ALGORITHM
See Also:
Constant Field Values

AES_ALGORITHM

static final String AES_ALGORITHM
See Also:
Constant Field Values
Method Detail

crypt

byte[] crypt(byte[] bytes)
Perform encrypt or decrypt action

Parameters:
bytes - the byte[] to crypt
Returns:
the result byte[]

crypt

String crypt(String text)
Perform encrypt or decrypt action

Parameters:
text - the String to crypt
Returns:
the result String

getCipher

Cipher getCipher()
Returns:
the cipher that is used by this crypto

getAlgorithm

String getAlgorithm()
Returns:
the algorithm that is used by this crypto


Copyright © 2012-2013 Polyglotted Org. All Rights Reserved.