The PRNGDecryptor is used in conjunction with a PseudoRandomSource
to decrypt data provided to this class in a stream interface to the
calling class.
A PRNG represents a Pseudo Random Number Generator.
It provides a similar relationship or functionality
that the BlockDecryptor uses for BlockDecryptorEngines. That is, it
allows you to use a PseudoRandomSource as an input stream instead
of relying on the decryption mechanisms exposed in the PseudoRandomSource
class.
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.
PRNGDecryptor(PseudoRandomSource keystream,
InputStream input)
Creates a PRNGDecryptor object based on an input stream
and a keystream that will create random numbers and decrypt the
ciphertext with them.
Method Summary
protected void
decrypt(byte[] data,
int offset,
int length)
Decrypts data according to the specific implementation of the chosen stream cipher.
Creates a PRNGDecryptor object based on an input stream
and a keystream that will create random numbers and decrypt the
ciphertext with them.
Parameters:
keystream - A PseudoRandomSource object to recreate the original random numbers in
order to decrypt the input stream.
input - An inputstream object containing the plaintext.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.
Method Detail
decrypt
protected void decrypt(byte[] data,
int offset,
int length)
throws CryptoTokenException
data - A byte array containing the input to the stream cipher.
offset - The offset, or initial position within the array, of the information to decrypt.
length - The length, in bytes, of the information to decrypt.
Throws:
CryptoTokenException - Thrown when an error occurs with the crypto
token or the crypto token is invalid.
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.
A String that represents the name of the algorithm.
Since:
JDE 3.6.0
Category:
Signed: This element is only accessible by signed clients. If you intend to use this element, please contact RIM to establish the necessary agreements that will allow you to have your COD files signed. Signing is only required for use on the device, development under the JDE can occur without signing the CODs.
Copyright 1999-2007 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved. Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. Copyright 2002-2003 Nokia Corporation All Rights Reserved. Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.