Practical Cryptography 140
Practical Cryptography | |
author | Neils Ferguson and Bruce Schneier |
pages | xx + 410 |
publisher | Wiley |
rating | 10/10 |
reviewer | James Petts |
ISBN | 0471223573 |
summary | Pure Hands-On Cryptographic Gold; invaluable guide for cryptographers. |
Schneier is one of the world's foremost experts, not just on cryptography, but also on security. It was as he delved deeper into the security of cryptographic systems that he realised that even though - theoretically at least - cryptography could be made arbitrarily secure, this was one of the more tractable problems in the security puzzle. For this reason, his company, Counterpane repositioned itself as a managed security company, rather than continuing to focus solely on cryptography. This transition was also reflected in his publication of Secrets and Lies (SL), which is very different in tone and focus from Applied Cryptography (AC). So where does Practical Cryptography (PC) fit in, and what does it offer? For me, the answer is that it lies pretty much squarely in the middle of the line reaching from AC to SL.
There is no shortage of products in the cryptography arena, but the vast majority of these attract undisguised scorn from professional cryptographers (at least those who can be bothered to comment on them), and although I am only an amateur in this field, I take it as axiomatic that only peer-reviewed cryptosystems (algorithms, protocols, etc) which have stood the test of time are worth taking even a preliminary peek at. This includes many that are described in AC. However, One of the problems with AC, openly acknowledged by the author, is that it contains essentially no implementation details. Furthermore, the cryptographic field has moved on since its publication, most notably with the adoption of Rijndael as the Advanced Encryption Standard, now a mandated Federal Information Processing Standard.
The source code to AC has been available from pretty much the moment of the book's publication, but one of the problems which faced a would-be cryptographic coder, is how to produce a working cryptographic product based on the routines that one could lay one's hands on. Merely incorporating the source code in a program does not a cryptosystem make: as Schneier points out cryptography is hard. And this is where this new book is invaluable: it tells you in great detail how hard it is, what the hardest parts are, and how you can maximise the return on the effort you may invest in developing cryptographic software.
The book pulls no punches, and does not gloss over any issues relating to implementing cryptographic systems. It deals with all the major components of a practical cryptosystem: the book's major sections are titled Message Security, Key Negotiation, Key Management and Miscellaneous.
Within each of these sections there are several chapters, covering virtually all the salient points imaginable, right down to the fundamentals. For example, the first chapter of the Key Management section deals with the clock. It explains from first principles the need for a clock: "At first glance, [a clock] is a decidedly un-cryptographic primitive, but because the current time is often used in cryptographic systems, we need a reliable clock." It is this sort of attention to particular implementation details that turns PC from a mere recipe book into an invaluable reference and a true cookbook.
Another invaluable feature is the generous use of pseudocode snippets, not only for algorithmic details, such as MACs and block cyphers, but also for higher-level operations like sending and receiving messages.
Ferguson and Schneier are refreshingly frank, too. Where they believe strongly in something, they let you know it. For example, the first paragraph of chapter 23, Standards, contains the statement that "[s]ecurity standards rarely work," while the authors go even further when dealing with X.509 certificates, stating on p.339, "[w]hatever you do, stay away from X.509 certificates. If you need a reason, read [40] and weep". This candour is refreshing, especially when juxtaposed with the weasel words that so many consultants and software vendors seem to rely on. However, this advice is not just given in curmudgeonly fashion, and when the authors discuss the matter of X.509 in a different context, they add, humorously, "[i]f you must use X.509, you have out condolences."
I am tempted to continue to analyse the book at great length, but to save space I will just highlight some further jewels from this work:
- Implementation issues such as swap files, language-specific memory handling behaviour, caches, etc. are covered in enough detail for you to understand how to do things, and more importantly, how not to do things.
- Randomness, pseudo-randomness and entropy are covered in enough depth for an implementor to avoid pitfalls, and pseudocode examples are given.
- Mathematical topics such as prime numbers, groups and large integer arithmetic are described in excellent detail.
- PKI, its promise, and failure are covered with wit and wisdom.
Is there anything I didn't like about the book? Frankly, no. Some might complain that it is priced too high (it lists at USD50 for the softcover, and USD70 for the hardcover), but it is printed on acid-free paper, and the density of useful advice is such that it outstrips in value many works which cost half the price or less.
If you are interested in crypto, do yourself a favour: buy this book.
You can purchase Practical Cryptography from bn.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.
DMCA (Score:5, Insightful)
I'm not joking...if you take the wording of the law literally?
Re:DMCA (Score:5, Funny)
Re:DMCA (Score:2)
Do yourself a favor and read the DMCA. http://www4.law.cornell.edu/uscode/17/1201.html
I
Re:DMCA (Score:1, Insightful)
Considering that the only reason to use an encryption algorithm is to control access to a message, I have to say you don't have a clue what you're talking about. Not only that, your humor detection circuit seems to be on the fritz.
Re:DMCA (Score:2)
Considering that the only reason to use an encryption algorithm is to control access to a message
I don't even know what to type here. I'm stunned, frankly.
Re:DMCA (Score:2)
>
> Considering that the only reason to use an encryption algorithm is to control access to a message, I have to say you don't
> have a clue what you're talking about. Not only that, your humor detection circuit seems to be on the fritz.
"Technological measure that controls access to a work" is defined in the DMCA. They are not talking about the english word "control" or "access," though the meaning is similar. Read the law if you want to un
Re:DMCA (Score:1)
(And so will DeCSS, if people start using CSS as an alternative to Rot-13ing their Usenet postings. ;-)
Re:DMCA (Score:1)
Re:DMCA (Score:1)
FP (Score:5, Informative)
Re:FP (Score:5, Funny)
I'm looking into this thing called a "caesar cipher", but it's slow going. I think it needs to be applied 13 times before the data is sufficiently encrypted.
Re:FP (Score:3, Funny)
Beware: it comes undone on March 15.
You call yourself an expert? (Score:3, Funny)
Applying it 26 times has to be twice as good. Has to be!
Worst. Whoring. Ever. (Score:1, Funny)
speaking of experts (Score:2, Insightful)
I am not in any way passing judgement on "jpetts" here. He, or she, is quite articulate, but could be anywhere from an expert with years of experience to someone who's "read a book or two" and talks a very good game.
Generally I try to assess a writer by coherence and consistency when I don't know the subject material myself. But that only gets one so far - and I usually spot some discrepanc
good companion to ac (Score:2, Informative)
This book is, sort of an executive summary of Applied Cryptography (AC), with some updates. It touches upon the insights that Scheneier mentioned in Secret and Lies (like crypto is the easy part and that won't s
Re:good companion to ac (Score:3, Interesting)
I'll tell ya what I think... (Score:5, Funny)
Re:I'll tell ya what I think... (Score:1)
Re:I'll tell ya what I think... (Score:2)
Re:I'll tell ya what I think... (Score:2)
Re:I'll tell ya what I think... (Score:1)
Remember to format the ciphertext, dude (Score:3, Funny)
Jakbs dfaks vbmka klsdf jalks jdSjk czLze qadjs kfsdk imzzo ikjpe adxxx
But please keep in mind: (Score:5, Funny)
Cryptography supports terrorism.
Reading about implementing cryptography supports terrorism.
Reading reviews about books about implementing cryptography supports terrorism.
Now turn off the computer, stand over there in the corner and we'll be by to pick you up in a little while. And remember, running supports terrorism.
Re:But please keep in mind: (Score:3, Funny)
No, driving off in your SUV supports terrorism.
Re:But please keep in mind: (Score:2)
What is Jesus is you co-pilot?
Re:But please keep in mind: (Score:2, Funny)
Re:But please keep in mind: (Score:2)
You terrorist!
Re:But please keep in mind: (Score:2)
Everybody runs...
Re:But please keep in mind: (Score:1)
Practical vs Applied (Score:5, Interesting)
Hopefully this helps the good guys more then the bad ones though...
Go calculate [webcalc.net] something.
Re:Practical vs Applied (Score:1, Redundant)
He mentioned it in this month Cryptogram.
Re:Practical vs Applied (Score:2)
http://www.counterpane.com/book-practical.
Re:Practical vs Applied (Score:5, Funny)
In case you hadn't noticed, the Slashdot story you just posted about your comment to is a review of that book.
Re:Practical vs Applied (Score:2)
Woops. Saw Applied Crypto linked in the description and that overroad the title.
Re:Practical vs Applied (Score:5, Insightful)
Currently, the only way to argue that a cryptosystem is secure is by reducing its security to that a well-studied primitive, like factoring, DLP, even DES! (Of course, it is true that we don't currently know of any explicit intractable problems, but if you are going to use a cryptosystem handed to you on a platter, better to know that its security has an undeniable link to factoring than merely that some group of software engineers somewhere couldn't find a way to break it.)
The point is that there is no "royal road" to cryptography. If you want to be a serious cryptographer, you need to get your hands dirty: understand what a reduction is, learn some complexity theory, learn some computational number theory. Of course, it is fine for end users or businesses to use prepackaged systems if they trust them. The dangerous road is the middle road, where we have "experts" who don't really understand the foundations of the subject.
If you want a laugh, read the description of pseudorandomness in Schneier's book and cf. that of, say, Goldreich's.
Re:Practical vs Applied (Score:3, Interesting)
I find it astonishing that a book that has only been out a few weeks has caused much damage.
Unless you a
Re:Practical vs Applied (Score:1)
These books are like popular science books such as A Brief History of Time, or Cosmos. They're not about making people an expert in a field, they're about helping the layman learn a little bit about a field.
Re:Practical vs Applied (Score:2)
I'd like to see the AC expand upon this, since I'm not quite sure what he means. Given the typical short attention span of
Schneier himself has mentioned the problem with poor crypto system designs (and the self-taug
Re:Practical vs Applied (Score:1)
After reading the review (I have not read the book being reviewed), I think your concerns are unfounded. Or better yet, your concerns are the reverse of the concerns of the book's authors. As I understand it, from reading the review, the authors are concerned that those who understand cryptography from a theoretical point of view -- that is, the "academics" -- would be the ones to create ineffective cryptosys
Re:you know, (Score:3, Funny)
I too will be paying for this with cash.
Re:you know, (Score:1)
did you know this? (Score:1)
Applied Cryptography (Score:5, Interesting)
"The Book the National Security Agency wanted never to be published..."
M@
Older stuff is a must read... (Score:5, Interesting)
Re:Older stuff is a must read... (Score:4, Interesting)
As the reviewers states, the algorithms have changed over the past several years, but it may be more important to remember that the basic issues have not. People are still trying to pass off obviously flawed protocols as good security measures.
Re:Older stuff is a must read... (Score:1)
I donno if the checkbook is a good idea. Probably unmarked bills, nonsequential. Mabey have your grandmother go out and buy it.
Too expensive? (Score:5, Insightful)
Is there anything I didn't like about the book? Frankly, no. Some might complain that it is priced too high (it lists at USD50 for the softcover, and USD70 for the hardcover), but it is printed on acid-free paper, and the density of useful advice is such that it outstrips in value many works which cost half the price or less.
Taking a look at my paperback copy of Applied Cryptography, it's listed at $55, so I hardly consider that any more expensive. And I paid full cover price for this bugger, as opposed to getting it online for a song, like I should have.
I don't think Applied Cryptography had a hardcover edition available, at least of the Second Edition. I certainly may consider picking that thing up. Hopefully it'll be able to stick together for awhile.
And on another note, what isn't printed on acid-free paper these days? Aside from little paperback novels, etc. I thought that was all done away with.
Re:Too expensive? (Score:2)
I totally agree - AC2 was well worth the money. FWIW AC2 was available in hardcover - Amazon still sell it at an unpleasant 85USD!
Re:Too expensive? (Score:2)
Taking a look at my paperback copy of Applied Cryptography, it's listed at $55, so I hardly consider that any more expensive.
Of course, if you compare it to Secrets and Lies, which was sent in duplicate for free to anyone who wanted it, $50-70 (or even $30 for the paperback at Bookpool) is a lot more expensive. But I guess mailing out tons of free books isn't a very good business model these days...
Re:Too expensive? (Score:2)
Re:Too expensive? (Score:2)
Re:Too expensive? (Score:3, Informative)
http://www.cacr.math.uwaterloo.ca/hac/
and many other places.
Re:Too expensive? (Score:1)
At the very least... (Score:5, Funny)
Re:At the very least... (Score:5, Funny)
Hmmm, maybe the PATRIOT Act is a ploy by authors to make sure we BUY their books (with cash, natch...), instead of checking 'em out from libraries...
Applied Cryptography (Score:5, Funny)
Re:Applied Cryptography (Score:2)
Accessible? (Score:5, Funny)
I'd rather see a review like: "This book was so impenetrable that teams of scientists in academia and the NSA, working with the online computing grid will take many times the age of the universe to understand the first chapter alone."
Acid-free paper? (Score:4, Funny)
Before you worry about finding a storage medium which will survive for a long time, think about how long the information you're storing will be useful.
Re:Acid-free paper? (Score:2)
Re:Acid-free paper? (Score:1)
Depends on if Quantum Computers become practical in that timeframe. If they do, RSA (and a lot of other crypto algorithms) become useless.
Re: Quantum Computers will NOT make crypto obsolet (Score:2)
Um, no.
From the Crypto Mini-FAQ [mindspring.com]:
Q: Will quantum computers make all this crypto obsolete?
Not in our lifetimes. Quantum cryptography along a single fiber optic
strand has been demonstrated, and claims to offer provable security
in a certain narrow academic sense, like the one-time pad. But to be
practical, it has to be combined with conventional cryptography, in
which cas
Re: Quantum Computers will NOT make crypto obsolet (Score:1)
You will note that I said "become practical within that timeframe" and "if they do, then . . ". I'm well aware of the breakthroughs required to make that happen.
On a somewhat related note, (Score:1, Insightful)
Re:On a somewhat related note, (Score:1)
A very good straight forward implementation of most basic algorithms (addition, subtraction, multiplication, division) can be found in BigInteger class in Java source code (one that comes with the SDK). Basically they took word-for-word what's in the Knuth's The Art of Computer Programming Vol. 2, and implemented it in Java.
Re:On a somewhat related note, (Score:2)
But most people are not willing to read the background mathematical papers needed to understandard any resonablely terse comments.
Or have you read Discrete Weighted Transforms and Large-Integer Arithmetic by Richard Crandall and Barry Fagin? (And "How Fast Can We Multiply?" in Knuth's Art of Computer Programming vol. 2)
Re:On a somewhat related note, (Score:3, Insightful)
Did you write your own compiler? No, well have you read every line of gcc? Especially all of the complicated optimizer that makes the binary run faster? Even if yo
Re:On a somewhat related note, (Score:1)
A lot of things can happen in 10 years...
Also those are not some "temporary" optimizations. There are simply better (but more complex) methods of doing numerical things - so in 10 years, they'll still be faster.
AND, people will always find better uses for CPU power IF it is available (if you don't use it up by bloated code).
Can you say ray-traced true-live-movie-quality DOOM 7? (I'm sure that can bring down to its knees any computer we can come up with in the next 10 years).
Obvious code O(n^2) -- FFT is O(log(n)^2) (Score:1)
The trivial way to implement the multiplcation of 2 numbers within a BN library takes O(n^2) as compared with the FFT which I believe is O(log(n)^2).
Now, the constant factor in the complexity of FFT is rather large as it requires a bit of work to set up. So if you are multipling numbers with a few digits, it would be faster to use the O(n^2), however, if you are doing really large number work go with the FFT algo.
Re:Obvious code O(n^2) -- FFT is O(log(n)^2) (Score:2)
Naive bignum multiplication would be O(n^2), which is a good bit slower than O(n log n).
thanks for correcting me. (Score:1)
Your point is why I had included the complexity.
Definitive Crypto Books... (Score:4, Informative)
I can't comment on Practical Cryptography as Wiley haven't yet shipped my pre-ordered copy of the book, grumble.....
BUT I can recommed 2 books that any person interested in implementing cryptography should have on their shelf:
I like the joke at the bottom of the X.509 link (Score:5, Funny)
An engineer, a chemist, and a standards designer are stranded on a desert island with absolutely nothing on it. One of them finds a can of spam washed up by the waves.
The engineer says "Taking the strength of the seams into account, we can calculate that bashing it against a rock with a given force will open it up without destroying the contents".
The chemist says "Taking the type of metal the can is made of into account, we can calculate that further immersion in salt water will corrode it enough to allow it to be easily opened after a day".
The standards designer gives the other two a condescending look, gazes into the middle distance, and begins "Assuming we have an electric can opener...".
I've always thought... (Score:5, Funny)
What about HAC? (Score:5, Informative)
Applied Crypto is certainly a quality, wide-ranging tome on crypto. For years though, there have been a couple very good books with more implementation details. The Handbook of Applied Crypto from Menezes, et al comes immediately to mind. Either of the two books by Neal Koblitz are excellent. I also like to recommend Decrypted Secrets from Bauer. The Handbook of Applied Crypto is available as a free download from the author's site:
Re:What about HAC? (Score:1)
Re:What about HAC? (Score:1)
Handbook of Applied Cryptography (Score:5, Informative)
Since everyone is posting their favorite books... (Score:4, Interesting)
another book on cryptology (Score:4, Interesting)
It's fun reading!
about the book by schneier (Score:1)
For extra security... (Score:2)
A review on crypto or error correcting protocols? (Score:1)
"Invaluable" appears once in the summary and three more times in the review.
And not only do we discover that "[t]he book pulls no punches", we later learn that "Ferguson and Schneier are refreshingly frank, too."
I would hope that a book outstrips the value of those which cost half the price or less, so is this really a complement?
Fortuna ...? (Score:2)
From the table of contents of the book, it looks like it could be just another member of the Yarrow family.
Good discussions - lacking depth (Score:4, Informative)
The writing is clear and does a good job of presenting information, and doing that well for a dense subject like cryptography should not be underestimated. The book is strongly opinionated, and I think that is a strength since the authors try [and for the most part succeed] in explaining how those opinions were formed. The topics are fairly comprehensive, and the material seems to be well organized (from what I've read so far).
For the knowledgeable, it is a bit disappointing. I did not expect to learn tons of new stuff, but was still disappointed at the depth. In many ways, the book was only a half-notch deeper than reading Schneier's Cryptogram essays, where perhaps I was hoping for something more like his papers. The good use of footnotes and references helps offset things a little.
There were clearly areas where the authors were more interested in than others, often corresponding to previous work (CTR block-cipher mode, PRNG). Other areas were less inspired, for example in the MAC (message-authentication-code) chapter they offer the advice "Do not output any of the intermediate values." This sounds good at first glance, but it totally impractical except under special circumstances (if the MAC routine allows variable length messages, and almost all do, intermediate values can be calculated by simply feeding the parts of the message into the routine - thus this advice has no real world value).
Another nitpick, is that I would have liked to see the various "rules" and advice formulated into check lists. That would have made the book much more valuable for crypto system designers, be they novice or expert.
On the balance, I feel that the book is worthwhile to anyone interested in the subject of cryptography, or who has to use [or design, test] a system that has cryptography. It won't make you an expert (funny how some people still think reading a book could do this), but at least it raises an awareness of the types of problems that derail cryptographic systems designs. It is easy to read and informative.
You got the author's name wrong ... (Score:1)
Crypto/Schmypto (Score:1)
Re:svefg cbfg (Score:1)
(But your genius will be unappreciated by the Slashdot moderators...)
Re:My new fangled encryption scheme (Score:3, Interesting)
There are two problems with this, first is the relatively small number of Irrational numbers that are likely to be used (unless there is a large and easy to mine font of these I am not aware of).
The source of security of most encryption systems is that the "random streams" created by the initial key are extraordinarially large.
Changing the starting point in 1 given or even a handful of give
Re:Better choices for t. (Score:2, Informative)
The fact that there are many t's and z's to choose from doesn't change the fact that you still need a secure channel to transmit t and z from Alice to Bob. And if you have that secure channel, what's the point of the encryption? Why not just pass the plaintext over the secure channel?
bad example. (Score:1)
Your example doesn't make sence. If you use a one-time-pad, you've only doubled the time frame (if you've recieved the OTP in the secure channel). It would make more sence to transmit a symetric key during the secure channel, and then use it to extend the time frame.
As far as yo
Re:Thta book isn't entirely necessary... (Score:1)
^^^^
Back to the drawing board for you. Seems your encryption doesn't maintain data integrity.
Re:Thta book isn't entirely necessary... (Score:1)
Re:Thta book isn't entirely necessary... (Score:2)
Re:Handbook on Applied Cryptography (Score:2)
No. The former is by Schneier, the latter by Menezes et al., and is somewhat more mathematical. Both are very good, but unless you have good maths, the former is more accessible, and not so much hard work. Conversely, if you can handle the latter, the maths in the former