Free Republic
Browse · Search
News/Activism
Topics · Post Article

Skip to comments.

Did NSA Put a Secret Backdoor in New Encryption Standard?
Bruce Schneier ^ | November 15, 2007 | Bruce Schneier

Posted on 12/17/2007 2:02:05 PM PST by antiRepublicrat

Random numbers are critical for cryptography: for encryption keys, random authentication challenges, initialization vectors, nonces, key-agreement schemes, generating prime numbers and so on. Break the random-number generator, and most of the time you break the entire security system. Which is why you should worry about a new random-number standard that includes an algorithm that is slow, badly designed and just might contain a backdoor for the National Security Agency.

Generating random numbers isn't easy, and researchers have discovered lots of problems and attacks over the years. A recent paper found a flaw in the Windows 2000 random-number generator. Another paper found flaws in the Linux random-number generator. Back in 1996, an early version of SSL was broken because of flaws in its random-number generator. With John Kelsey and Niels Ferguson in 1999, I co-authored Yarrow, a random-number generator based on our own cryptanalysis work. I improved this design four years later -- and renamed it Fortuna -- in the book Practical Cryptography, which I co-authored with Ferguson.

The U.S. government released a new official standard for random-number generators this year, and it will likely be followed by software and hardware developers around the world. Called NIST Special Publication 800-90 (.pdf), the 130-page document contains four different approved techniques, called DRBGs, or "Deterministic Random Bit Generators." All four are based on existing cryptographic primitives. One is based on hash functions, one on HMAC, one on block ciphers and one on elliptic curves. It's smart cryptographic design to use only a few well-trusted cryptographic primitives, so building a random-number generator out of existing parts is a good thing.

But one of those generators -- the one based on elliptic curves -- is not like the others. Called Dual_EC_DRBG, not only is it a mouthful to say, it's also three orders of magnitude slower than its peers. It's in the standard only because it's been championed by the NSA, which first proposed it years ago in a related standardization project at the American National Standards Institute.

The NSA has always been intimately involved in U.S. cryptography standards -- it is, after all, expert in making and breaking secret codes. So the agency's participation in the NIST (the U.S. Commerce Department's National Institute of Standards and Technology) standard is not sinister in itself. It's only when you look under the hood at the NSA's contribution that questions arise.

Problems with Dual_EC_DRBG were first described in early 2006. The math is complicated, but the general point is that the random numbers it produces have a small bias. The problem isn't large enough to make the algorithm unusable -- and Appendix E of the NIST standard describes an optional work-around to avoid the issue -- but it's cause for concern. Cryptographers are a conservative bunch: We don't like to use algorithms that have even a whiff of a problem.

But today there's an even bigger stink brewing around Dual_EC_DRBG. In an informal presentation (.pdf) at the CRYPTO 2007 conference in August, Dan Shumow and Niels Ferguson showed that the algorithm contains a weakness that can only be described a backdoor.

This is how it works: There are a bunch of constants -- fixed numbers -- in the standard used to define the algorithm's elliptic curve. These constants are listed in Appendix A of the NIST publication, but nowhere is it explained where they came from.

What Shumow and Ferguson showed is that these numbers have a relationship with a second, secret set of numbers that can act as a kind of skeleton key. If you know the secret numbers, you can predict the output of the random-number generator after collecting just 32 bytes of its output. To put that in real terms, you only need to monitor one TLS internet encryption connection in order to crack the security of that protocol. If you know the secret numbers, you can completely break any instantiation of Dual_EC_DRBG.

The researchers don't know what the secret numbers are. But because of the way the algorithm works, the person who produced the constants might know; he had the mathematical opportunity to produce the constants and the secret numbers in tandem.

Of course, we have no way of knowing whether the NSA knows the secret numbers that break Dual_EC-DRBG. We have no way of knowing whether an NSA employee working on his own came up with the constants -- and has the secret numbers. We don't know if someone from NIST, or someone in the ANSI working group, has them. Maybe nobody does.

We don't know where the constants came from in the first place. We only know that whoever came up with them could have the key to this backdoor. And we know there's no way for NIST -- or anyone else -- to prove otherwise.

This is scary stuff indeed.

