jfileupload.transfer.client.util
Class PBE

java.lang.Object
  extended by jfileupload.transfer.client.util.PBE

public class PBE
extends java.lang.Object

PBE helper.


Field Summary
static java.lang.String ENCODING
           
 
Constructor Summary
PBE(Conf conf)
           
 
Method Summary
 java.lang.String bytesToHexString(byte[] in)
           
 byte[] cipher(char[] password, byte[] buffer, int offset, int len)
          Cipher the byte buffer.
 byte[] decipher(char[] password, byte[] buffer, int offset, int len)
          Decipher the byte buffer.
 java.lang.String decipherHexString(java.lang.String str)
           
 byte[] getBytes(java.lang.String list)
          Return byte array from a comma separated list.
 byte[] hexStringToBytes(java.lang.String str)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ENCODING

public static java.lang.String ENCODING
Constructor Detail

PBE

public PBE(Conf conf)
Method Detail

cipher

public byte[] cipher(char[] password,
                     byte[] buffer,
                     int offset,
                     int len)
              throws java.lang.Exception
Cipher the byte buffer.

Parameters:
password -
buffer -
offset -
len -
Returns:
Throws:
java.lang.Exception

decipher

public byte[] decipher(char[] password,
                       byte[] buffer,
                       int offset,
                       int len)
                throws java.lang.Exception
Decipher the byte buffer.

Parameters:
password -
buffer -
offset -
len -
Returns:
Throws:
java.lang.Exception

getBytes

public byte[] getBytes(java.lang.String list)
Return byte array from a comma separated list.

Parameters:
list -
Returns:

hexStringToBytes

public byte[] hexStringToBytes(java.lang.String str)

bytesToHexString

public java.lang.String bytesToHexString(byte[] in)

decipherHexString

public java.lang.String decipherHexString(java.lang.String str)