WEBVTT

00:00.000 --> 00:01.680
Okay, we're going to get started.

00:01.680 --> 00:03.180
AV will come at some point.

00:03.180 --> 00:05.640
Until then, you get micro-figures.

00:05.640 --> 00:09.320
I don't know if you can see anything there at all, but we'll do what we can.

00:09.840 --> 00:15.640
So, I'm Sean Anconi, and I'm an academic researcher at the University of Melbourne.

00:15.640 --> 00:18.500
I'm going to start with my long list of thank-yous.

00:18.500 --> 00:24.720
At that size font you probably can't see it, but there is a long list of people who actually made all this research possible.

00:24.720 --> 00:28.540
A team of researchers across the world at various different universities.

00:29.280 --> 00:36.420
My particular journey, I've done a fairly standard academic thing, other than a few run-ins with the law during the process.

00:36.640 --> 00:38.740
Some time in government, I worked in the U.S.

00:38.740 --> 00:42.060
Senate, which also feeds into some of this talk, and then at the U.S.

00:42.060 --> 00:43.020
Federal Trade Commission.

00:43.020 --> 00:46.400
They're a little less involved in the kind of scary stuff.

00:46.840 --> 00:56.680
So, the motivating question for a lot of my last 15 years has been, how does the NSA or state-level adversaries actually break crypto?

00:56.680 --> 00:58.820
So, we've all got theories about how they do it.

00:58.820 --> 01:01.600
Maybe it's implants, maybe it's fancy math.

01:01.600 --> 01:09.620
We don't actually know, as members of the public, unless some of you are former NSA employees, how this is done in a real practical sense.

01:09.700 --> 01:20.680
So, one of the things me and the various labs that I've worked in has done is try and replicate some of the setups that the National Security Agency might use, and see what we can replicate.

01:20.680 --> 01:35.080
Whether that's very large number crunching, whether that's trying to reverse engineer different hardware parts and see if there are vulnerabilities there, or even more interestingly, trying to figure out how decryption is done at scale.

01:35.080 --> 01:49.000
So, we know that for a substantial fortune of the NSA's existence and other similarly placed state-level adversaries, they have actually been able to engage in signals intelligence of decrypted traffic at scale.

01:49.000 --> 01:50.720
So, how do they do that?

01:50.880 --> 01:52.700
We could have a few guesses.

01:52.700 --> 02:06.780
The first is, well, they're the NSA, they've got a billion dollar-ish black budget, they can just buy a lot of chips, a lot of GPUs, a lot of ASICs, and accelerate crypto cracking faster than we could, and maybe they're just brute-forcing stuff.

02:07.040 --> 02:19.840
But we're pretty certain that AES-128 is very good, AES-256 is excellent, and even with a whole data center full of ASICs, you're unlikely to make very much progress at all.

02:19.840 --> 02:24.760
We think the security on those algorithms is pretty tight, so how are they actually doing it?

02:24.760 --> 02:28.160
Maybe it's just a matter of getting compliance out into the wild.

02:28.160 --> 02:36.780
Many of you probably saw the Snowden slides of agents putting chips into or tampering with existing hardware devices, maybe that's some of it.

02:36.780 --> 02:43.460
But it doesn't really explain the scale at which we think the NSA is able to do interception and decryption.

02:43.800 --> 02:48.380
And then most recently on the internet I've seen a whole lot of AI mumbo-jumbo.

02:48.380 --> 02:52.160
Perhaps the NSA is using LLMs to crack everything.

02:52.160 --> 02:55.520
I think that one seems a little even more unlikely.

02:55.600 --> 02:57.120
So what's the truth of it?

02:57.120 --> 02:59.400
How are they actually doing this at scale?

02:59.420 --> 03:01.940
The answer is probably some mix of these.

03:01.940 --> 03:08.860
Having a large data center full of ASICs is likely quite helpful, but it isn't going to get you all the way there.

03:08.860 --> 03:23.760
Having implants that you can target at specific adversaries, like the NSA's adversaries, not the NSA themselves, is again going to be very useful, but won't get you all the way there to the type of mass interception that we actually think is happening.

03:23.900 --> 03:26.820
So let's...

03:26.820 --> 03:27.960
Oh, sure.

03:28.820 --> 03:29.680
Okay.

03:30.360 --> 03:32.580
So... oh my god, that's loud.

03:32.840 --> 03:34.360
Maybe I'll go back here.

03:36.760 --> 03:51.720
So let's take it back a little bit and go to an actual picture of what cryptography looks like, sketch version, and slowly add in some of the pieces to try and figure out what the NSA themselves might actually be targeting in order to achieve decryption at scale.

03:51.840 --> 03:55.720
So here we have our baby intro crypto 101 slide.

03:55.720 --> 04:00.340
I know this is old news probably for many of you, but as we add a few more features.

04:00.400 --> 04:07.140
So Alice wants to talk to Bob, and then we have our adversary who wants to intercept in the middle.

04:07.140 --> 04:12.520
Maybe they have cut a transcontinental sub and are intercepting the traffic.

04:12.520 --> 04:14.400
So right now, no encryption on this.

04:14.400 --> 04:14.920
Great.

04:14.920 --> 04:18.200
Eve can listen in and hear that Alice hates her.

04:19.240 --> 04:25.060
Unfortunately, now Alice and Bob have decided to use cryptography and suddenly it's opaque to them.

04:25.060 --> 04:27.400
This is the challenge that the NSA faces.

04:27.520 --> 04:31.680
So what are the concrete cryptographic building blocks that they're going to use?

04:31.680 --> 04:35.540
Well, they'll probably have a symmetric cipher under some key K.

04:35.640 --> 04:39.340
As we know, that's not going to be enough to actually secure the communication.

04:39.340 --> 04:43.680
Right now, this is susceptible to things like man in the middle attacks, replay attacks.

04:43.680 --> 04:47.040
So we're going to need all these different pieces.

04:47.260 --> 04:49.780
On there, we'll have a key exchange at the beginning.

04:49.780 --> 04:50.880
Still not good.

04:50.880 --> 04:52.920
Now we're going to need some kind of authentication.

04:52.920 --> 04:54.880
So we're going to add a digital signature.

04:55.020 --> 04:58.980
We're going to add nonces to ensure that replay attacks aren't possible.

04:59.500 --> 05:03.420
And this involves randomness at a number of different stages.

05:03.420 --> 05:13.160
And the security of the protocol critically is fundamentally reliant on the unguessability of these random values.

05:13.160 --> 05:18.520
So for those of you who are familiar with random number generation, this will seem like fairly straightforward to you.

05:18.520 --> 05:21.880
Well, of course, these random numbers aren't truly random.

05:21.920 --> 05:34.680
But digging into the details turns out to be quite important, because if there is a flaw systemically in the random number generators, maybe this would open up a pathway for a state level adversary to systemically decrypt the traffic.

05:34.680 --> 05:47.060
Because once you're able to predict some of these values, and again, the details of which random numbers you need to predict are going to be dependent on implementation, you might be able to decrypt traffic at scale.

