How is NSA breaking so much crypto?
freedom-to-tinker.com
freedom-to-tinker.com
can someone explain to me why this cant be fixed over night. im no crypto expert, but
" If a client and server are speaking Diffie-Hellman, they first need to agree on a large prime number with a particular form. "
why can't you just switch the large prime number and then continue on sending encrypted data?
For some protocols, this is fine. For other protocols, it's a problem. IIRC one variant of the triple-handshake attach on TLS involved tricking the client into using a weak group.
From memory (too lazy to look up all the details right now), the issue is that the order of the multiplicative group mod p is p-1. If p is a prime greater than 3 (which it is in standard Diffie-Hellman), then p-1 is certainly not prime, which means that the multiplicative group will have subgroups of varying sizes. Some subgroups might be small. If one party sends a public share in a small subgroup, then bad things can happen.
Unfortunately, validating the DH parameters is too slow to do with each handshake. So either you carefully design the protocol to avoid this problem (which is certainly doable in many case), you use a well-known group (which should be fine as long as the group is large enough), or you use something like ECDH. ECDH is nice because the index calculus attacks don't work and you can have a nice group structure.
Aside: While it's possible for an EC group to have a prime order, for various tricky reasons, the better modern EC curves deliberately have an order that's h*p for some small h (h is called the "cofactor" and h=4 or h=8 are common) and a large prime p. This gives some nifty benefits, but it requires a bit of care under some circumstances.
Isn't the all promise of cryptography predicated on the idea that you can impose exponential effort by merely incurring polynomial effort?
See https://tools.ietf.org/html/draft-ietf-tls-tls13-09#page-49
https://www.ietf.org/archive/id/draft-bhargavan-tls-session-...
I'm not quite sure why this Internet-Draft expired without a replacement or if this work is still continuing somewhere in the TLS WG.
Oh, because it was issued as an RFC!
What you are saying seems to only make sense for MITM attacks?
https://secure-resumption.com/
although that site seems to be down right now.
While people can agree that this is ultimately a flaw in the design of the TLS protocol, in some contexts, it's still a reason that it matters whether your connection with an arbitrary site is using a safe Diffie-Hellman group or not.
Getting rid of old software is hard, people don't know, then there isn't enough incentive to upgrade, then you need to support legacy clients so you still keep old crypto support (which now means that you can attack clients which support stronger crypto through various downgrade/fallback attacks) etc..
if i read this article correctly, if we could update millions of computers in a short period of time with a new prime number that would be enough to solve this problem in the short term - long term all we need to do is change the prime number every X number of months, were X would require billions (as opposed to hundreds of millions) of dollars to solve
Millions more weren't. Shitty routers (did you know WEMO devices still run an old Linux 2.6 series kernel? How about Cisco firewall appliances? Yup). Home automation systems. Boxes people have half forgotten about. Systems running software from vendors who won't support you if you run anything more than half a decade old.
There are probably 1000's of various DH implementations that are utter crap, it's not like you can release a single advisory and make big news about it.
https://en.wikipedia.org/wiki/Safe_prime
You can contrast
openssl dhparam -5 2048
which generates 2048-bit Diffie-Hellman parameters, to openssl genrsa 4096
which generates a 4096-bit RSA key (containing two 2048-bit primes) and note that the second is dramatically faster than the first. On-the-fly DH parameter generation is really slow.However, generating 1024-bit parameters is probably fast enough to do on launch or install. Under the authors' estimates this might be fairly safe today because the adversary will have to spend many millions of dollars to attack your individual service (and you could change the parameters once a day or something if you wanted). But I think the authors agreed that large predistributed parameters make a better tradeoff for most cases.
There is an RFC about to issue listing such parameters
https://datatracker.ietf.org/doc/draft-ietf-tls-negotiated-f...
Edit: I possibly shouldn't refer to "the authors" in the third person here, because you are the lead author.
Further edit: "Close to a minute" is actually not a bad estimate, but the variance is very high! So it can easily be considerably worse.
hobbes@namagiri:~$ time openssl dhparam -5 2048
Generating DH parameters, 2048 bit long safe prime, generator 5
This is going to take a long time
............[snip]......++*++*
-----BEGIN DH PARAMETERS-----
MIIBCAKCAQEAzshMWp3IBjMW5Aia2wJOvA2EBY32Mn2fMXzlyFDklnRUg8ff/19A
YWbRA4RAXrBMxoXEH1LVVpm5l89PGZ3DzjDafuNzNskgUhcAewUXXMQdkOFnPHYc
5F7+3DS8981Q0Q05qscBb26YGb2XaoJygyVj+B87NTvdAPzNU4fW5DyCuxhf5eov
ZeZwcC4KZ31Lr7enFcFBjTjxQxW88pP4YhiNYQ1fsFARGJT0X7ksOlRVWFrODu6b
nq0Ye/UWe0WB1zzmxz66ZujAwRwAgfmQZd7rILJqg68sxBeg88FlXJUeKfPL/bIT
KOl1LhiHr/HkUBfgZRahK0MGcthwiLdFZwIBBQ==
-----END DH PARAMETERS-----
real 0m37.073s
user 0m33.464s
sys 0m2.924s
hobbes@namagiri:~$
Edit: second run: real 0m35.362s
user 0m31.992s
sys 0m2.880s
Would somebody post the steps I should use to make my own OpenSSH sshd(s) use non-standard DH parameters? Do I need to do anything to my clients?Any of the sizes' most recent 128 parameters can be downloaded in SSH moduli format, e.g. https://2ton.com.au/dhparam/4096/ssh
https://stribika.github.io/2015/01/04/secure-secure-shell.ht...
Indeed, the guide recommends generating new contents for the /etc/ssh/moduli file (IFF you keep `diffie-hellman-group-exchange-sha256` enabled).
See the manpage moduli(5).
Hm, the format of the existing file does not match the format of what `openssl dhparam` generated. I'll research...
However, the paper authors say
"If you use SSH, you should upgrade both your server and client installations to the most recent version of OpenSSH, which prefers Elliptic-Curve Diffie-Hellman Key Exchange."
That might ultimately be a simpler and safer course unless you have to deal with old clients that you don't have the ability to upgrade.
Generating DH parameters, 2048 bit long safe prime, generator 5
This is going to take a long time
Haha! It also made my CPU sweat nicely. I Ctrl+C^d after it ran for nearly 10 minutes with no sign of stopping though :( I see what you mean when you guys say it isn't feasible on every install of everything and why these are reused. I do think software maintainers should make an effort to do this regularly when new patches are released.This actually opens up a new question in my mind: how does Open Source Software manage to keep these keys secret? Off to google...
The secrets used in Diffie-Hellman are chosen by the participants in the key exchange at the moment that it's used.
https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exc...
Here, the dhparam command is creating g and p (well, you're supplying g as a command-line argument, and the command is choosing p); those are the public parameters which can be published anywhere, can be given to anyone, and can be re-used by multiple sites and services (although the last case makes life easier for attackers if the p value is too small, as the researchers indicate it is for some popular Internet standards and software configurations).
When a Diffie-Hellman key exchange happens, the two sites agree (not necessarily in a secret way, indeed normally not in a secret way) on what g and p to use, and then one site secretly chooses a, the other side secretly chooses b, and they do the math that results in both sides knowing the same combined secret without other parties being able to determine it. Only a, b, and the resulting combined secret g^ab mod p are confidential; g and p aren't.
Diffie-Hellman can also provide forward secrecy because you can deliberately forget what values of a and b you used on a particular occasion, and then you can't reconstruct them (unless you can compute discrete logarithms, which is supposed to be difficult). That's not true for key exchange using RSA for confidentiality, where, if you still have the private key, you can still read your messages that were sent to you in the past using that private key.
Ciphersuites in TLS that use Diffie-Hellman in an ephemeral way ("DHE") will still use RSA, but for identifying the server (and optionally the client) and confirming that no man-in-the-middle attack has happened. So, they only use RSA for signatures, not for confidentiality, and they still get forward secrecy if they forget the DH private values associated with individual sessions. (Some servers use the same b value for multiple incoming connections, which reduces the degree of forward secrecy they get: if someone hacked them or seized their server while it still contained a particular b value, that person could decrypt previously recorded TLS sessions with that server that used the same b value.)
Diffie-Hellman involves four numbers, which are called g, p, a, and b (and which are used to calculate other numbers).
g and p are public, and are often used "for the long term" (including sharing g and p values between different Internet sites and services). The researchers found that the problem is that a lot of sites use the same p values, and the ones they use are too small, so that there is a single calculation that a government can do which allows them to break DH that uses those particular p values. Although this calculation is phenomenally expensive, it seems likely that NSA did it several years ago.
a and b are private and must remain secret. Commonly a different a and b are chosen each time Diffie-Hellman is used (like for each new connection or session with an Internet service).
Diffie-Hellman provides a property called forward secrecy because it allows two ends of a connection to derive a session key (which gets calculated using information derived from g, p, a, and b, and gets then used as a key for some other cryptosystem, normally some form of AES today, but in theory it could be anything) but then later "forget" what the session key was and how it was derived. Unlike other ways of doing key exchange, when the parties choose to "forget" their session key and associated information this way, they no longer have a way to recover or reconstruct it!
This is useful because, for example, if someone hacks the computer of someone who was using protocols with ephemeral DH, the computer likely won't contain information that could be used to reconstruct the session key and decrypt old communications. (That's assuming that the software scrubs key material from memory when it's no longer needed... which might not always be true.)
Change is a bitch. As are proprietary and one-off updating schemes.
Then the protocol would have to be rewritten and the change would not be backwards compatible.
GCHQ and Belgacom spring to mind:
http://www.spiegel.de/international/europe/british-spy-agenc...
Let's have a show of hands. Anyone got unencrypted private keys on their machine or on their server? How hard is it to steal those?
http://security.stackexchange.com/questions/25437/what-issue...
http://www.symantec.com/connect/blogs/how-attackers-steal-pr...
No, because nobody would do that and the NSA has no legal authority with which to force that. Companies wouldn't agree to this because they have everything to lose and nothing to gain. It's not like the NSA could even offer them favors in exchange, as the entire thing is ultra-classified. Also there's exactly zero chance this would ever be able to be kept secret. Companies can't even keep their products secret for the few months it takes from prototypes to launch, there's no way in hell the NSA would trust them to keep this secret for years. The first sys admin forced to do this would instantly talk about it.
> some other means (man-in-the-middle attacks, server backdoors, hacking vulnerable software) to bypass the encryption entirely
The article talks about this. That's definitely possible, but it's much more targetted and doesn't fit the scale that the Snowden leaks suggested the NSA was achieving.
Not claiming I'm well read up on this but wasn't a big part of the leaks that companies were cooperating with the NSA in secret?
http://www.wired.com/2014/01/how-the-us-almost-killed-the-in...
"Gellman wanted to be the first to expose a top-secret NSA program called Prism. Snowden’s files indicated that some of the biggest companies on the web had granted the NSA and FBI direct access to their servers, giving the agencies the ability to grab a person’s audio, video, photos, emails, and documents."
However there is none of that for any of the other companies listed under Prism. Later leaks from Snowden suggest that the companies listed in Prism did not know they were part of Prism (places where inter-dc traffic was being spliced, that sort of thing).
Also just practically speaking with how fast companies rise & fall in this area doing this on a per-company basis wouldn't scale. Like when would you expect the NSA to approach, say, WhatsApp? Or Snapchat?
The evidence about companies cooperating with NSA on mass surveillance came out in the first decade of the 2000s, e.g., http://www.salon.com/2006/06/21/att_nsa/ and https://en.wikipedia.org/wiki/Room_641A
You might say the same thing about every social engineering victim ever. Nothing to gain, why do they help? Someone asked for help / seemed like the had the authority / was afraid for no reason.
Additionally, from my experience, monitoring after decryption isn't too hard to pull off. It takes a lot of time, money, and expertise to secure the inside and egress of the network and there is very little pressure on most companies to exert themselves to defend at those layers. Further, most networks aren't properly segmented and the attacks that tend to gain access to one machine (like a windows or mac laptop) on a network can be pivoted to access more restricted places. Given how open companies tend to be (practicing zero opsec), it's even very easy to know who to attack and have reasonable estimations about their machine's worth inside a network.
This is literally the most breathtakingly naive comment I have ever read on HN.
Then, they pay them too. Many companies, esp govt contractors, were more than happy to help for tens of millions.
These cryptanalytic capabilities are mostly relevant for servers hosted outside the US, I'd wager.
https://theintercept.com/2015/09/28/death-athens-rogue-nsa-o...
The scale out of the NSA capabilities may have become an issue -- adversaries have figured out that the US knows too much, as people get blown up when they pick up the phone.
DHE-RSA-AES128-GCM-SHA256
DHE-RSA-AES128-SHA
ECDHE-RSA-AES128-GCM-SHA256
ECDHE-RSA-AES128-SHA
Personally I use the shorter "strong" config off cipherli.stweakdh.org recommended 43, and cipherlist.st 16. cipherlist.st was a subset of the weakdh.org list.
Can someone explain to me what the authors mean by "cracking" a prime? Is the difficulty of this related to the difficulty factoring a composite number? The language used is annoyingly imprecise.
Edit: Question was already asked by smegel, and has some useful answers.
In theory the NSA could enumerate ginormous rainbow tables for a large set of secret keys.
Perhaps someone else on HN can provide a more detailed description of the suspected attack?
Edit: the responses to smegel's question below seem much mor e thorough and accurate than mine!
I think the kind of precomputation you envision here is still too hard to do because the number of possible DH secrets is still much too big to examine all of them by precomputation!
From http://www.cisco.com/en/US/docs/ios-xml/ios/sec_conn_ikevpn/...:
<< Diffie-Hellman--A public-key cryptography protocol that allows two parties to establish a shared secret over an unsecure communications channel. Diffie-Hellman is used within IKE to establish session keys. It supports ==> 768-bit (the default) <==, 1024-bit, 1536-bit, 2048-bit, 3072-bit, and 4096-bit DH groups. It also supports a 2048-bit DH group with a 256-bit subgroup, and 256-bit and 384-bit elliptic curve DH (ECDH). Cisco recommends using 2048-bit or larger DH key exchange, or ECDH key exchange. >>
Malice or incompetence? (or crappy hardware that needs help to not be slow?)
The recommendation is correct so...
https://datatracker.ietf.org/doc/draft-ietf-tls-negotiated-f...
As a result, that draft proposes using specific much larger parameters, on the basis of scaling considerations for the attacker. I think the authors of this paper endorse this solution.
(It's OK in general if you share parameters with someone else, it just means that an attacker who can do this precomputation for those parameters gets to attack both of your DH sessions as a result.)
Inspired me to write a little tool to download all referenced pdfs from any given pdf: https://github.com/metachris/pdf-link-extractor
Also the latest openssh package warns against Diffie hellman ssh keys now we know why they warn us.
I for one welcome the coming arrival of ECDH over curve25519 in TLS everywhere.
(And I really hope that comes to pass.)
Is there any chance that ECC is vulnerable to similar issues with static universally agreed upon constants. In ECC these are curves, and is it feasible to "pre-crack" a curve? Or is the space so huge in this case that it would take millions of years of compute time to do so?
Someone who knows ECC math better than I do would have to answer this one.
Also, remember: this isn't a fatal flaw in all of Diffie Hellman. It's a variant of a well-known attack that makes it economical to attack 1024 bit DH, not merely plausible. So far as anyone knows, it does nothing to help attack 2048 bit DH.
Note the qualifications around (b). Just any QC would not do... it would have to (as far as I know) have a rather "wide" coherent qubit capacity among other characteristics.
So what... Curve25519 until 2050? 2100? Hard to say and new math is always a total wildcard, but it seems damn secure.
... and as you say DH and RSA are also great with >2048 bits. 4096 bits is what I typically use.
There are four reasons people use Curve25519: it's faster in software than most implementations of the other curves, it was designed to be mostly misuse-resistant, so you don't have to be as careful checking parameters (a very common vector for ECC curve attacks), it's designed to be simple to make leak-proof implementations (unlike the NIST curves, which are hard to do in constant time), and it has the Dan Bernstein brand.
But if we're talking about index calculus attacks, the NIST curves do fine there too.
After the NSA news happened , schneier said the math is safe , saying/implying you can trust Diffie-Hellman. And now it's not secure. So how can we be so sure of Curve25519 ?
In other words, people a decade ago were also telling you to avoid DH-1024. What we're looking at today is a more efficient way of exploiting a bug we've known about for a long time.
The security of 2048-bit DH versus 1024-bit DH isn't the difference between "one year" and "two years", it's the difference btween "one year" and centuries.
[2] http://security.stackexchange.com/questions/42415/openvpn-dh...
Wrong answer. Standard primes are fine; just avoid the small ones. If you try to select your own parameters you're probably going to pick wrong, either in the sense of breaking the crypto or making people wonder if you selected your parameters to hide a backdoor. The standard large primes (my preferred option is the "group #14" 2048-bit prime) were very obviously not selected maliciously, and there's no way anyone has done the precomputations necessary to index that group.
Is there any known situation in which generating parameters with 'openssl dhparam' will give you broken/weak parameters?
> either in the sense of breaking the crypto or making people wonder if you selected your parameters to hide a backdoor
This is a concern if you're going to distribute your parameters with software, but it could make sense where a sysadmin controls both endpoints, such as a site-to-site VPN.
(a link will suffice)
p = 2^2048 - 2^1984 - 1 + 2^64 * { [2^1918 pi] + 124476 }
The value 124476 is the smallest non-negative value which results in p and (p-1)/2 both being prime and 2 being a quadratic residue mod p; this ensures that the subgroup {2^0, 2^1, 2^2, 2^3, ... } is cyclic.
We assume that the binary expansion of Pi is not selected maliciously. ;-)
FFFFFFFF FFFFFFFF C90FDAA2 2168C234 C4C6628B 80DC1CD1
29024E08 8A67CC74 020BBEA6 3B139B22 514A0879 8E3404DD
EF9519B3 CD3A431B 302B0A6D F25F1437 4FE1356D 6D51C245
E485B576 625E7EC6 F44C42E9 A637ED6B 0BFF5CB6 F406B7ED
EE386BFB 5A899FA5 AE9F2411 7C4B1FE6 49286651 ECE45B3D
C2007CB8 A163BF05 98DA4836 1C55D39A 69163FA8 FD24CF5F
83655D23 DCA3AD96 1C62F356 208552BB 9ED52907 7096966D
670C354E 4ABC9804 F1746C08 CA18217C 32905E46 2E36CE3B
E39E772C 180E8603 9B2783A2 EC07A28F B5C55DF0 6F4C52C9
DE2BCBF6 95581718 3995497C EA956AE5 15D22618 98FA0510
15728E5A 8AACAA68 FFFFFFFF FFFFFFFF
Source: https://tools.ietf.org/html/rfc3526#section-3Well, I suppose that we must assume that, as assuming otherwise is self-defeating: anyone running the simulation we're living in already has direct access to the plaintexts anyway.
However, a possible danger is that somebody maliciously suggested using π instead of e...
> Wrong answer. Standard primes are fine; just avoid the small ones.
Sure, that's what I meant insofar as the out of the box params are apparently too small in many apps/libs. The links I gave cover it pretty well, I think, no?
Do what Colin says upthread.
Nothing that I said was wrong - nor does it contradict Colin's advice - and while simple systems are better, that's a tradeoff that should be made if you care about entities with lots of resources like e.g. the NSA. As history shows, bad parameters (or parameters that are feasibly bruteforced over a particular timeframe) are not an 'unlikely' weakness. Besides, being aware of potential vulnerabilities - especially those that you know pose real threats - and not addressing them is simply bad practice.
I'd prefer Tahoe-LAFS
Why else would you want that if you aren't trying to hide something?
Is there an easy way to check if a VPN provider has updated?
The ASICs NSA built for breaking some common 1024 bit fields are probably breaking specific RSA keys now...
Deleted comment
But I'm not convinced that this command will answer the question; if you take the TLS analogy, you can have a client certificate with a 4096-bit RSA key but you can then use that to authenticate to a server with a 768-bit DH parameter! So these parameter sizes are independent.
But if you don't have access to that code on every platform you might need to deploy on, it might be better to do DH-2048 than to use crappy curve code.
Basically, your best choice right now is Curve25519. If you can't get a trustworthy Curve25519, though, it might be tricky to pick between DH-2048 and {other curve software}.
(2) Parent is asking for something just slightly different enough that it escapes dragnets and automated attacks.
There is no question that (1) is much better than (2).
But in special circumstances, one could do both (1) and (2) in cascade operation (i.e., do one first, then the other). If the code for (1) and (2) run as separate processes with independently chosen keys, seeds, parameters, etc., then it doesn't matter how awful (2) is. It might help, it might not help, but it won't make the security worse than using (1) alone.
The obvious downsides are slowness, code complexity, non-standard API/interface, code maintenance headaches, and false sense of extra security (but not worse security).
ftp://ftp.inf.ethz.ch/pub/crypto/publications/MauMas93a.pdf
Except that you could run the VMProtected binary until just after the unpacking routine ended giving you the original binary in memory. Didn't have to understand VMProtect at all.
Thanks hackers!
The same thing isn't necessarily true with crypto, but the lesson is that thinking you're adding security by layering without knowing what you're doing might backfire.
It’s also quite possible that the NSA/GCHQ/5-Eyes will notice that your communications are 'interesting, because different' and mark them to be stored in perpetuity in case they ever do decide that you’re of interest so that they can go back and break it all then.
So, how lucky are you feeling?
[1]: http://security.stackexchange.com/questions/83881/is-using-t...
The basic algorithm is that you take some candidate X (which will be our 2048 bit number here) and classify your question (primality, whether it is the product of 2 primes, etc) --- once you have your question, Q, then you can pick a number Y0 to get X % Y0 = Z0 ... sometimes ~sqrt(X) works well, other times it's the closest prime factorial, etc.
now using those results, [Q, Y0, Z0], you can optimally pick Y1 and do the operation again, X % Y1 = Y2 ...
Like the Chinese remainder theorem each Z gives you information on the next optimum Y given your question Q ...
I called it tunnel factoring and saw some great early results ... but for some reason I haven't ever pursued it
I'll have to look at some old cvs repos ... Hopefully I can find it. I'll put it on guthub if i can.
I worked a good 6 months on it and I understand the gravity of the claim. I have no interest in being bogus or fraudulent.
Please do. It sounds very interesting.
I'm personally trying to get more of my projects out into the open, even before I feel like they're ready - having code I put lots of time into that never gets seen by anyone makes me feel like I'm wasting my time. But at least getting some feedback helps me build better things next time.
I'll just leave this here: http://fortune.com/2015/06/29/intelligence-community-loves-i...
Either you don't know what is in that DC, or you do. If you don't know what's in the DC, you can't say one way or the other about what it can and can't do. If you do know what's in the DC, then you'd likely be prevented from saying what it's capabilities were or would deny those capabilities publicly if it did possess them. This is why people make tinfoil hats; because they reach cognitive dissonance quickly with logic built around untrusted data.
Because I can't implicitly trust you, or Amazon, or the intelligence agencies, I'm left with the reasoning capabilities I have and trust. Floundering in cognitive dissonance isn't going to get me anywhere in that regard. I'm left with what I know, which is that US agencies pay Amazon a staggering amount of money to run a datacenter for them. I know that AWS itself runs servers with special purpose hardware in them, such as GPUs, and that most of the value in AWS comes from federating systems and providing fault tolerance and easy programmatic access to provisioning. What sits behind all those features is anyone's guess. Amazon does not publicly discuss their relationship with the government, so that's zero help here.
If Amazon wanted to own the world's public cloud AND remain trusted, they should have thought twice about doing a deal with the government. In Germany, this shit wouldn't fly. Companies who provide services to the government there sign special agreements to ensure what services they provide to the government aren't colluded with the services they provide to individuals. It's beyond dumb that we allow this in the US and that the largest cloud provider here is mute in that regard.
Sure you can: just go with worst case scenario and assume custom hardware. I did that on Schneier's blog below:
"The room for error here is in the ASIC assessment. We need to figure out how much they can parallelize this, either in cores or custom circuits, in a given ASIC. Then, how many of those can do in one chip at 14-28nm. Then how many they can squeeze in a rack. Then how much factoring can be done with Amazon or Microsoft datacenters full of those. That would be the most paranoid assessment.
You see, the unit prices of these things are really low vs initial development costs. That's one of main drivers for hardware to shrink. The chips might cost pro's $10-30 million to develop with boards a tiny fraction of that. Then, the chips themselves are fabbed dirt-cheap with the boards being inexpensive. If algorithm doesn't need much communication, then they can use standard I/O options to farm out the jobs which then just run until they complete. They could add more capacity year after year cheaply with incremental energy cost after spending a ton of money on chip design and real estate just once. They could get 50,000-100,000 chips with multiple accelerators on each every year.
So, I think the authors upper bound is lower than the real upper bound. Need to get specialists who have implemented algorithms like this in hardware to show how it will likely be implemented. Need at least one person whose done a 28nm design to estimate how much of the chip can be dedicated to that with the other functions considered. Then multiply that by whatever Amazon has to get a decent upper-bound. "
Imagine the money not spent on more pressing issues we face these days: health problems, poverty and the destruction of nature earth, just to name a few.
Why do we, as a society, tolerate this?
In Western democracies [I really want to put quotes around both those words] do we have a choice?
In the UK we get to vote but it's for one of 2 or 3 sets of policies for the next 5 years, at no point do I recall any main party saying they were going to do something about NSA/GCHQ incursions in to UK life; I imagine USA have us over a barrel even if there were political will amongst the elite to change the spying on ordinary subjects [of the Crown].
Of course that would never happen as nobody who actually had any intention to do such a thing would ever get elected as PM - look at the complete lambasting that Jeremy Corbyn has been getting, including murmurings that the Army would mutiny if he got into power.
[NB I am not a Labour supporter and wouldn't vote for Corbyn but I do think that the way he has been treated recently is pretty appalling.]
Spending billions to make a whole country stop working and cast a vote is another one. Should we take all those billions and put them in more pressing issues in exchange for despotism?
Maybe our society tolerates it because it is the only way to play the game with the current rules.
* for some ambitious but obviously not literal definition of "all".
I know I can, but I'm hoping for something simpler than having to parse the TLS messages from:-
openssl s_client -connect host:port -msg
to work it out.Then, if the prime number is standardized or hard-coded, why they just not use it? Why we need to break it?
If everyone used a random very large prime (spec suggests so) then NSA would have to break with every prime number possible which currently is not possible
Client generates a key, encrypts with server's RSA key, sends it to the server, and the session starts. This lacks PFS.
Client and server participates in DH key exchange, the server signs their DH parameters using the RSA key so that the client knows that he's talking to the right person. They now start the session using that DH generated key. This has PFS.
And there's same as the above but with DH replaced with elliptic curve DH (different way of achieving the same thing), and RSA replaced with ECDSA, and a few other options.
This means it can't be done without risking that you might notice it. And it can't be done just by passively hoovering up all the traffic and then retrospectively going back and decrypting it.
The problem is that in many cases you can't afford to sacrifice enough performance for it.
Also, malware and crypto doesn't "play in the same field". Malware is solved by secure programming, access controls and users that are educated to not fall for trojans.
Encryption handles communication and storage, and only to a small degree data processing.
On the other hand there are algorithms which are believed to be backdoored by the NSA (some elliptic curves). These algorithms can be avoided.
In the end, cascading encryption has very limited benefits because the weakest point of a security application is almost never the algorithm used.
Still, it's a good reminder that you should not be using 1024-bit Diffie-Hellman.
Just to clarify (because I was confused when I read your comment), the weak DH attack was made public by the same people who wrote this post and the academic paper attached to it. It looks like the post and the paper are part of the same "release".
Conflict of interest disclaimer: I was a grad student of Professor Halderman's several years ago.
If I'm not mistaken, they gave a presentation in May and have now published a full technical paper.
Perhaps rehash is too harsh a word to apply to a paper that contains more details than given in the slides.
No criticism of the authors is intended (to the contrary, their findings are amazing and very important). But readers need to know this isn't a new attack before they go off panicking.
Today they simply formally presented their research at ACM CCS.
This is how that attack works. You generate a set of small primes called the base primes:
2, 3, 5, 7, 11, ...
Then you generate powers of p which all factor in only the base primes. This creates a set of linear equations, which can be solved to find the discrete logarithm of all base primes.This was all pre-computation. After this, to find the discrete logarithm of x, you generate powers of x until it factors in the set of base primes. Once that is found, calculating the logarithm is easy.
This requires a trade-off: the larger the set of base primes, the longer the first step takes, but the faster the second step is.
It's a table specifically of the discrete logs of a large (but tractable) number of small primes. Those discrete logs can be used as the input to a separate stage that can calculate the discrete log of any value in the field.
I mean, say we put through a few patches and started generating primes more often. Then there big-ass special purpose prime machine becomes an order of magnitude less-effective, right?
I think the best way to defend against these one-to-many attacks is to spread out the cost of decrypting large quantities of data. If we all had our own keys, even if they weren't as strong as one single key that everyone used, that much more work has to be done to decrypt data for a group of users.
I know nothing about crypto, but a layman can hear about these implementation architectures and immediately realize what's wrong with it all.
What can end-users be doing about this?
The government of the people should not be spending $10B a year to monitor and track all of its people just to warehouse the data.
That is quite literally Stasi. Not vaguely like, exactly like.
Come on. I agree this is ridiculous and unacceptable, but this kind of hyperbole only serves to make people discount the sentiment. The NSA has not tried to use this to suppress political dissidence. The Stasi themselves called the way they manipulated prisoners "decomposition", and all evidence suggests it deserved the name. It makes the CIA torture look like juvenile detention.
Is that a possible dark future if this goes unchecked? For sure. But I think one of the main reasons serious anti-NSA sentiment and action has had trouble making it to the mainstream is that people say things like this that make most people write the movement off as a bunch of crackpot conspiracy theorists. I don't think you are one, so please don't talk like one.
False. They did with Martin Luther King Jr.
To quote the Senator Church of the Church Committee which investigated this:
>In the need to develop a capacity to know what potential enemies are doing, the United States government has perfected a technological capability that enables us to monitor the messages that go through the air. Now, that is necessary and important to the United States as we look abroad at enemies or potential enemies. We must know, at the same time, that capability at any time could be turned around on the American people, and no American would have any privacy left such is the capability to monitor everything—telephone conversations, telegrams, it doesn't matter. There would be no place to hide.
>If this government ever became a tyrant, if a dictator ever took charge in this country, the technological capacity that the intelligence community has given the government could enable it to impose total tyranny, and there would be no way to fight back because the most careful effort to combine together in resistance to the government, no matter how privately it was done, is within the reach of the government to know. Such is the capability of this technology.
>I don't want to see this country ever go across the bridge. I know the capacity that is there to make tyranny total in America, and we must see to it that this agency and all agencies that possess this technology operate within the law and under proper supervision so that we never cross over that abyss. That is the abyss from which there is no return.
Didn't mean to imply the entire government is 100% stasi, I mean their data warehousing obsession about their own citizens is exactly stasi-like.
What if few hundred millions is 10x less than actual amount. What if it takes 10 years instead of 1.
Unless they themselves are wrong in the calculations.
Analysis and attempts to decode the Voynich manuscript lead me to believe mathematical patterns intended to hide information, languages in particular, are not safe in the least.
When the work required to brute-force a cipher in a sane timeframe doesn't exist (or even couldn't fit) within the bounds of the observable universe, (if the crypto works as intended, which, to be fair, is a big if) brute-forcing is safely axed as an avenue of attack.
Of course, on these scales, if you really want to, you could connive and threaten your way into having a backdoor installed. Or you could spy on the victim and steal their laptop, with the key decrypted and in memory. Or you could beat the key and password out of them. Brute-forcing shouldn't be the most pressing of anyone's cryptographic worries.
When software uses a known set of hard coded primes, it is logarithmically simplified in what it takes to defeat it.
Maybe there are good primes, bad primes, but to "standardize" a prime is to give an anchor to an adversary.
The trade floors are already opening in Asia, I think. You have got 24 hours. Go!!!
No one will get their privacy "back" by fighting the NSA through technology, considering their mission, budget and capabilities they'll always win, the only way to pacify the NSA is through legislation that will ensure that they only use their capabilities when it's warranted.
The NSA can build a giant supercomputer/ASIC system/FPGA grid, but they're not going to factor a 2^14bit prime unless they have working quantum.
The only problem then is, unfortunately, having correct, secure, and non-tampered-with implementations of all the requisite libraries.
I'm not saying that currently in theory you cannot deploy or implement NSA foolproof crypto, I'm saying that in practice it will never work because the NSA mandate is to be able to break it and they'll will do everything in their power to maintain those capabilities.
And unless some one thinks that abolishing the NSA is a realistic possibility then you better pick your fights, because while the NSA all other US defense organizations are more or less superior to all others because the USA sees dominance and force projection to be vital to their national security China, Russia, and probably major EU powers aren't that far behind.
As for "Allied Countries"... yeah, sure the NSA would probably be within its charter if it let China take over Britain (except of course, that that'd harm US interests too).
Using Dual_EC_DRBG was a bit like doing your half of a Diffie-Hellman key exchange with the NSA - with the key exchanged being your internal random-number generator state - to anyone else, this communication is completely impenetrable!
Well, until someone else gets sufficient access to the internal NSA IT systems to get hold of the factors themselves of course. And one of the things Snowdon demonstrated to us was just how woefully insecure their internal networks were to a person in the right position. If someone in Snowdon’s position was able to access those keys, then it seems likely that so would other intelligence agencies, but we’ll never know for sure of course.
Such hubris. Much decrypt. Thanks NSA!
I tend to believe that, with time as the X-axis, that the nature of technology is on a positive curve with regard to liberty while the nature of political institutions is on a negative one.
Technology is a power multiplier. In the context of a graph of liberty vs time it would simply make moving that curve on the Y axis exponentially easier.
So either you disagree with that or you have some optimistic views on human nature with regards to liberty.
Add in the problem that that the less liberty there is the easier/more likely it is for more to be removed, increases in liberty are up hill, so to speak, compared to decreases as a side issue.
It's not that the NSA is inherently bad or good, as long as it exists it will be able to break crypto because that is it's mission, the US needs that ability for national security but it doesn't mean that the NSA has to apply their capabilities to cast a net on the entire planet.
That said it's very unlikely that an organization with virtually unlimited funding, and a recruitment monopoly on the best and the brightest in the field of cryptography and computer security will lose on the technology front. Trying to disarm the NSA is effectively trying to disarm the US that won't fly, the only option is to ensure that they use it only when its explicitly warranted and not as a business as usual tool.
Bullshit.
> recruitment monopoly on the best and the brightest in the field of cryptography and computer security
Again, bullshit. The NSA can't compete on compensation and there are plenty of people who refuse to work there out of principle alone.
And the NSA doesn't need to compete on monetary compensation, it competes on a whole 'nother level which is giving people the biggest challenges to solve while having access to unparalleled levels of resources and cutting edge technology.
Bell Lab's didn't compete on compensation either, but it was where everyone wanted to work because of the environment.
You also disregard nationalism, patriotism, and the ability of the intelligence community to groom targets which they've perfected into an art form.
I'm not saying those things don't exist or that the NSA is incapable of hiring competent people, I'm disputing your claim that the NSA has a 'monopoly' on recruiting the best and brightest. I've seen no significant correlation in my personal experiences between skill in mathematics and patriotism.
I wonder what world you all live in in which this is a bad thing. Theres real threats out there and i'd hate to live in a country that lacked the geopolitical leverage to make use of these tools to my nation's interests.
In 1972 the threat was the Democrats being elected president, so workers on the president's re-election committee burglarized the Democratic National Committee's headquarters at the Watergate hotel. Then Nixon (on tape!) hashed out a plan to have the FBI cover this up. Without a high-up leaker in the FBI, none of this may have ever come to light. (Actually, Nixon did something similar in 1968 against Humphrey, by convincing the South Vietnamese government to not hold peace talks. He not only betrayed the US but the South Vietnamese he made a deal with, since he pulled US troops out in 1972)
Then of course there is the FBI acting as a political police - disrupting the civil rights movement, bugging Martin Luther King Jr. and leaking information gained to the media, attacking those Democrats who were voting against continuing the Vietnam War etc.
Some of these excesses were pulled back in the 1970's, but in recent years they have begun raising their head again. And the country isn't even in such bad shape economically, militarily etc. I can image what would happen if there were another Depression, sit down strikes etc.
In 1929, the Secretary of State (a Republican!) shut down post-WWI domestic spying saying "gentlemen do not read other gentlemen's mail". Now we have these massive police bureaucracies who apparently don't care about the Fourth Amendment, and who are advising Congress that we shouldn't be allowed to have private communications with one another on our iPhones etc., all should be opened to the ears of Big Brother.
Keep walking down this road, and the "threats" like the mujahideen (funded by the previous generation of your type who explained to us that "Theres real threats out there") will not die down, but multiply, and will increasingly be from citizens within this country.
Grow some balls. I'll take a 1% chance of dying to terrorists every year over an Orwellian government that passively intercepts everyone's communications.
It's actually 0% per lifetime, rounded to many decimal places.
Statists and authoritarians like to overstate external threats as an excuse to consolidate & expand state authority internally. It's an old and common tactic.
The world where we all depend on secure communications for autonomy of our own lives?
Having the ability doesn't mean that they need to use it all the time which is what you should be fighting against.
As long as the fight is centered around trying to disarm the NSA you'll lose because that's not the right tactic an the US as a nation cannot accept it.
Maybe it's all just petty fiefdom bullshit. But those are standard approaches for plausible deniability. And some bits are reportedly unaccountable, walled off through "need to know basis" policy. So how can we know who they work for?
I'm glad the NSA and GCHQ are keeping tabs on them. Who knows when they might get a little too uppity and try change the status quo?