Cryptography, the science of secret writing, is the biggest, baddest security tool in the application programmer's arsenal. Cryptography provides three services that are crucial in secure programming. These include a cryptographic cipher that protects the secrecy of your data; cryptographic certificates, which prove identity (authentication); and digital signatures, which ensure your data has not been damaged or tampered with.
This book covers cryptographic programming in Java. Java 1.1 and Java 1.2 provide extensive support for cryptography with an elegant architecture, the Java Cryptography Architecture (JCA). Another set of classes, the Java Cryptography Extension (JCE), provides additional cryptographic functionality. This book covers the JCA and the JCE from top to bottom, describing the use of the cryptographic classes as well as their innards.
The book is designed for moderately experienced Java programmers who want to learn how to build cryptography into their applications. No prior knowledge of cryptography is assumed. The book is peppered with useful examples, ranging from simple demonstrations in the first chapter to full-blown applications in later chapters.
Topics include:
The Java Cryptography Architecture (JCA)
The Java Cryptography Extension (JCE)
Cryptographic providers
The Sun key management tools
Message digests, digital signatures, and certificates (X509v3)
Block and stream ciphers
Implementations of the ElGamal signature and cipher algorithms
A network talk application that encrypts all data sent over the network
Jonathan Knudsen is an author at O'Reilly & Associates. His books include The Unofficial Guide to Lego Mindstorms Robots, Java 2D Graphics, and Java Cryptography. He is the Courseware Writer for LearningPatterns.com.
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects.
The image on the cover of Java Cryptography is from the CMCD PhotoCD Collection. It was manipulated by Edie Freedman using Adobe Photoshop 3.0 and Adobe Gallery Effects filters. The cover layout was produced with Quark XPress 3.3 using the Bodoni Black font from URW Software.
Whenever possible, our books use RepKover?, a durable and flexible lay-flat binding. If the page count exceeds RepKover's limit, perfect binding is used. The inside layout was designed by Nancy Priest. Text was prepared by Erik Ray in SGML DocBook 2.4 DTD. The print version of this book was created by translating the SGML source into a set of gtroff macros using a filter developed at ORA by Norman Walsh. Steve Talbott designed and wrote the underlying macro set on the basis of the GNU troff -gs macros; Lenny Muellner adapted them to SGML and implemented the book design. The GNU groff text formatter version 1.09 was used to generate PostScript output. The heading font is Bodoni BT; the text font is New Baskerville. The screen shots that appear in the book were created in Adobe Photoshop 4 and the illustrations were created in Macromedia Freehand 7.0 by Robert Romano.
X is the random variable that a number in the range from 1 to p-1 is a primitive element.
1: is by the Fact 2.132, iii
2: is by the Fact 2.101, i
3: is by the Fact 2.102 for p-1 > 5
So if the number of bits of p-1 is 2048 bits then we get 1 / 6 ln ln (p-1) ~ 0.023
That means only every 44th number is a generator and in my opinion this strongly disqualifies
the "any random number" approach by the author as a secure solution.
Do not get my wrong, the "any random number will do" approach might be appropriate for a book
that concentrates on teaching Java cryptography implementation aspects, such as this book, not
elaborating on an all-time secure solution. But if this is so the author is supposed to mention
it somewhere in the text which, unfortunately again, did not happen.
If you want to implement a really secure ElGamalCipher you need to consider precomputed big safe
primes and their associated generators. You can have a look at RFC2412 and at the internet draft
draft-ietf-ipsec-ike-modp-groups-04.txt to be found at www.ietf.org. I think this is a pretty
good excercise for students who mastered the basics.
Overall, I strongly encourage the author to revise the first edition and be a bit more rigorous
on security aspects of the implemented algorithms.
11/10/2001
5.0
Java Cryptography Review
By bert
from Undisclosed
Comments about oreilly Java Cryptography:
Whats wrong with the Math???
Hey this book is a must for the budding Java programmer(make sure you can comfortably program in Java-or else it's just a book you'll struggle to understand the core facts while trying to grasp the language with) Top notch, go buy, go encrypt and stop your aunty sally from reading your "private" mail.
8/7/2001
(2 of 2 customers found this review helpful)
3.0
Java Cryptography Review
By David Bejjam
from Undisclosed
Comments about oreilly Java Cryptography:
The word Cryptography scares many Java Programmers. This book clearly explains the fundamentals of Cryptography easily.
6/18/2001
3.0
Java Cryptography Review
By Matt Hooker
from Undisclosed
Comments about oreilly Java Cryptography:
A good general read on Java Cryptography. There are a few errors in some of the code examples, but nothing that a quick glance over the Security API javadocs can't quickly fix. We had quite a major project on the go and the book was invaluable during that time. Well worth investing in. I would have given a higher rating, but I am a man in search of perfection and the fact that the book contained erroneous code prevents me from so doing.
6/7/2001
4.0
Java Cryptography Review
By BHUSHAN.THAMMINENI
from Undisclosed
Comments about oreilly Java Cryptography:
Excellent book,when i was researching on cryptography
and related stuff,as our company wanted to become CSP
(cryptography service provider)on its own turn,after
loitering across thousands of pages over the net,i
found in this book thoughts that are crystalline and
distilled,about cryptography, where you could find
confluence of real mathematics and serious coding.
i recommend this book without hesitation to any
upcoming programmer,who wants become some day man
of difference.commendable work indeed.
1/31/2001
5.0
Java Cryptography Review
By Li-fan Chen
from Undisclosed
Comments about oreilly Java Cryptography:
There's no better first book on cryptography for a programmer to buy.
You get a great deal of exposure to an important facet of network security through this little gem. It's friendly and to the point.
The Java API is excellent--but the idea of cryptography is little odd to the everyday web or network application programmer. Having someone to kindly bridge the crypto-what-ja-ma-call-its to a world of how-do-i-wrap-it-around-my-web-or-mail-service is simply priceless. There's NO silly cryptomath (because only those cryptoexperts get the math anyway) but instead it's filled with no-nonsense coverage of how each and every common crypto engine and crypto-"protocol" takes your stream of data and converts them to cryptograms. If you always like to learn as MUCH as you could about a particular computational wonder tool before tackling a project without turning your brain to mush with research mathematics--you'll like this book.
It's just one of those books I wished I read a lot earlier so I won't have an excuse to avoid APIs that exposes applied cryptography to network applications all these years. I highly recommend this book before you head on to the math of it.
It's too bad the SSL/TLS API for Java never made it into this first edition (it did make it into O'Reilly's latest Java network programming book though).
Any one know of a book just like this one but for another language like C or Perl? With a book like this you don't need to explain it all over again--but illustration and snippets of code showing how to use the various APIs in other languages would be useful. I think if the author is willing to dabble into all of these issues and give away his findings on a book website it will be just AWESOME! A second edition of said book with all of these issues covered would be just grand too :-)
7/21/2000
4.0
Java Cryptography Review
By sean
from Undisclosed
Comments about oreilly Java Cryptography:
This book is for beginners??
Hmmm, once you get into security world, it should be estimated more than that...I guess..
As a java programmer who wishes to learn and use security algorithms, I couldn't find better book than this...(I didn't get bribes from Knudsen.)
7/14/2000
3.0
Java Cryptography Review
By Omid Milani Fard
from Undisclosed
Comments about oreilly Java Cryptography:
This is a good book for begginer's on java cryptography!