05:47.100 --> 05:49.700
So that's what a chunk of the talk is going to be about.

05:49.920 --> 06:01.880
And then the second half, which I think is almost the more interesting half, we're going to move beyond random number generators and say, well, how do you encourage people to have broken random number generators in the first place?

06:01.880 --> 06:14.140
And if you're a state level adversary, how do you go about ensuring that the implementations and protocols that people use are broken in the first place so that you can later come along and break the traffic?

06:14.780 --> 06:15.460
Okay.

06:15.460 --> 06:17.280
So let's go back even a little further.

06:17.280 --> 06:18.840
Back to the design of DES.

06:18.840 --> 06:26.440
We have a standards organization which attempts to set what algorithms will be used and what their design is.

06:26.440 --> 06:32.660
So earlier on, this was the National Bureau of Standards, which evolved into the National Institute of Standards and Technology.

06:32.680 --> 06:39.020
And there's a cute little stick figure graphic online about the early standardization of DES due to Jeff Moser.

06:39.020 --> 06:41.060
You can check that out online.

06:41.760 --> 06:44.040
But this was quite a long time ago.

06:44.040 --> 06:51.940
What changed such that the NSA went from breaking DES with shorter key lengths to being able to break traffic at scale on the internet?

06:52.120 --> 06:57.760
Well, there's the well known Snowden slide that showed that the NSA did in fact have this capability.

06:57.820 --> 07:09.740
Some of it was due to intercepting traffic after it had been decrypted at places like Google's termination, just after the termination, the NSA would have a network tap and then they'd be able to read the decrypted traffic.

07:09.740 --> 07:17.540
But something about this slide kind of twigged for my lab that suggested that they were actually able to do some of the decryption themselves.

07:17.860 --> 07:21.700
And for the NSA, this resulted in a happy dance.

07:22.480 --> 07:31.860
So what is the public cryptography community missing or what were they missing in around 2010 that actually led to this decryption happening?

07:31.880 --> 07:34.180
Was there a big algorithmic breakthrough?

07:35.540 --> 07:38.820
They're probably one of the largest hires of mathematicians in the world.

07:38.820 --> 07:46.040
Do they know something about math that we didn't such that they were able to compromise either the random number generators or the public key crypto?

07:46.060 --> 07:52.120
Did they have an algorithm to calculate the discrete log of Diffie-Hellman faster than we think is possible?

07:52.300 --> 07:53.040
Maybe.

07:53.420 --> 07:56.980
Or is it something both a little more mundane and a little more sinister?

07:56.980 --> 07:59.000
And we're going to talk about what that was.

07:59.000 --> 08:06.060
So, again, as a refresher, we need in order to generate crypto keys, we need a good source of system randomness.

08:06.280 --> 08:10.500
Not every crypto system is going to rely on randomness, but most will.

08:10.500 --> 08:16.000
And so this is going to be the focus for today is those crypto systems that do need randomness.

08:16.060 --> 08:29.640
The best way of doing it probably is using quantum mechanical fluctuations, having a true random number generator and actually get something that's pulling from as far as physicists know is a truly random distribution.

08:30.240 --> 08:43.980
But there are some issues with this in that true random number generators have tended to be expensive, not available in commodity hardware, your phone doesn't have one in them, so if your phone wants to do TLS, it's going to need some other source of randomness.

08:43.980 --> 09:00.740
And so what we've traditionally done is use pseudo random number generators and schematically we gather entropy from a variety of sources, whether those keyboard timings, what time the computer was turned on, mix that up using a whitening function and use that to generate our crypto keys.

09:01.100 --> 09:12.500
And so in order to figure out what the NSA, how the NSA was breaking traffic at scale, a good path forward would be to look at standardized designs of pseudo random number generators that are everywhere.

09:12.560 --> 09:24.520
And the reason why standards are important is because from a financial perspective, industry is going to latch on to those standards to choose what they design into their products, which makes them an excellent target if you want to compromise something.

09:24.520 --> 09:29.720
If you compromise the standard, you're going to compromise a large set of products.

09:29.800 --> 09:38.300
So we're going to dig a little bit into some of the standardization programs that have existed that an adversary such as the NSA would have been able to break.

09:38.880 --> 09:41.420
Now if you dive into U.S.

09:41.420 --> 09:47.320
federal information security standards, a number of them are much larger than others.

09:47.320 --> 09:56.780
Now the primary one of these is FIPS, the federal information processing standards, 140-X, where X is the series of the standard.

09:57.000 --> 10:00.700
At the time of research, it was 140-2.

10:00.700 --> 10:09.580
Now there's 140-3, and I'm pleased to say that a lot of the issues in this talk have been remediated over the last two, three-ish years with that new standard.

10:09.760 --> 10:25.760
And as part of that, they also introduced the cryptographic module verification program, the CMVP, where vendors were able to go to NIST and say, hey, we think we meet FIPS 140-2, can you give us certification under this program?

10:25.760 --> 10:30.360
And with this certification, you then have approval for your products to be procured by the U.S.

10:30.360 --> 10:31.380
federal government.

10:31.380 --> 10:41.560
So if you are a major vendor of hardware devices, of course you're going to want to ensure that you have a FIPS compliant mode such that you can sell to one of the biggest customers out there, the U.S.

10:41.560 --> 10:42.000
government.

10:42.000 --> 10:53.880
And so there are a large set of incentives, even if you think your crypto should be designed in a slightly different way, to at least support the FIPS standards such that you can attain this certification and then sell your devices.

10:53.880 --> 11:08.260
So if you look at all the biggest hardware device manufacturers in the world, so network devices, Juniper, Cisco, and the like, all of them do maintain FIPS supported modes in their products.

11:08.260 --> 11:12.760
Now I will say that just because FIPS is supported doesn't mean it's necessarily the default.

11:12.760 --> 11:15.740
With many devices you do have to switch the FIPS mode on.

11:15.740 --> 11:19.740
It is also available for software systems such as OpenSSL.

11:19.740 --> 11:36.400
This is a little iffy in terms of the way that the certification has worked historically because the documents are largely written for end-to-end systems such as integrated hardware devices, but OpenSSL did have them certified as a library for inclusion within other products.

11:37.220 --> 11:49.500
Now a couple of interesting things about having the FIPS mode turned on is when FIPS is turned on you're actually required to use the FIPS algorithms for every system function.

11:49.540 --> 11:58.220
So at this point it no longer becomes optional whether you use the FIPS random number generator, the FIPS approved random number generator, or the FIPS approved public key algorithm.

11:58.220 --> 12:00.400
You have to use it for everything.

12:00.900 --> 12:06.520
And here you can see the diagram of what one of the FIPS approved random number generators looked like.

12:06.520 --> 12:15.400
This is the ANSI X9.31 generator which was the earliest random number generator that I could find in a FIPS standard.

12:15.400 --> 12:17.140
And that's going to be where we begin our story.

12:17.140 --> 12:28.140
It might be a little hard to follow along with the size of the graphic for how this random number generator works, but I will try and describe it to the best of my ability over voice.

