Cipher : Java Glossary

go to home page C words local find full screen, hide local find menu Google search web for more information on this topic jump to foot of page translate this page with Babelfish 2008-06-19 by Roedy Green ©1996-2009 Canadian Mind Products
index page for letter ⇒ punctuation 0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z (all)
Cipher
Here’s how to encrypt and decrypt a message using CipherOutputStream/ CipherInputStream The methods used are all part of Sun’s JCE. Sun’s JCE documenation is all but useless. You pretty well have to Google the web to find sample code to use these methods for particular algorithms and block modes.

AES Encryption

Requires a shared secret key between sender and receiver.

RSA Public/Private Key Encryption

Requires sender to know public key of receiver, and receiver requires the corresponding private key.

Learning More

The Javadoc is almost useless. All the methods have undocumented parameters that are specific to various algorithms. Your best bet is to scour the Internet with Google, e.g. search for PBE DECRYPT_MODE to find Java source code listings where people used the PBE algorithm and Cipher. DECRYPT_MODE to decrypt messages. Beware, much of the code you will find is not working properly. People posted it seeking help getting it to work. Another source of information is books on JCE.

Sun’s Javadoc on the Cipher class : available:
Sun’s Javadoc on the CipherInputStream class : available:
Sun’s Javadoc on the CipherOutputStream class : available:
Sun’s Javadoc on the KeyGenerator class : available:
Sun’s Javadoc on the SecretKey class : available:
Sun’s Javadoc on the SecretKeySpec class : available:
Sun’s JDK Technote Guide on cryptography algorithm names : available:

CMP homejump to top
CMP logo
feedback Please email your feedback for publication, errors, omissions, broken/redirected link reports
and suggestions to improve this page to Roedy Green : feedback email
made with CSS
HTML Checked!
ICRA ratings logo
mindprod.com IP:[65.110.21.43]
Your face IP:[38.103.63.62] The information on this page is for non-military use only.
You are visitor number 11. Military use includes use by defence contractors.
You can get a fresh copy of this page from: or possibly from your local J: drive (Java virtual drive/mindprod.com website mirror)
http://mindprod.com/jgloss/cipher.html J:\mindprod\jgloss\cipher.html