Top Fields Constructors Methods
org.bouncycastle.tls.crypto.impl.jcajce

pack-priv final Class JcaTlsRSAEncryptor

extends Object
implements TlsEncryptor
Class Inheritance
All Implemented Interfaces
org.bouncycastle.tls.crypto.TlsEncryptor
Imports
java.io.IOException, java.security.GeneralSecurityException, .PublicKey, javax.crypto.Cipher, javax.crypto.spec.SecretKeySpec, org.bouncycastle.tls.AlertDescription, .TlsFatalAlert, org.bouncycastle.tls.crypto.TlsEncryptor

Field Summary

Modifier and TypeField and Description
private final JcaTlsCrypto
private final PublicKey

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public byte[]
encrypt(byte[]
byte array containing the input data.
input
,
int
offset into input where the data starts.
inOff
,
int
the length of the data to encrypt.
length
)

Implements org.bouncycastle.tls.crypto.TlsEncryptor.encrypt.

Encrypt data from the passed in input array.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

cryptoback to summary
private final JcaTlsCrypto crypto
pubKeyRSAback to summary
private final PublicKey pubKeyRSA

Constructor Detail

JcaTlsRSAEncryptorback to summary
pack-priv JcaTlsRSAEncryptor(JcaTlsCrypto crypto, PublicKey pubKeyRSA)

Method Detail

encryptback to summary
public byte[] encrypt(byte[] input, int inOff, int length) throws IOException

Implements org.bouncycastle.tls.crypto.TlsEncryptor.encrypt.

Doc from org.bouncycastle.tls.crypto.TlsEncryptor.encrypt.

Encrypt data from the passed in input array.

Parameters
input:byte[]

byte array containing the input data.

inOff:int

offset into input where the data starts.

length:int

the length of the data to encrypt.

Returns:byte[]

the encrypted data.

Exceptions
IOException:
in case of a processing error.