12:28.540 --> 12:39.220
So essentially the way that this random number generator works, and this is going to be our first candidate for NSA backdooring, is you feed in the time as the entropy.

12:39.260 --> 12:46.000
Every time you generate a random number, you mix that up by XORing it with the prior version of the state.

12:46.020 --> 12:51.660
How the state is initialized is left somewhat up to the implementation.

12:52.020 --> 12:54.880
And then you use a block cipher as a mixing function.

12:54.880 --> 13:01.520
So you feed the time into either DES and the earliest versions of the design I could find, or then AES later.

13:01.520 --> 13:04.500
You XOR it with the prior state, that gets you the new state.

13:04.500 --> 13:10.020
You do this again with another timestamp, and then you get the output of the random number generator.

13:10.380 --> 13:17.680
Now, for those of you keen-eyed individuals, you might have remembered that AES is in fact invertible under a given key.

13:17.740 --> 13:24.680
So if you know the key, and you know the output of the random number generator, you can run the whole thing backwards and get to the state.

13:24.680 --> 13:33.760
And then if you're able to guess the, you're able to, if you run it backwards, you can get the state XORed with the timestamp.

13:33.980 --> 13:39.520
Now, timestamps are somewhat guessable, they're relatively low entropy, especially on older systems.

13:39.520 --> 13:49.740
In fact, I think it was only in the last couple months that a number of distros moved to using 64-bit time for the system random number generators.

13:49.920 --> 13:56.780
And so if you're guessing a 32-bit timestamp that's relying on when the machine is turned on, you can run that actually pretty quickly.

13:56.780 --> 14:04.240
In my estimates of how much real entropy this has, it's about 2 to the 28, which is crackable on a standard laptop.

14:04.580 --> 14:18.380
So you reverse that, you invert the output from the random number generator that hopefully you've captured, you get the XOR of the timestamp and the state, you guess the timestamp, you've now recovered the state.

14:18.380 --> 14:27.840
If you can guess a second timestamp, you can then verify your guess by comparing it to the next output of the random number generator under a new timestamp.

14:28.700 --> 14:32.220
So how did this actually come to be a standard?

14:32.280 --> 14:45.940
Well, one of the really interesting things here, and this is going to be a repeated part of the story, is that before it became part of the federal information processing standards, someone, in this case John Kelsey, actually pointed out this particular flaw.

14:46.200 --> 14:54.040
And this pattern of, well, there's a potential flaw in the standard, but we're going to go ahead and standardize it anyway, is something that we see over and over.

14:54.140 --> 15:04.840
And even if it's not proof of backdooring, is a reason to be suspicious about the way that standardization is happening in and gives us substantial unease about the process.

15:04.840 --> 15:12.520
The only things that should get standardized are things for which there are no known significant public cryptographic concerns or weaknesses.

15:12.740 --> 15:22.960
So as early as 1998, this is a little tricky for me, squinting at it on the tiny screen, we'd known about the flaw.

15:23.140 --> 15:30.340
And then all the way up until 2016, this random number generator was actually part of the official government standard.

15:31.340 --> 15:50.480
So as I said before, if for some reason you're able to figure out the key that is used in this random number generator, then you can probably invert the whole process and guess the future outputs of the random number generator, allowing you to break whatever crypto system is relying on these random numbers.

15:50.800 --> 15:53.900
So what does the standard actually say about this key?

15:53.900 --> 15:55.480
It seems to be really important.

15:55.480 --> 15:58.140
If you know the key, you can break the random number generator.

15:58.160 --> 16:04.000
So reading directly from the standard, this is the entirety of what it said about the key.

16:04.080 --> 16:09.860
For AES 128-bit key, let star K be 128-bit key.

16:09.900 --> 16:10.580
Okay?

16:10.720 --> 16:15.900
This star K is reserved only for the generation of pseudo random numbers.

16:16.140 --> 16:20.040
That is the sum total of the guidance about the key.

16:20.120 --> 16:24.100
The standard did not specify that the key should not be hardcoded.

16:24.320 --> 16:33.980
And so, of course, the obvious thing to do is to go and look at all the places where this random number generator is used and see how many of them actually hardcoded the key.

16:34.500 --> 16:40.640
One of the other beautiful things about the cryptographic module validation program is that all the certificates are public.

16:40.640 --> 16:51.800
Every device that has been certified under the program has a listing of the name of the product and what algorithm they use, which makes it an obvious target now that we know that there might be hardcoded keys out there.

16:51.800 --> 17:05.520
So, I went out and went through all of the 300-odd certifications, went through every device, and reverse engineered all of them that were not explicitly clear in their documentation that the key was generated dynamically.

17:05.520 --> 17:09.820
If the key was generated dynamically, there are other attacks you could probably use to recover it.

17:09.820 --> 17:19.980
But at least for the low hanging fruit of the hardcoded ones, I was able to find 12 different certificates or devices that actually had hardcoded their key.

17:20.220 --> 17:22.920
And see if I can squint this.

17:22.920 --> 17:26.460
Here is some of the language that was used in the certification documents.

17:26.600 --> 17:34.140
The key is compiled into the binary, static key stored in the firmware, entered in the factory, loaded at factory, embedded in Flash.

17:34.300 --> 17:42.260
Now, unfortunately, I wasn't able to obtain many of the physical hardware devices that were actually under the certification program.

17:42.260 --> 17:44.300
I did get my hands on a few.

17:44.440 --> 17:55.520
One manufacturer that we contacted as part of the remediation process had actually lost the source code because they had acquired the vendor in a murder and acquisition.

17:55.940 --> 18:00.500
So they weren't actually able to tell us what their hardware was doing and they discontinued the product.

18:00.500 --> 18:02.100
So we weren't able to get a copy.

18:02.140 --> 18:09.960
However, I was able to get a copy of a device running Fortios V4 that was certified under this program.

18:09.960 --> 18:16.700
And at the time, this was the second largest network device operating system out there behind Juniper.

18:17.600 --> 18:20.600
So reverse engineered it and what did I find?

18:20.760 --> 18:25.080
There we are, a hard coded key for the random number generator.

18:25.480 --> 18:28.200
Now, something about this key struck me as familiar.

18:28.200 --> 18:32.920
You spend too much time staring at hexadecimal values and some of them just embed in your brain.

18:33.500 --> 18:41.300
I then went back to the test vectors for the ANSI X931 generator and that is the exact same key.

18:41.300 --> 18:47.040
So some poor cryptographic engineer had obviously pulled it right out of the standard without thinking.

18:47.040 --> 18:50.940
Now, naturally, this led to a pretty straightforward attack.

18:51.380 --> 19:04.420
So monitoring a TLS flow from a Fortios V4 device, we were able to see the server random being sent by one of these hardware devices to any client connecting.

19:04.420 --> 19:08.520
That server random has the raw output from the random number generator.

19:08.520 --> 19:24.180
We can then invert that under the key that we got from the firmware or the test vector and then use that with a guess of the time stamp and verifying it against the master secret from the TLS handshake to ensure that we actually have cracked this.

19:24.780 --> 19:27.400
So this took about how much was it?

