# JCE Query : How to Initialize Cipher for Encrypt/Decrypt

Vishal Goenka (vgoenka@novell.com)
Sat, 10 Jan 1998 15:54:45 -0700

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: Alex Horovitz: "JCE Query : How to Initialize Cipher for Encrypt/Decrypt"
- Previous message: Shelina Gorain: "does the JECF use the JDK 1.2 security api?"

    Message-Id: <s4b799db.043@novell.com>

    Date: Sat, 10 Jan 1998 15:54:45 -0700

    From: Vishal Goenka <vgoenka@novell.com>

    To: java-security@web1.javasoft.com

    Subject: JCE Query : How to Initialize Cipher for Encrypt/Decrypt

Couple of questions on usage of Cipher class :

1. The methods do not seem to take any parameter that may specify whether
the Cipher has to be used for encryption or decryption.
2. Since all methods (except constructor) are final, it appears that the
provider must extend CipherSpi. Does Cipher.getInstance() instantiates the
Provider's CipherSpi and pass that as an argument to the Cipher constructor,
or, does it instantiate the provider's Cipher (subclass of Cipher) and the
subclass is expected to call super(providerCipherSpi, ....).

I would appreciate if some more documentation on usage of JCE classes in
general is made available. Source code would do too, but I guess that is not
distributed right now ?

Regards,
Vishal Goenka
Novell

- Next message: Alex Horovitz: "JCE Query : How to Initialize Cipher for Encrypt/Decrypt"
- Previous message: Shelina Gorain: "does the JECF use the JDK 1.2 security api?"