Even if no one knows the secret numbers, the fact that the backdoor is present makes Dual_EC_DRBG very fragile. If someone were to solve just one instance of the algorithm's elliptic-curve problem, he would effectively have the keys to the kingdom. He could then use it for whatever nefarious purpose he wanted. Or he could publish his result, and render every implementation of the random-number generator completely insecure.

It's possible to implement Dual_EC_DRBG in such a way as to protect it against this backdoor, by generating new constants with another secure random-number generator and then publishing the seed. This method is even in the NIST document, in Appendix A. But the procedure is optional, and my guess is that most implementations of the Dual_EC_DRBG won't bother.

If this story leaves you confused, join the club. I don't understand why the NSA was so insistent about including Dual_EC_DRBG in the standard. It makes no sense as a trap door: It's public, and rather obvious. It makes no sense from an engineering perspective: It's too slow for anyone to willingly use it. And it makes no sense from a backwards-compatibility perspective: Swapping one random-number generator for another is easy.

My recommendation, if you're in need of a random-number generator, is not to use Dual_EC_DRBG under any circumstances. If you have to use something in SP 800-90, use CTR_DRBG or Hash_DRBG.

In the meantime, both NIST and the NSA have some explaining to do.


TOPICS: Business/Economy; Government
KEYWORDS: encryption; microsoft; nsa; random
Navigation: use the links below to view more comments.
first 1-5051-100101-111 next last
Don't panic, he's not going tin foil hat. Read the whole thing and see the reasoned discussion.

But what makes this interesting is that Microsoft is including this random number generator in Vista SP1.

1 posted on 12/17/2007 2:02:06 PM PST by antiRepublicrat
[ Post Reply | Private Reply | View Replies]

To: antiRepublicrat

Is a bear Catholic?


2 posted on 12/17/2007 2:05:31 PM PST by NonValueAdded (Fred Dalton Thompson for President)
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat

SHHHHH! Dammit!


3 posted on 12/17/2007 2:09:43 PM PST by Elpasser
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat
81372659

My random number for the day. See, it's real easy.

4 posted on 12/17/2007 2:10:31 PM PST by Rudder
[ Post Reply | Private Reply | To 1 | View Replies]

To: rdb3; Calvinist_Dark_Lord; GodGunsandGuts; CyberCowboy777; Salo; Bobsat; JosephW; ...

5 posted on 12/17/2007 2:10:43 PM PST by ShadowAce (Linux -- The Ultimate Windows Service Pack)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Rudder
81372659

My random number for the day. See, it's real easy.

The bad news is I just found the backdoor of your random number and I'm currently in ur kitchen eatin ur oatmeals.
6 posted on 12/17/2007 2:12:42 PM PST by mysterio
[ Post Reply | Private Reply | To 4 | View Replies]

To: Rudder

probably NOT random, as it has no repeated numbers.