19:27.400 --> 19:33.460
It was 2 to the 25 brute work under empirical observation in order to brute force the key.

19:33.880 --> 19:47.160
We were able to perform internet wide scans and find private keys against perform against hosts in the wild decrypting what would be passively TLS handshakes and then being able to decrypt all of the traffic.

19:47.580 --> 19:54.960
So after our contact with Fortios to let them know of the issue, they took it out of Fortios V5.

19:55.340 --> 19:59.700
So at this point, you're probably thinking, great, we've solved the problem.

19:59.700 --> 20:01.500
Fortios V5 is secure.

20:01.540 --> 20:01.860
Okay.

20:01.860 --> 20:04.000
Let's move to the next random number generator.

20:04.620 --> 20:10.780
So this is counter DRBG, which is the evolution of the ANSI X931 generator.

20:10.780 --> 20:12.940
You think, okay, there's that problem with the key.

20:12.940 --> 20:15.520
What if we make that key a bit more dynamic?

20:15.520 --> 20:17.800
What if we generate it at run time?

20:17.800 --> 20:23.340
Surely we will avoid all the pitfalls of the prior random number generator.

20:23.340 --> 20:31.020
So this one was standardized in a document known as special publication 890, which had a series of random number generators.

20:31.020 --> 20:34.280
And we'll talk about one more of them in this talk as well.

20:34.280 --> 20:38.560
This is the successor design to X931, and there are a couple of changes.

20:38.560 --> 20:43.900
So now instead of using the timestamp, we are encrypting and incrementing counters.

20:43.900 --> 20:48.060
So hopefully you can't just guess the value of the counter if it's initialized randomly.

20:48.600 --> 20:55.580
And this also added support for adding in additional entropy into the pseudo random number generator as time went.

20:55.580 --> 21:10.820
So this was optional in the standard, but if a manufacturer so chose, they could add in entropy from things like packet timings to further mix up with the state of the pseudo random number generator and prevent the kinds of attacks that we saw before.

21:11.560 --> 21:15.520
So this pseudo random number generator worked in a three-step process.

21:15.520 --> 21:29.100
Take the existing key and a counter, add one to the counter, add any additional entropy together, run that all through so concatenate them, run it through AES, and then you'll get out from it a new key and a new counter.

21:29.100 --> 21:33.020
So split the output into a portion for the key and the counter.

21:33.600 --> 21:53.500
Then again, increment the counter by one, concatenate it with the key, run it, sorry, not concatenate it, use the key, and run the counter through AES, and then you get the output from the random number generator itself that will be given to the client application.

21:53.980 --> 21:59.860
And then one more time, just to ensure that you've refreshed the state again after this process, repeat it.

21:59.860 --> 22:11.280
So this is just like step one, where under the key K, concatenate the counter plus one and the additional entropy, run that through AES, and you'll get a new key and a new counter.

22:11.280 --> 22:13.860
So the key is now being refreshed pretty frequently.

22:13.860 --> 22:16.480
There's an opportunity to add in additional entropy.

22:17.180 --> 22:18.540
We should be safe.

22:19.240 --> 22:22.140
There are two problems with this design.

22:22.160 --> 22:28.000
The first is that you can generate an arbitrary amount of output in the second step.

22:28.000 --> 22:36.240
What this means is that you can generate, say, 10 kilobytes of random data under the same key before the key is actually rotated.

22:36.240 --> 22:46.520
It's not that you generate one block of output under the key, generate as many blocks of output as you need under the same key and counter value, and only then do you refresh it.

22:46.660 --> 22:54.360
The second thing is that the additional entropy was totally optional and left up to implementers to decide what they wanted to do.

22:54.520 --> 23:04.440
And we know that implementers aren't always putting in as much work as they could into their cryptographic designs, and so many manufacturers that we found just didn't implement this whatsoever.

23:04.940 --> 23:07.040
So this leads to an attack.

23:07.040 --> 23:19.060
If you can generate a large enough amount of randomness, if you can convince a client application to generate a large amount of randomness in that second step, you might then be and see some of the raw output.

23:19.060 --> 23:21.000
You've still got this invertibility problem.

23:21.000 --> 23:28.980
You can recover the state, which is the counter value, and then it's all deterministic from there, unless there's additional entropy coming in.

23:28.980 --> 23:32.380
So no additional entropy, whole thing's deterministic once more.

23:34.340 --> 23:39.720
If there is additional entropy, of course, if you know how that's being generated, you might be able to guess it.

23:39.760 --> 23:43.120
Depending on how much it is, you can brute force it.

23:43.120 --> 23:44.240
Okay.

23:44.240 --> 23:54.280
So let's go back to our prior idea, which was go back to the CMVP, see who's using it, see how bad the implementations actually are, and then try and learn something from it.

23:54.280 --> 24:02.880
So we systematically reviewed all of or I systematically reviewed all of the CMVP certificates again, and what did I find?

24:02.880 --> 24:08.180
Fortios V5 had switched to using this pseudo random number generator.

24:08.440 --> 24:14.060
So I reverse engineered it as before and also used it to simulate a number of other targets.

24:14.060 --> 24:24.580
I didn't reverse all of them, because that would have taken more time than it was worth for the proof of concept, but I at least demonstrated that under the assumptions that those other products were using, they were also vulnerable.

24:25.160 --> 24:33.360
This time, in order to actually extract the key for AES during that second stage, I used a side channel attack.

24:33.360 --> 24:42.740
So perhaps this should make everyone a little more skeptical about whether the NSA was doing this at scale, but at least tells us something about the design.

24:42.900 --> 24:51.740
And using the attack, I was able to recover a long-term client ECDSA secrets that had been generated using this process.

24:53.440 --> 25:02.900
So cool attack, bro, but not necessarily what I was hoping for in terms of explaining wide-scale decryption capabilities of the NSA.

25:03.440 --> 25:14.820
It has, however, given us another bit of information about the standardization process, and that is the piece that I want to keep us focusing on long-term when we think about how large-scale decryption is actually happening.

25:15.980 --> 25:16.520
Okay.

25:16.540 --> 25:22.320
This story has been told quite a lot, and so I'm not going to belabor all the details.

25:22.320 --> 25:24.820
I'm not going to go through the actual implementation details.

25:24.820 --> 25:31.060
I'll just give you a little bit of the refresher to tweak that bit in your brain that's what's going on here with standardization.

25:31.960 --> 25:38.000
So, again, this is a proposal where problems were known about it relatively early on.

25:38.000 --> 25:59.020
In 2004, there was a draft proposal for inclusion into NIST SP890A, the same document as that last RNG that we just saw, and there was an early distinguishing attack by Schoenmaker and which showed that you could tell if the output, if a given string of output was actually from this random number generator or was truly random.

25:59.020 --> 26:03.240
You could distinguish between the two, and that's a big warning sign for pseudo-random number generators.

26:03.740 --> 26:20.520
In 2007, Dan Schumo and Niels Ferguson demonstrated that this could potentially be lead to a backdoor attack where if you knew the settings of particular curve points, you could use those curve points to run a passive TLS decryption attack.

