Top Description Fields Constructors Methods
org.bouncycastle.crypto.engines

public Class RFC3211WrapEngine

extends Object
implements Wrapper
Class Inheritance
All Implemented Interfaces
org.bouncycastle.crypto.Wrapper
Imports
java.security.SecureRandom, org.bouncycastle.crypto.BlockCipher, .CipherParameters, .CryptoServicesRegistrar, .InvalidCipherTextException, .Wrapper, org.bouncycastle.crypto.modes.CBCBlockCipher, org.bouncycastle.crypto.params.ParametersWithIV, .ParametersWithRandom, org.bouncycastle.util.Arrays

an implementation of the RFC 3211 Key Wrap Specification.

Field Summary

Modifier and TypeField and Description
private CBCBlockCipher
private boolean
private ParametersWithIV
private SecureRandom

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public String
getAlgorithmName()

Implements org.bouncycastle.crypto.Wrapper.getAlgorithmName.

Return the name of the algorithm the wrapper implements.

public void
init(boolean forWrapping, CipherParameters param)

Implements org.bouncycastle.crypto.Wrapper.init.

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

Implements org.bouncycastle.crypto.Wrapper.unwrap.

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

Implements org.bouncycastle.crypto.Wrapper.wrap.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

engineback to summary
private CBCBlockCipher engine
forWrappingback to summary
private boolean forWrapping
paramback to summary
private ParametersWithIV param
randback to summary
private SecureRandom rand

Constructor Detail

RFC3211WrapEngineback to summary
public RFC3211WrapEngine(BlockCipher engine)

Method Detail

getAlgorithmNameback to summary
public String getAlgorithmName()

Implements org.bouncycastle.crypto.Wrapper.getAlgorithmName.

Doc from org.bouncycastle.crypto.Wrapper.getAlgorithmName.

Return the name of the algorithm the wrapper implements.

Returns:String

the name of the algorithm the wrapper implements.

initback to summary
public void init(boolean forWrapping, CipherParameters param)

Implements org.bouncycastle.crypto.Wrapper.init.

unwrapback to summary
public byte[] unwrap(byte[] in, int inOff, int inLen) throws InvalidCipherTextException

Implements org.bouncycastle.crypto.Wrapper.unwrap.

wrapback to summary
public byte[] wrap(byte[] in, int inOff, int inLen)

Implements org.bouncycastle.crypto.Wrapper.wrap.