7 posted on 12/17/2007 2:16:03 PM PST by SpinnerWebb (Islam ... If you can't join them, beat them.)
[ Post Reply | Private Reply | To 4 | View Replies]

To: antiRepublicrat

8 posted on 12/17/2007 2:17:13 PM PST by SeafoodGumbo
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat

Bruce Schneier rules at sniffing out snake oil.


9 posted on 12/17/2007 2:19:10 PM PST by Bobalu (I guess I done see'd that varmint for the last time....)
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat

Anyone ever use this encryption? I’ve thought about using it and I wonder if it’s any good.

http://www.meganet.com


10 posted on 12/17/2007 2:22:16 PM PST by Free Vulcan (Friends don't let friends vote Huckabee)
[ Post Reply | Private Reply | To 1 | View Replies]

To: SeafoodGumbo
Child abuse!

Wait, there is a second edition. Arrrg, Sandy Clause ate all my money! Always next month.

11 posted on 12/17/2007 2:24:10 PM PST by fireforeffect (A kind word and a 2x4, gets you more than just a kind word.)
[ Post Reply | Private Reply | To 8 | View Replies]

To: antiRepublicrat

Hasn’t cryptography long been considered regulated “weaponry”?


12 posted on 12/17/2007 2:28:43 PM PST by weegee (If Bill Clinton can sit in on Hillary's Cabinet Meetings then GWBush should ask to get to sit in too)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Free Vulcan

“Anyone ever use this encryption?”

I use GnuPG.


13 posted on 12/17/2007 2:28:54 PM PST by GovernmentIsTheProblem (The GOP is "Whig"ing out.)
[ Post Reply | Private Reply | To 10 | View Replies]

To: antiRepublicrat

Wouldn’t surprise me.


14 posted on 12/17/2007 2:30:52 PM PST by pray4liberty (The Truth sinks people whose only recourse is lies.)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Rudder

8675309


15 posted on 12/17/2007 2:32:33 PM PST by mwyounce
[ Post Reply | Private Reply | To 4 | View Replies]

To: antiRepublicrat
But what makes this interesting is that Microsoft is including this random number generator in Vista SP1.

Is anyone surprised by that? Apparently, Microsoft has never been able to hire a decent cryptographer.

16 posted on 12/17/2007 2:40:07 PM PST by zeugma (Hillary! - America's Ex-Wife!)
[ Post Reply | Private Reply | To 1 | View Replies]

To: mwyounce

4 8 15 16 23 42


17 posted on 12/17/2007 2:40:12 PM PST by Michael Barnes
[ Post Reply | Private Reply | To 15 | View Replies]

To: SpinnerWebb

Right. I threw out two zeros because I don’t like that number.


18 posted on 12/17/2007 2:44:20 PM PST by Rudder
[ Post Reply | Private Reply | To 7 | View Replies]

To: antiRepublicrat
From the introduction to Schnier's book...

"There are two kinds of cryptography in the world. There is the kind that will keep your kid sister from reading your mail, and there is the kind that will keep major governments from reading your mail. This book is about the latter."

Probably the best technical book introduction ever written.

19 posted on 12/17/2007 2:44:51 PM PST by antinomian (Show me a robber baron and I'll show you a pocket full of senators.)
[ Post Reply | Private Reply | To 1 | View Replies]

To: SpinnerWebb

What are the chances of that?


20 posted on 12/17/2007 2:45:46 PM PST by kinsman redeemer (The real enemy seeks to devour what is good.)
[ Post Reply | Private Reply | To 7 | View Replies]

To: mwyounce

Congratulations! You have a BINGO.


21 posted on 12/17/2007 2:47:04 PM PST by Rudder
[ Post Reply | Private Reply | To 15 | View Replies]

To: mysterio
I'm currently in ur kitchen eatin ur oatmeals.

LOL! And I was just going to make some granola.

22 posted on 12/17/2007 2:49:00 PM PST by Rudder
[ Post Reply | Private Reply | To 6 | View Replies]

To: weegee
Hasn’t cryptography long been considered regulated “weaponry”?

Yes, thus the origins of the "munitions t-shirt", described briefly here.

23 posted on 12/17/2007 2:50:47 PM PST by DuncanWaring (The Lord uses the good ones; the bad ones use the Lord.)
[ Post Reply | Private Reply | To 12 | View Replies]

To: NonValueAdded
Is a bear Catholic?

Not me, I'm Episcopalian.

24 posted on 12/17/2007 2:52:01 PM PST by AndyTheBear (Disastrous social experimentation is the opiate of elitist snobs.)
[ Post Reply | Private Reply | To 2 | View Replies]

To: antiRepublicrat

***What Shumow and Ferguson showed is that these numbers have a relationship with a second, secret set of numbers that can act as a kind of skeleton key.***

I’d sure be curious to see their math where they showed this relationship. And, I’d like to know how they are certain that a second set of numbers exist or if this is just a case of we thought and wouldn’t you know the math works out.


25 posted on 12/17/2007 2:56:42 PM PST by Lord_Calvinus
[ Post Reply | Private Reply | To 1 | View Replies]

To: mwyounce

Did you get “that number off the wall”?


26 posted on 12/17/2007 2:57:09 PM PST by ROTB (Front Runner=rich guy who doesn't hate evil and strives to offend no one, & WILL SELL YOU OUT.)
[ Post Reply | Private Reply | To 15 | View Replies]

To: antiRepublicrat
It doesn’t matter.

There are more geniuses, per square foot, at the NSA than any place on earth.

They don’t need a back door.

27 posted on 12/17/2007 2:59:23 PM PST by Beckwith (Dhimmicrats and the liberal media have chosen sides -- Islamofascism)
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat
23,292,079,583,053

OK here is my number
it is the product of 2 primes
A common encryption / decryption
algorithm depends on a public key
of a long number which is the product
of 2 long prime numbers

Find the 2 primes and you get the Kewpie doll

28 posted on 12/17/2007 3:00:25 PM PST by HangnJudge
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat

I found the whole article rather cryptic...


29 posted on 12/17/2007 3:01:43 PM PST by mikrofon (Tales From the Cryptologist)
[ Post Reply | Private Reply | To 1 | View Replies]

To: antiRepublicrat
Absolutely not. It is entirely impossible for the NSA to read my

[Drill, f'Petessake, your car is parked in the General's spot. Move it, willya?]

Oops. Gotta go...

30 posted on 12/17/2007 3:02:56 PM PST by Billthedrill
[ Post Reply | Private Reply | To 1 | View Replies]

To: Free Vulcan

http://www.google.com/search?hl=en&q=meganet+snake+oil&btnG=Google+Search


31 posted on 12/17/2007 3:04:02 PM PST by Bobalu (I guess I done see'd that varmint for the last time....)
[ Post Reply | Private Reply | To 10 | View Replies]

To: NonValueAdded
Is a bear Catholic?

More importantly, does it pope in the woods?

32 posted on 12/17/2007 3:04:58 PM PST by Fresh Wind (Scrape the bottom, vote for Rodham!)
[ Post Reply | Private Reply | To 2 | View Replies]

To: antiRepublicrat

Is there any reason to only use one random number generator? If two ‘random’ generators are independent, then the XOR of them will be at least as ‘random’ as the better of the two. Adding in an extra random generator might not help a whole lot, but it couldn’t hurt and it would at least make attacks on the primary one more difficult.


33 posted on 12/17/2007 3:22:17 PM PST by supercat (Sony delenda est.)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Free Vulcan
http://www.meganet.com

"Onetime pad wanna-be"

34 posted on 12/17/2007 3:22:58 PM PST by The Duke (I have met the enemy, and he is named 'Apathy'!)
[ Post Reply | Private Reply | To 10 | View Replies]

To: HangnJudge
Find the 2 primes and you get the Kewpie doll

http://www.acme.com/software/factor/

23,292,079,583,053 =
3355067 * 6942359

Anyone who can find the primes, can
decrypt your messages in this scheme

Generally, if ya got a lot of computer
you can break darn near any scheme


35 posted on 12/17/2007 3:22:59 PM PST by HangnJudge
[ Post Reply | Private Reply | To 28 | View Replies]

To: HangnJudge

To be fair, the article is about how you generate p and q to begin with. In other words, if my mission is to figure out what your two primes are that multiply out to 23,292,079,583,053, then, sure, I can try to brute-force my way through all 14-digit primes, but if you used some kind of flawed technique for picking your two primes in the first place, then I can save myself a whole ton of work.

It’s kind of like how I can always beat you at rocks-paper-scissors if I know you always pick rock.


36 posted on 12/17/2007 3:23:48 PM PST by Omedalus
[ Post Reply | Private Reply | To 28 | View Replies]

To: HangnJudge

Would that be Factorization: 6942359 * 3355067?

Jack


37 posted on 12/17/2007 3:28:09 PM PST by JackOfVA
[ Post Reply | Private Reply | To 28 | View Replies]

To: Omedalus
To be fair, the article is about how you generate p and q to begin with. In other words, if my mission is to figure out what your two primes are that multiply out to 23,292,079,583,053, then, sure, I can try to brute-force my way through all 14-digit primes, but if you used some kind of flawed technique for picking your two primes in the first place, then I can save myself a whole ton of work.

It’s kind of like how I can always beat you at rocks-paper-scissors if I know you always pick rock.

Bingo

38 posted on 12/17/2007 3:28:21 PM PST by HangnJudge
[ Post Reply | Private Reply | To 36 | View Replies]

To: JackOfVA
Would that be Factorization: 6942359 * 3355067?


39 posted on 12/17/2007 3:30:41 PM PST by HangnJudge
[ Post Reply | Private Reply | To 37 | View Replies]

To: HangnJudge

“Generally, if ya got a lot of computer you can break darn near any scheme”

A computer, and time. Lots and lots and lots and lots and lots of time. :)

The point of digital encryption techniques isn’t to make a code unbreakable. There’s no such thing as a literally unbreakable code. Rather, the point is that, without some particular piece of information (such as a key), breaking the code is so computationally complex that the expected time it would require to break the code, given “reasonable” computing resources (more on that later), is greater than the lifetime of the value of the message itself.

As for what makes computing resources “reasonable” given the desired encryption strength, that depends on what you want to protect. Contrary to most tinfoil-hatters out there, the NSA is not going to pool the combined supercomputing resources of every federal lab in order to crack their way into your porn archive. They may, however, do so in order to acquire China’s nuclear launch codes - or, more to the point, the Chinese may do so to us.


40 posted on 12/17/2007 3:31:27 PM PST by Omedalus
[ Post Reply | Private Reply | To 35 | View Replies]

To: weegee

Hasn’t cryptography long been considered regulated “weaponry”?

Yes. they are categorized as munitions.

I was once in the business of developing commercial encryption devices. Every design to be considered for export had to be approved by the NSA.

I can guarantee you that every approved encryption system has a backdoor the NSA can use, or they feel that they don’t need one as the encryption is easy enough to break without it.


41 posted on 12/17/2007 3:40:14 PM PST by EEDUDE
[ Post Reply | Private Reply | To 12 | View Replies]

To: LonePalm

ping for your list.


42 posted on 12/17/2007 3:58:14 PM PST by ASA Vet
[ Post Reply | Private Reply | To 1 | View Replies]

To: Michael Barnes

Can you believe we have to wait almost a whole year from last season until the new season starts? What is up with that?


43 posted on 12/17/2007 4:13:38 PM PST by LivingNet
[ Post Reply | Private Reply | To 17 | View Replies]

To: SeafoodGumbo

That is so cool! In a geek sort of way.


44 posted on 12/17/2007 4:24:54 PM PST by antiRepublicrat
[ Post Reply | Private Reply | To 8 | View Replies]

To: weegee
Hasn’t cryptography long been considered regulated “weaponry”?

It was a long time ago, but the cat came out of the bag. Students all over the world were learning how to do cryptography at their universities, but we couldn't export anything written here.

45 posted on 12/17/2007 4:28:15 PM PST by antiRepublicrat
[ Post Reply | Private Reply | To 12 | View Replies]

To: SeafoodGumbo

My kid cracked your kid’s code...


46 posted on 12/17/2007 4:29:12 PM PST by AmericaUnited
[ Post Reply | Private Reply | To 8 | View Replies]

To: AmericaUnited
My kid cracked your kid’s code...

That's what my kid wants yours to think. Mwuhahahahhahaa.

47 posted on 12/17/2007 4:47:39 PM PST by SeafoodGumbo
[ Post Reply | Private Reply | To 46 | View Replies]

To: antiRepublicrat

is there a ping list for this stuff? if so, please put me on.

i recently read an article about how Google was used to break a password hash (MD5?). it seems to me that distributed computing is a poor man’s way to approach some of these tasks.


48 posted on 12/17/2007 4:55:08 PM PST by tired1 (responsibility without authority is slavery!)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Omedalus
There’s no such thing as a literally unbreakable code.

A simple one time pad is 100% unbreakable no matter how much time or computer power you have.

49 posted on 12/17/2007 5:00:35 PM PST by Reeses (Leftism is powered by the evil force of envy.)
[ Post Reply | Private Reply | To 40 | View Replies]

To: Reeses

Yes fine, except for a one-time pad. :)


50 posted on 12/17/2007 5:11:23 PM PST by Omedalus
[ Post Reply | Private Reply | To 49 | View Replies]


Navigation: use the links below to view more comments.
first 1-5051-100101-111 next last

Disclaimer: Opinions posted on Free Republic are those of the individual posters and do not necessarily represent the opinion of Free Republic or its management. All materials posted herein are protected by copyright law and the exemption for fair use of copyrighted works.

Free Republic
Browse · Search
News/Activism
Topics · Post Article

FreeRepublic, LLC, PO BOX 9771, FRESNO, CA 93794
FreeRepublic.com is powered by software copyright 2000-2008 John Robinson