26:22.440 --> 26:32.080
In 2013, the Snowden slides came out with specifically relating to Project Bull Run, and this is particularly interesting.

26:32.080 --> 26:41.800
I'll show the slide in a minute because it detailed or very lightly detailed that the NSA may actually have been concretely involved in the standardization process.

26:42.080 --> 26:43.820
So, is this the end of the story?

26:43.820 --> 27:03.680
It took until 2014 for this proposal to actually be removed from the standard, despite the fact that it had been concretely shown to be vulnerable, and then it was in 2015, years after the Snowden slides, years after this backdoor, where we actually found this inside Juniper Screen OS,

27:03.680 --> 27:12.160
which is their smaller product line, so this isn't their Junos, which is their larger network operating system, but we did find this deployed in the wild.

27:12.760 --> 27:20.200
Now, Junos is interesting because it didn't seem like they were actually using this random number from their documentation.

27:20.200 --> 27:27.320
It didn't seem like they were using this random number generator as the random number generator that would be used to produce the raw output.

27:27.320 --> 27:34.080
They were actually chaining it with NCX931, the first random number generator that we broke here.

27:34.080 --> 27:42.440
So, maybe even if there's a passive backdoor in the dual EC random number generator, they're fine because they weren't really using it anyway.

27:42.440 --> 27:44.960
They were just using it as input to another one.

27:45.800 --> 27:51.500
And further than that, they weren't using the potentially backdoored values in the NIST standard.

27:51.500 --> 27:55.260
They were using their own values for the points on the curve.

27:56.260 --> 27:58.740
So, let's rewind back a little bit.

27:58.740 --> 28:03.700
What did the NSA say in their leaked Snowden slides say that they had been doing?

28:03.720 --> 28:11.960
Insert vulnerabilities into commercial encryption systems, IT systems, networks, and endpoint communications devices used by targets.

28:11.960 --> 28:14.060
And then here's the more interesting bullet point.

28:14.060 --> 28:19.000
Influence policies, standards, and specifications for commercial public key cryptography.

28:20.140 --> 28:30.100
So, we did ‑‑ we, again, reverse engineered the ScreenOS code to find out what had been happening in different versions of ScreenOS and if it was actually vulnerable.

28:30.720 --> 28:40.620
So, here is a diff we did on a patch where Juniper announced that someone had gotten in in an unauthorized fashion into their code base and made some changes to their cryptography.

28:40.620 --> 28:53.180
One of the changes we found was that someone had actually changed the points on the curve that determine who has access to a potential passive backdoor from the dual EC random number generator.

28:54.140 --> 29:02.800
So, in theory, this still wouldn't be a problem because ScreenOS was only certified for use with ANSI X931 and not dual EC.

29:06.800 --> 29:26.560
So, in order to actually mount this attack, the same kind of thing as before, we would have to capture raw output from the random number generator and use now knowledge of the relationship between the two points in the standard or the two points used by the random number generator to reverse it.

29:26.560 --> 29:34.720
I'm not going to go over the details, but it turned out there were a number of particular implementation flaws as well that were present that made this viable.

29:34.940 --> 29:48.160
So, the first thing we found was that instead of actually being run through ANSI X931, the raw random number output from dual EC had mistakenly been exposed.

29:48.280 --> 30:02.400
On top of that, there was a choice for how many bytes you could use to produce the nonce and ScreenOS was producing more than enough bytes than were actually needed for the protocol which also led to our attack being much more efficient.

30:02.800 --> 30:04.660
So, this made us somewhat suspicious.

30:04.660 --> 30:13.740
We looked into the various different versions of ScreenOS that were released to figure out what unauthorized changes had been made to the code that kind of led to this.

30:13.900 --> 30:18.940
And we found that across versions, these flaws were subtly introduced over time.

30:18.960 --> 30:35.420
So, first, ANSI X931 was present and then in a later patch, dual EC was removed from the from the sorry, the ANSI X931 generator was removed from the chaining process to expose dual EC.

30:35.540 --> 30:46.000
So, over time, it looks like an adversary had a long-term plan for how to take a subtle cryptographic weakness into an actual passive TLS decryption attack.

30:46.000 --> 30:52.800
And we demonstrated this not in the wild because we didn't know the relationship between the two points that the NSA was using.

30:52.800 --> 30:53.720
That's the whole point of it.

30:53.720 --> 30:55.400
It should be a nobody but us backdoor.

30:55.400 --> 31:04.900
But by switching out those points ourselves on a target device that we purchased, we were able to show that at least this attack is viable.

31:04.980 --> 31:11.300
We did run scans against devices in the wild to look for ones that were vulnerable and were able to identify them.

31:11.860 --> 31:24.680
But it also seems that in some part, this probably wasn't actually as useful as maybe the NSA was hoping it would be because it never got deployed at the kind of scale where it would have been useful.

31:24.680 --> 31:33.540
But again, this is one more bit in the of trying to compromise standards as a technique of to subvert crypto at scale.

31:33.540 --> 31:41.320
Which, again, is the point of the talk rather than the particular individual bugs in the random number generators which are illustrative of this technique.

31:41.780 --> 31:50.560
So there was also some really good public reporting about how what had actually happened with the insertion of the bugs into ScreenOS.

31:50.680 --> 31:56.220
And this is what I think is kind of both surprising, interesting, and gives us a bit of a policy lesson.

31:56.520 --> 31:59.460
So it seems like, and I'll skip this to here.

31:59.460 --> 32:01.940
You're not going to be able to see it on that screen anyway.

32:02.140 --> 32:11.320
It seems like it wasn't actually the NSA that changed the value of the points that ScreenOS was using or that introduced the actual bugs.

32:11.340 --> 32:29.740
I have both had myself contact with individuals whom I trust who have told me that this was a Chinese APT, likely state sponsored, there's also public reporting which used different sources to back it up that suggests that this vulnerability was actually exploited by Chinese state sponsored hackers.

32:29.740 --> 32:32.480
I don't know the details of exactly who it was.

32:32.720 --> 32:44.560
But this is particularly fascinating as it shows us what was meant to be a nobody aspect or probably for the United States was repurposed by a foreign state adversary.

32:44.740 --> 32:47.420
I can give you one more small bit of information.

32:47.420 --> 32:51.900
Now, you might remember that I said it very early on that I used to work in the U.S.

32:51.900 --> 32:54.780
Senate as a cyber security fellow for U.S.

32:54.780 --> 32:57.040
Senator Ron Wyden in 2018.

32:57.120 --> 33:03.640
And I'll read you a little bit from the Bloomberg article that described their findings.

33:05.620 --> 33:10.400
In a July 2017, I'm going to have to read this from over here.

33:11.440 --> 33:21.940
In a July 2020 response to Wyden and other members of Congress, Juniper provided few new details of the case but blamed the intrusions on a sophisticated nation state hacking unit.

33:22.740 --> 33:29.120
NSA told Wyden's staff in 2018 that there was a lessons learned report.

33:29.180 --> 33:34.040
But the agency now asserts that it cannot locate the document.

