org.bouncycastle.crypto.engines

Class RC2WrapEngine

public class RC2WrapEngine extends Object implements Wrapper

Wrap keys according to RFC 3217 - RC2 mechanism
Method Summary
StringgetAlgorithmName()
Method getAlgorithmName
voidinit(boolean forWrapping, CipherParameters param)
Method init
byte[]unwrap(byte[] in, int inOff, int inLen)
Method unwrap
byte[]wrap(byte[] in, int inOff, int inLen)
Method wrap

Method Detail

getAlgorithmName

public String getAlgorithmName()
Method getAlgorithmName

Returns: the algorithm name "RC2".

init

public void init(boolean forWrapping, CipherParameters param)
Method init

Parameters: forWrapping param

unwrap

public byte[] unwrap(byte[] in, int inOff, int inLen)
Method unwrap

Parameters: in inOff inLen

Returns: the unwrapped bytes.

Throws: InvalidCipherTextException

wrap

public byte[] wrap(byte[] in, int inOff, int inLen)
Method wrap

Parameters: in inOff inLen

Returns: the wrapped bytes.