33:34.580 --> 33:40.640
According to a Wyden aide, Reuters previously reported NSA's claim that the document had been lost.

33:40.760 --> 33:46.160
And to this date, as far as I know, no one has actually seen this document within the legislative branch.

33:46.160 --> 33:47.740
And I have asked around.

33:47.740 --> 33:50.180
So you can join your own dots there.

33:50.540 --> 33:54.100
So what is the big picture from all of this?

33:54.100 --> 34:07.660
The big takeaway is that standardization and accompanying certification processes are significant targets for state-level adversaries and that it is plausible that these are used for large-scale surveillance.

34:07.660 --> 34:17.440
So if we're trying to figure out what are the ingredients that go into building a large-scale decryption and interception program, this is likely one of the ingredients.

34:17.440 --> 34:26.040
We've got lots of different pieces from the NSA bull run slides to the empirical research that my team did to some of the follow-up journalism that's been done.

34:26.680 --> 34:30.420
So let's think back to and try and build a model around this.

34:30.420 --> 34:32.300
Let's go to supply chain attacks.

34:32.300 --> 34:34.920
Because this is starting to give some of that vibe.

34:34.920 --> 34:46.280
So traditionally, supply chain attacks are surreptitious actions that leverage the procurement and deployment process to get compromised devices into the hands of adversaries.

34:46.680 --> 34:53.120
And part of the idea here is that by the time it gets to the administrator actually deploying it, it should already be too late.

34:53.120 --> 34:57.960
Something in the supply chain has gone wrong and made the product vulnerable.

34:58.920 --> 35:03.560
This is the DOD's version of what a supply chain attack looks like.

35:03.560 --> 35:07.380
Again, you can download the slides after if you want to actually peek at it.

35:07.380 --> 35:07.980
And

35:11.080 --> 35:16.900
this is the NSA's version of what a supply chain attack looks like.

35:17.200 --> 35:30.520
What this is actually depicting is this is one of the leaked slogan slides showing the tailored access operations group intercepting Cisco network devices in the mail process, inserting implants and then sending them on.

35:30.520 --> 35:31.800
So that's great.

35:31.800 --> 35:34.520
But it's not quite what's happening here.

35:35.220 --> 35:39.980
That process targets only one phase of the whole product life cycle.

35:40.040 --> 35:45.780
For the most part, it targets once the implementation has already occurred, then you go in and insert something.

35:45.780 --> 35:46.700
That's where your spy is.

35:46.700 --> 35:50.500
But that's too unsophisticated for a state-level adversary.

35:51.160 --> 36:02.380
Instead, a state-level adversary can target a much larger portion of the product life cycle, going even before an individual firm starts to design their product.

36:03.020 --> 36:06.500
Now, let me look at my beautiful figure here, because I can't see it.

36:07.300 --> 36:30.800
So all the way back at the concept and design stage, the NSA is able to influence the way that firms go about designing their products initially, even before the engineers actually get to writing a line of code, by ensuring that they have certification and standardization requirements that impose on them in a particular way and that require them to build products that will have security flaws.

36:31.080 --> 36:36.020
So what I call this is a pre-supply chain operation, or a psycho for short.

36:36.020 --> 36:39.160
It is a broader version of the supply chain attack.

36:39.160 --> 36:47.360
Now, I think it is plausible to say, well, this is really just a fancy supply chain operation attack, but I needed some fancy mnemonic to give you to take away.

36:47.760 --> 36:50.420
So these are similar to supply chain operations.

36:50.420 --> 36:52.560
They're adversarial and surreptitious.

36:52.560 --> 37:02.560
But instead of corrupting the implementation phase, there's a greater focus on corrupting the design, standardization, and certification stages of the product.

37:03.080 --> 37:15.340
Now, if we want to actually go about doing these, this takes us a little further away from crypto qua crypto and a little closer to kind of the politics around product design.

37:15.460 --> 37:24.020
So there are a few ways that I identified that have potentially been used in the past, or that could potentially be used to conduct one of these attacks.

37:24.740 --> 37:33.560
The first is to actually create binding regulations that require people to implement products in certain ways.

37:33.660 --> 37:49.260
So one thing that you might do is rather than directly having a requirement such like you cannot, we'll talk about export restrictions in a second, but rather than putting a limit on key lengths, you might say you have to introduce support for these 30 different algorithms.

37:49.260 --> 37:56.720
And we know from the history of cryptography that the more algorithms you support, the more cryptographic agility you have, the more fragile your system becomes.

37:56.720 --> 38:03.320
If you introduce backwards compatibility, that also introduces the potential for downgrade attacks.

38:03.320 --> 38:16.050
So even without prescribing specific detailed product features, by creating a regulatory environment that introduces fragility, you can potentially encourage implementers surreptitiously to have products that are broken.

38:16.680 --> 38:20.080
The next is you can directly mandate design flaws.

38:20.080 --> 38:38.960
So we saw this with the capping of the DES key length at 56 bits, which seems likely, the reason that was likely done was to enable state level adversaries, particularly the NSA, to brute force the keys while still allowing a modicum of security for people in public who were using the algorithm.

38:40.220 --> 38:40.900
Julie C.

38:40.900 --> 38:42.920
was yet another different sort of technique.

38:42.920 --> 38:51.280
So that's going into a design and changing the standardization of parameters such that the choice of parameters are known to have a weakness.

38:51.300 --> 38:59.740
You could do this with things like Diffie-Hellman groups, which were used in the logjam attack, such that the choice of parameters admits a certain type of attack.

38:59.740 --> 39:02.800
There is a way to use the Julie C.

39:02.800 --> 39:07.940
random number generator with parameters that are verifiably what we call nothing up my sleeve.

39:07.940 --> 39:14.180
So you generate them using a hash of some innocuous phrase, and then everyone's relatively confident.

39:14.220 --> 39:20.240
But if you're able to instead hijack the process and choose the parameters yourselves, maybe you can introduce a backdoor.

39:21.240 --> 39:23.500
You can introduce intentional complexity.

39:23.500 --> 39:26.090
This kind of overlaps with the regulatory rollover.

39:26.940 --> 39:34.900
And then you can also make sure that you intentionally exclude things from the threat model of whatever standardization and certification you're using.

39:34.900 --> 39:48.300
So in this case, SP890A and FIPS 140-2 didn't include anything about side channels, which allowed me to actually perform the side channel attack because there was no hardening against any of the random number generators used there.

39:48.320 --> 40:05.680
So again, I think I'm not convinced that the NSA is using side channel attacks on a large scale, but this is still illustrative of the point that by excluding things from the threat model of the standardization process, you can make products weaker than they would be otherwise and use this as part of your nation state program.

40:06.820 --> 40:10.000
So does any of this actually apply to the real world?

40:10.000 --> 40:11.780
So I've built this lovely model.

40:11.780 --> 40:16.980
Are there any other types of attacks other than the random number generator ones for which this is vaguely plausible?

40:19.780 --> 40:28.360
So I'm going to race through a few recent examples of other standardization where this actually seems like it might have occurred.

40:28.960 --> 40:45.500
There was a family of lightweight ciphers called Simon and Speck, which had been pushed by the US in particular at the International Standards Organization, which is another standards body that probably doesn't hold quite as much weight as the FIPS standards in terms of actual implementations,

40:45.500 --> 40:48.280
but is still used by plenty of manufacturers.

40:49.040 --> 41:00.380
Ultimately, Simon and Speck were included in Linux, Android, and Android, but not for a very substantial period of time.

41:01.140 --> 41:03.660
There were a few things that were suspicious about the designs.

41:03.660 --> 41:06.260
There was no explanation of the parameter choices.

41:06.260 --> 41:13.020
The NSA design documents more were producing the design and not explaining how the design came to be.

41:13.020 --> 41:14.520
So this was a little fishy.

41:14.640 --> 41:23.920
There was a whole bunch of procedural weirdness that happened at the International Standards Organization that I think Tomer assured details in some of his works worth looking up.

41:24.700 --> 41:32.180
And as a result of Tomer and his team showing up at the ISO, they were actually able to prevent it being standardized.

41:32.340 --> 41:36.440
Had it not been for them, it seems likely like it would have gone through.

41:38.520 --> 41:42.060
So another thing that I mentioned briefly was export-grade cryptography.

41:42.060 --> 41:51.100
This seems like another pretty easy fit for this sort of threat model whereby it's not just about the adversaries who use the exported weaker cryptography.

41:51.100 --> 41:54.760
It's also about how you've changed the ecosystem as a result.

41:54.760 --> 42:05.240
TLS implementations were forced to support export-grade cryptography under the same protocol, which led to attacks such as the drown attack, which was something else that I worked on for a period of time.

42:06.360 --> 42:12.480
There are examples of other influences on parameter choices, even through the ITF.

42:12.480 --> 42:22.000
There is an RFC5114 that standardized a whole bunch of Diffie-Hellman groups.

42:22.000 --> 42:38.960
These were then used as part of the logjam attack, where the NSA presumably precomputed a portion of the computation needed to perform the number field sieve calculation to extract the discrete logs.

42:38.960 --> 42:53.860
If you're reusing the same Diffie-Hellman group over and over, and you're able to perform this partial computation, then you can complete the computation for any given handshake in a very short period of time, at least for 1024-bit groups.

42:53.900 --> 42:56.220
So there's another nice example there.

42:56.740 --> 43:05.780
And then combining this with an export downgrade attack, we were able to compromise 7% of the Alexa 1 million through the handshake.

43:05.780 --> 43:21.220
This is, again, probably another viable example of being able to actually use kind of this weird regulatory standardization process in order to achieve large-scale passive decryption as part of a state-level set of attacks.

43:23.000 --> 43:30.460
One other one, which is even more recent, this was Black Hat two years ago, was the Tetra radio encryption standard.

43:30.460 --> 43:34.560
There are a whole bunch of different sub-algorithms under the Tetra standard.

43:34.560 --> 43:39.160
The ones that were found to be flawed were TEA1 and TEA3.

43:39.200 --> 43:52.480
These are used for things like police radios for within enterprise deployments for real-world systems, oil rigs, that sort of thing, like SCADA.

43:53.320 --> 44:08.400
And there was a critical design flaw, again, introduced as part of the standardization process, which led to substantial weaknesses in the key strength reduction from what was meant to be 80 bits to something that was readily breakable on a laptop.

44:09.880 --> 44:12.620
So, putting it all together, we get this nice chart.

44:12.640 --> 44:13.700
Thank you.

44:13.720 --> 44:22.500
We get a really nice chart of, over the years, all the different attempts that I have been able to chart, at least, by which these techniques have actually been used.

44:22.520 --> 44:30.040
Now, in some of these instances, I remain unconvinced that this was an intentional malicious attempt to subvert the standard.

44:30.040 --> 44:36.100
However, some of these are still illustrative of what one might want to do were one to try and subvert a standard.

44:36.100 --> 44:45.840
And you can be sure that those on the other side to us who are trying to protect crypto are definitely taking those lessons to heart and are still trying to subvert the standards.

44:46.020 --> 44:57.740
This also leads to one interesting attack that I call the arsehole attack, which is standardization committees largely work by people being nice to each other and acting in good faith.

44:57.740 --> 45:05.600
And if someone is behaving intentionally like an arsehole, that'll put other people off and they may no longer take place in the standardization.

45:05.600 --> 45:08.980
Other people have the personality that that's just going to drive them further.

45:08.980 --> 45:17.920
But I think there is a substantial effect that is played by interpersonal dynamics on what actually comes out of these standardizations.

45:17.920 --> 45:25.120
And we know there's a long history of governments using this type of social engineering to modify policy.

45:25.120 --> 45:29.780
And so in this instance, I think we also have to apply that to crypto policy and design as well.

45:29.780 --> 45:42.220
So potentially have a deep think when you're involved in crypto standardization about kind of the rules for the road around conduct to make sure that those rules are actually facilitating a secure design process.

45:42.720 --> 45:45.900
Now, I'm going to wrap up in a couple of minutes for questions.

45:45.940 --> 45:49.800
But I have one or two more points to give you for a takeaway.

45:49.920 --> 45:57.720
Another thing is that the design of your standards organizations actually makes a difference to how easy they are to target.

45:58.100 --> 46:11.320
Something like the IETF, which prides itself on being very open and inclusive, is in a way the same version of Kirchhoff's principle, where not only is your code open, but your meetings are open.

46:11.320 --> 46:16.280
And this gives room for more people to scrutinize both the process and to participate.

46:16.680 --> 46:19.300
And this can actually be used to strengthen crypto.

46:19.460 --> 46:30.780
For something that's a lot more closed, such as prior iterations of some of the NIST process, they have since this research actually made some improvements, which I think are changing the way that standardization happens.

46:31.400 --> 46:36.000
So if you're a more closed process, that makes you more susceptible to these kinds of attacks.

46:36.000 --> 46:45.060
The ISO is a wonderful example of a process that I would not design, because for the large part, the representatives there represent countries rather than individuals.

46:45.060 --> 46:47.120
It is not an anyone-come-and-join.

46:47.120 --> 46:53.760
And it also requires long-term buy-in and long-term participation in order to actually remain part of the process.

46:53.760 --> 46:59.280
And so this kind of exclusionary factor actually can make the cryptography itself weaker in the long run.

46:59.280 --> 47:03.620
And this is very nearly what happened with Simon and Speck.

47:03.880 --> 47:15.260
The only nice thing there to say is that academic institutions give professors like me a lot of leeway to spend our time doing things that aren't always producing research papers, at least once you have tenure.

47:15.260 --> 47:18.700
And so we're in a rare place to try and be able to influence there.

47:18.980 --> 47:23.340
That said, we don't get any career rewards for saving the world from backdoored crypto.

47:23.340 --> 47:27.020
So there's only a limited amount of time that we can spend doing that.

47:27.400 --> 47:28.960
So some takeaway points.

47:28.960 --> 47:35.280
The first one, and this is what I like to hammer home more generally, is that standardization is not security.

47:35.280 --> 47:42.180
The fact that you're using a standardized algorithm does not mean that you don't have to apply any thought whatsoever to your crypto.

47:42.180 --> 47:46.460
You still have to work to ensure that your crypto implementations are robust.

47:46.460 --> 47:52.300
All of the attacks that we saw relied not just on broken standards, but also on broken implementations.

47:52.300 --> 47:57.020
So an implementation flaw combined with a broken standard led to the real world attack.

47:57.020 --> 48:00.880
That doesn't mean, like, it's somewhat understandable if you trust the standard.

48:00.880 --> 48:05.060
Not everyone has time or the ability to think through the standard themselves.

48:05.060 --> 48:11.320
But even so, if you're going to trust the standard, please still pay close attention to your implementations.

48:12.180 --> 48:15.020
And then the other thing is that certification is not an audit.

48:15.020 --> 48:27.140
Just because you've been approved by whatever the federal government's latest cryptographic module validation program is, that is not the same as having a bunch of crypto experts actually go through your code and actually think about it.

48:27.620 --> 48:32.480
So what have we learned about the way that the NSA actually breaks crypto?

48:32.540 --> 48:37.320
So there are the sexy things which I would like to imagine that the NSA has maybe done.

48:37.320 --> 48:43.560
An L of one-fourth algorithm for computing the discrete log for Diffie-Hellman mod p.

48:43.560 --> 48:44.300
That would be great.

48:44.300 --> 48:45.480
An algorithmic speed-up.

48:45.480 --> 48:46.680
They've got tons of mathematicians.

48:46.680 --> 48:48.140
Super cool, super sexy.

48:48.960 --> 48:56.460
I would love to imagine that they have some, like, secret side-channel attack thing that they're doing at scale somehow.

48:56.460 --> 49:00.200
That'd be really cool, but also probably a little less plausible.

49:00.460 --> 49:02.860
Some things that are more plausible, though.

49:02.940 --> 49:08.320
It seems unlikely that the old Diffie-Hellman attacks for pre-computation that I mentioned are still working.

49:08.800 --> 49:12.300
Some of these RNG attacks are now a bit older.

49:12.380 --> 49:15.140
And so they're likely not happening to the same extent.

49:15.140 --> 49:19.580
I do see the random number generators that are being deployed in the wild being much better.

49:19.600 --> 49:23.620
Linux has, in the last couple years, updated their one to be a lot more...

49:23.620 --> 49:29.880
There was a theoretical attack that I looked at a couple years ago that we weren't able to turn into an actual attack, but now that one's gone as well.

49:29.880 --> 49:36.200
So I think some of these attacks are becoming less plausible ways for the NSA to achieve their SIGINT goals.

49:36.580 --> 49:39.380
However, there's still a lot of value for them in the legacy attacks.

49:39.380 --> 49:45.880
There is a long tail of things on the internet that are still using legacy devices, downgrade attacks, all that kind of thing still viable.

49:46.560 --> 49:53.600
There's now a whole world of firmware attacks and ODAs that's still viable.

49:53.600 --> 49:55.240
So there's some of that still happening.

49:55.260 --> 50:03.480
Probably not on the kind of scale that one might imagine, but these regulatory attacks to undermine crypto is still happening.

50:03.480 --> 50:09.240
We're seeing this particularly in the EU with their attempts to mandate backdoors in cryptography.

50:09.240 --> 50:13.780
This happened in Australia with the access and assistance bill, and so we still have to keep our eyes open.

50:13.780 --> 50:20.440
The game is not over, and it seems likely that the NSA still has very substantial decryption capabilities.

50:21.160 --> 50:24.840
So one more slide on our takeaways.

50:25.160 --> 50:30.200
At the end of the day, our standards and certification are a target.

50:30.840 --> 50:35.280
Opaque vendor implementations of the standards are likewise a significant target.

50:35.280 --> 50:39.260
They get substantially less scrutiny, and that's where I found a lot of the problems.

50:39.440 --> 50:44.660
And then being an asshole could actually be an intentional strategy to undermine crypto.

50:45.400 --> 50:59.940
And then my final takeaway is that in practice what we saw, again, as I mentioned, is that actually breaking crypto at scale requires this beautiful intersection, beautiful in a tragic way, of both the standards corruption or standards problems with the algorithms,

50:59.940 --> 51:02.680
but then also substantial implementation flaws.

51:02.800 --> 51:05.900
Thank you very much, and I think we've got about four minutes for questions.

51:13.080 --> 51:14.280
Go for it.

51:15.800 --> 51:18.780
The slides will be posted to the DEF CON website.

51:18.780 --> 51:22.960
I'm not sure how that happens, but I can also post them to my own website.

51:22.960 --> 51:26.220
I can have that up later today, if you just put in my name.

51:29.440 --> 51:32.100
C-O-H-N-E-Y dot info.

51:32.100 --> 51:35.180
It's just a standard bio thing, but I'll put a link to the slides this afternoon.

51:36.980 --> 51:38.160
Anything else?

51:54.670 --> 51:57.910
So some of this research is getting a little bit longer in the tooth.

51:57.910 --> 52:06.470
I think it's interesting to consider in the context, but if you Google scholar my name, all the crypto papers are largely on this line of work.

52:06.710 --> 52:08.130
Same thing with the website.

52:08.250 --> 52:14.650
But I'm happy to update, try and get the DEF CON hacker tracker updated to as well include some of those in the references.

52:31.670 --> 52:37.250
Yeah, so I think for the most part we're feeling a lot more comfortable about the way that things have been done recently.

52:37.830 --> 52:39.690
So there's a mix of factors leading to this.

52:39.690 --> 52:51.110
Some of it is formally verified implementations, formal proofs of the protocols, which is different from formally verifying the implementations, and also changes to the way that standardization occurs.

52:51.490 --> 53:02.130
We have a couple of ideas on where there might be still some more problematic designs out there, whether backdoored or not, but so far nothing that we can really point to.

53:02.130 --> 53:06.270
Just some bad feelings at the back of our heads.

53:25.590 --> 53:28.250
Largely standardizing around

53:34.990 --> 53:43.490
, because that's now understood, it's easy to get guessbooks for it, not to start moving through the process.

53:43.830 --> 53:56.950
Is that something you've looked at yourself with your team, as far as the goodness of CPU jitter as an actual use case?

53:57.350 --> 54:11.050
So I think, like, if I had to build an RNG today, what I would first do is I'd use the CPU instruction to generate output, and then I'd run that output through a cryptographic RNG with CPU jitter, plus other sources of entropy.

54:11.350 --> 54:19.410
There's one in SP-890A that I still think is a pretty good design, HMAC-DRBG, which uses a hash function, so it's one way.

54:19.410 --> 54:20.090
And

54:35.760 --> 54:49.140
being able to serve, to validate the entropy source, if you rely on the CPU jitter, et cetera, it's a fast, pain in the ass process, practically, from a product development standpoint.

54:49.620 --> 54:52.200
But I understand that that is a...

54:52.200 --> 54:52.720
Yeah.

54:54.160 --> 54:56.800
Okay, thank you very much, everyone.

