WEBVTT - This file was automatically generated by VIMEO

0
00:00:07.200 --> 00:00:09.900
in our second video of public key cryptography

1
00:00:10.700 --> 00:00:13.600
We'll see in details the diffee-helman key

2
00:00:13.600 --> 00:00:13.800
 agreement.

3
00:00:14.800 --> 00:00:17.500
And the one-way function that is fundamental to

4
00:00:17.500 --> 00:00:19.500
 proving the security of this protocol.

5
00:00:20.800 --> 00:00:23.700
We'll also look at the attack site and study

6
00:00:23.700 --> 00:00:26.000
 men in the middle attack on this protocol.

7
00:00:27.200 --> 00:00:28.300
So let's get started.

8
00:00:30.500 --> 00:00:35.300
Okay, before explaining diffie-hellman key

9
00:00:34.300 --> 00:00:37.400
 agreement protocol. We need to

10
00:00:37.400 --> 00:00:40.900
 Define some mathematical Concepts.

11
00:00:42.200 --> 00:00:45.400
For that we'll revisit the finite fields that

12
00:00:45.400 --> 00:00:47.500
 we have seen with a yes algorithm.

13
00:00:48.300 --> 00:00:51.500
This time we'll use a similar finite

14
00:00:51.500 --> 00:00:54.500
 field to the gf28 that we have seen for a

15
00:00:54.500 --> 00:00:54.800
 yes.

16
00:00:55.700 --> 00:00:58.800
We'll use what we call Prime finite fields.

17
00:00:59.700 --> 00:01:02.600
I think these fields are easier to visualize than

18
00:01:02.600 --> 00:01:03.700
 the shift to it.

19
00:01:05.300 --> 00:01:08.000
So to define a prime finite field, we need

20
00:01:08.500 --> 00:01:08.900
 a prime number.

21
00:01:09.800 --> 00:01:12.200
I hope everyone is familiar with the

22
00:01:12.200 --> 00:01:13.600
 concept of prime numbers.

23
00:01:14.800 --> 00:01:19.100
And the operation module will need them to understand

24
00:01:18.100 --> 00:01:23.700
 the mathematics of dvlm

25
00:01:22.700 --> 00:01:24.700
 and key climate protocol.

26
00:01:25.200 --> 00:01:29.100
So if you are not familiar with this concept, please stop

27
00:01:28.100 --> 00:01:31.300
 the video and Google them. It will

28
00:01:31.300 --> 00:01:34.500
 take you a couple of minutes to review prime numbers

29
00:01:34.500 --> 00:01:36.400
 and the operation module.

30
00:01:38.500 --> 00:01:42.300
So we Define the finite

31
00:01:41.300 --> 00:01:45.700
 field as the set of integers modulo

32
00:01:44.700 --> 00:01:46.700
 the prime B.

33
00:01:47.600 --> 00:01:50.200
So the integers from 0 all the

34
00:01:50.200 --> 00:01:51.100
 way to P minus 1.

35
00:01:51.800 --> 00:01:54.700
And we can have arithmetic over these numbers.

36
00:01:55.400 --> 00:01:56.300
Let's take an example.

37
00:01:57.600 --> 00:02:00.800
For p equal to 5. We defines it

38
00:02:00.800 --> 00:02:03.700
 5 as the set of integers 0 1

39
00:02:03.700 --> 00:02:04.100
 2 3 4

40
00:02:04.900 --> 00:02:05.900
and we can have

41
00:02:07.600 --> 00:02:11.500
addition as well as multiplication on

42
00:02:10.500 --> 00:02:13.800
 this Prime Finance

43
00:02:13.800 --> 00:02:13.900
 field.

44
00:02:14.700 --> 00:02:17.300
So for example 2 plus 2 is

45
00:02:17.300 --> 00:02:18.600
 equal to 4.

46
00:02:19.900 --> 00:02:22.900
And 3 plus 3 is

47
00:02:22.900 --> 00:02:25.500
 equal to 6 module 5.

48
00:02:25.500 --> 00:02:26.300
 That's 1

49
00:02:27.600 --> 00:02:30.400
4 plus 2 for example is equal to

50
00:02:30.400 --> 00:02:34.000
 6 as well. So module 5, that's

51
00:02:33.000 --> 00:02:34.200
 1

52
00:02:34.900 --> 00:02:37.600
so similarly we can have a multiplication.

53
00:02:37.600 --> 00:02:39.100
 So for instance.

54
00:02:40.500 --> 00:02:43.900
2 times 4 that's 8 and as

55
00:02:43.900 --> 00:02:46.400
 we are working module 5, so the result is

56
00:02:46.400 --> 00:02:47.000
 3.

57
00:02:48.700 --> 00:02:50.800
Etc so please take your time to

58
00:02:51.800 --> 00:02:55.200
Look at this table to better understand what

59
00:02:54.200 --> 00:02:57.200
 are prime finite Fields through

60
00:02:57.200 --> 00:02:58.800
 this example of Z5?

61
00:03:00.300 --> 00:03:03.200
Okay, as we defined multiplication we can

62
00:03:03.200 --> 00:03:05.100
 also Define exponentiation.

63
00:03:05.700 --> 00:03:08.300
the exponentiation of an element

64
00:03:08.300 --> 00:03:12.200
 G of the finite field to an

65
00:03:11.200 --> 00:03:14.500
 exponent x is the value y

66
00:03:15.100 --> 00:03:18.800
which is equal to G raised to X module

67
00:03:18.800 --> 00:03:21.900
 P. So G multiplied by itself X

68
00:03:21.900 --> 00:03:24.200
 time module p is that

69
00:03:24.200 --> 00:03:27.200
 5 3 raise to one is equal to 3

70
00:03:27.200 --> 00:03:30.400
 which module 5 which is equal to 3.

71
00:03:31.500 --> 00:03:34.400
Free raise to 2 module 5

72
00:03:34.400 --> 00:03:37.400
 is equal to 3 times 3 module 5

73
00:03:37.400 --> 00:03:40.200
 is equal to 9 or 05, which is equal

74
00:03:40.200 --> 00:03:41.100
 to 4.

75
00:03:42.200 --> 00:03:45.600
the exponential of 3 to the power

76
00:03:45.600 --> 00:03:48.500
 3 what you find is equal to 3 times

77
00:03:48.500 --> 00:03:50.000
 3 times 3 0 5

78
00:03:50.700 --> 00:03:53.200
she is equal to 27 more 05 which is

79
00:03:53.200 --> 00:03:54.000
 equal to 2.

80
00:03:55.400 --> 00:03:58.600
We defined a discrete logarithm

81
00:03:58.600 --> 00:04:02.100
 operation as the reverse of the exponentiation.

82
00:04:03.100 --> 00:04:06.400
So given element Y and the basis G.

83
00:04:07.300 --> 00:04:11.000
The discrete logarithm of Y in this pieces is

84
00:04:10.600 --> 00:04:13.800
 the exponent x such that

85
00:04:13.800 --> 00:04:16.600
 why is written as G

86
00:04:16.600 --> 00:04:18.600
 power x module?

87
00:04:19.800 --> 00:04:22.400
So for example in Z5 we have seen

88
00:04:22.400 --> 00:04:25.100
 that three raised to

89
00:04:25.100 --> 00:04:26.000
 one is equal to 3.

90
00:04:26.700 --> 00:04:29.000
So the discrete logarithm of three.

91
00:04:29.900 --> 00:04:32.300
In the basis 3 is the value

92
00:04:32.300 --> 00:04:33.000
 1.

93
00:04:34.700 --> 00:04:38.500
And similarly we have seen that four is

94
00:04:38.500 --> 00:04:39.500
 equal to 3.

95
00:04:40.700 --> 00:04:43.800
power 2 that's 5 so the discrete

96
00:04:43.800 --> 00:04:46.100
 logarithm of 4 in the basis 3

97
00:04:46.100 --> 00:04:47.600
 is 2

98
00:04:48.400 --> 00:04:51.600
and similarly as well. We have seen that two can

99
00:04:51.600 --> 00:04:54.400
 be written as 3 power 3 what you

100
00:04:54.400 --> 00:04:57.700
 Rule 5 so the discrete algorithm of two in the

101
00:04:57.700 --> 00:05:00.200
 base of 3 is 3 itself.

102
00:05:01.100 --> 00:05:04.300
Using exponentiation and discrete logarithm we can

103
00:05:04.300 --> 00:05:07.200
 construct the one-way function that we need for the

104
00:05:07.200 --> 00:05:08.900
 diffee-helman key limit.

105
00:05:09.800 --> 00:05:12.500
in fact when p is quite big

106
00:05:13.200 --> 00:05:17.000
by big women like thousands of bit

107
00:05:16.000 --> 00:05:17.200
 long.

108
00:05:18.500 --> 00:05:21.700
Computing the exponentiation is still feasible and

109
00:05:21.700 --> 00:05:24.100
 can be done very efficiently.

110
00:05:24.800 --> 00:05:25.400
It will take.

111
00:05:26.400 --> 00:05:28.300
Less than a second using your laptop.

112
00:05:29.200 --> 00:05:32.600
However going the other way so Computing the discrete

113
00:05:32.600 --> 00:05:33.500
 logarithm of an element.

114
00:05:34.400 --> 00:05:37.600
In finite field of this length, like

115
00:05:37.600 --> 00:05:40.300
 thousands of bits is a hard problem.

116
00:05:40.300 --> 00:05:43.600
 It will take more than hundreds of years using today's

117
00:05:43.600 --> 00:05:44.200
 laptop.

118
00:05:46.200 --> 00:05:49.600
Let's better clarify the sort of challenge related to

119
00:05:49.600 --> 00:05:51.900
 Computing discrete logarithm.

120
00:05:52.900 --> 00:05:55.700
Let's imagine Alice that has

121
00:05:55.700 --> 00:05:58.400
 chosen some prime field. Zp.

122
00:05:59.700 --> 00:06:03.000
So she has already chose the value

123
00:06:02.300 --> 00:06:05.300
 p and g as an element

124
00:06:05.300 --> 00:06:06.500
 of ZB.

125
00:06:07.300 --> 00:06:10.600
and she picked an exponent x

126
00:06:11.500 --> 00:06:14.500
and computed y as the

127
00:06:14.500 --> 00:06:17.100
 power of G to X module p

128
00:06:18.100 --> 00:06:21.600
and there is sort of public board where she can publish data.

129
00:06:21.600 --> 00:06:25.300
 So Alice publishes PG and

130
00:06:24.300 --> 00:06:25.800
 why?

131
00:06:27.900 --> 00:06:30.800
Anniversary can get a PG and Y and the

132
00:06:30.800 --> 00:06:33.900
 challenge that the adversary wants to solve is to

133
00:06:33.900 --> 00:06:36.900
 retrieve the secret exponent x from

134
00:06:36.900 --> 00:06:37.400
 y.

135
00:06:38.600 --> 00:06:41.100
This is called discrete logarithm problem.

136
00:06:42.200 --> 00:06:45.500
And this challenge is the fundamental brick for the

137
00:06:45.500 --> 00:06:47.500
 security of the Herman protocol.

138
00:06:48.500 --> 00:06:52.300
If network is able to break this discrete

139
00:06:51.300 --> 00:06:54.000
 algorithm problem, it will be able to

140
00:06:54.600 --> 00:06:56.900
 break the security of the animal protocol.

141
00:06:58.500 --> 00:07:01.300
Today if Prime P that we

142
00:07:01.300 --> 00:07:05.500
 Alice is using is at least of length 1024

143
00:07:04.500 --> 00:07:05.900
 bits.

144
00:07:06.600 --> 00:07:09.400
Then we consider the discrete logarithm

145
00:07:09.400 --> 00:07:12.400
 problem to be computationally very difficult.

146
00:07:14.200 --> 00:07:17.400
the largest record of computing discrete logarithm

147
00:07:17.400 --> 00:07:17.600
 problem

148
00:07:18.400 --> 00:07:21.900
was on a field with a prime of length

149
00:07:21.900 --> 00:07:23.900
 795 bits.

150
00:07:24.800 --> 00:07:28.100
This was realized in 2019 by team

151
00:07:27.100 --> 00:07:30.300
 of researchers that use the

152
00:07:30.300 --> 00:07:31.400
 sophisticated algorithm.

153
00:07:32.300 --> 00:07:35.600
and an important high performance Computing

154
00:07:35.600 --> 00:07:36.300
 infrastructure

155
00:07:37.300 --> 00:07:40.800
So for Lambda hacker, it

156
00:07:40.800 --> 00:07:43.900
 will be costly to break

157
00:07:43.900 --> 00:07:47.600
 a DLP of 795 bits.

158
00:07:48.500 --> 00:07:52.700
That's why we consider the length 1024 which

159
00:07:52.700 --> 00:07:55.800
 is much harder than 795 to

160
00:07:55.800 --> 00:07:57.300
 be secure enough.

161
00:07:58.900 --> 00:08:01.200
Here you find a link to

162
00:08:01.200 --> 00:08:04.500
 Wikipedia page with all the

163
00:08:04.500 --> 00:08:07.400
 records of discrete algorithm problem in the

164
00:08:07.400 --> 00:08:10.000
 last 10 to 15 years. So feel free to

165
00:08:10.500 --> 00:08:14.800
 consult it to know more about the history of this discrete

166
00:08:13.800 --> 00:08:15.300
 logarithm.

167
00:08:16.100 --> 00:08:17.100
problem records

168
00:08:18.800 --> 00:08:21.900
In 2015, there was vulnerability

169
00:08:21.900 --> 00:08:25.200
 found by team of researchers. This was

170
00:08:24.200 --> 00:08:26.600
 called Log Jam attack.

171
00:08:27.500 --> 00:08:31.100
This attack used variability in

172
00:08:30.100 --> 00:08:34.700
 servers that used primes

173
00:08:34.700 --> 00:08:37.100
 of length 512 bits.

174
00:08:37.900 --> 00:08:41.000
And by because DLP

175
00:08:40.200 --> 00:08:41.300
 is not.

176
00:08:42.200 --> 00:08:46.100
hard in such with such lengths

177
00:08:45.100 --> 00:08:46.600
 of primes

178
00:08:47.300 --> 00:08:49.000
this attack was possible.

179
00:08:50.200 --> 00:08:54.900
And they showed that actually several servers

180
00:08:54.900 --> 00:08:58.100
 a large percentage of the servers

181
00:08:57.100 --> 00:09:01.000
 that are used on internet around

182
00:09:00.600 --> 00:09:03.300
 5 to 10% of them

183
00:09:03.300 --> 00:09:06.600
 were actually vulnerable to this attack and

184
00:09:06.600 --> 00:09:09.200
 their security could be compromised.

185
00:09:11.900 --> 00:09:12.100
Okay.

186
00:09:13.100 --> 00:09:16.300
Not we understood the mathematics of the exponentiation and

187
00:09:16.300 --> 00:09:20.300
 discrete logarithm. We can see how Diffie and

188
00:09:20.300 --> 00:09:24.000
 element use these one-way functions to construct

189
00:09:23.900 --> 00:09:26.300
 a key agreement protocol.

190
00:09:27.200 --> 00:09:30.600
Okay, so let me remind you the setting so we

191
00:09:30.600 --> 00:09:33.100
 have two parties Alice and

192
00:09:33.100 --> 00:09:36.700
 Bob who would like to create shared key

193
00:09:36.700 --> 00:09:40.400
 and Alice and Bob are communicating over

194
00:09:39.400 --> 00:09:42.800
 in unsecure Channel

195
00:09:42.800 --> 00:09:45.200
 where there is an adversary that

196
00:09:45.200 --> 00:09:47.800
 is intercepting their messages.

197
00:09:48.900 --> 00:09:51.400
So Ellis and pop agree on

198
00:09:51.400 --> 00:09:54.400
 a prime field. Does it be and on

199
00:09:54.400 --> 00:09:55.800
 an element G?

200
00:09:57.300 --> 00:10:00.600
After that at least speaks an exponent x x

201
00:10:00.600 --> 00:10:04.400
 a and computes the value ya as

202
00:10:03.400 --> 00:10:06.800
 the value G raised to

203
00:10:06.800 --> 00:10:09.400
 the exponent XA module p and

204
00:10:09.400 --> 00:10:12.000
 she sends that to a bob.

205
00:10:13.700 --> 00:10:16.500
Similarly Bob picks an exponent XP and

206
00:10:16.500 --> 00:10:20.000
 computes YB as the power of

207
00:10:19.300 --> 00:10:22.400
 G to his exponent XB and

208
00:10:22.400 --> 00:10:24.100
 send it to Alice.

209
00:10:25.500 --> 00:10:28.500
now at least computes the key as

210
00:10:29.500 --> 00:10:33.500
the value YB that she received from Bob raised

211
00:10:32.500 --> 00:10:35.000
 to her exponent XA.

212
00:10:36.300 --> 00:10:39.700
and Bob computes the value

213
00:10:39.700 --> 00:10:41.300
 K as

214
00:10:42.100 --> 00:10:45.400
the ya received from Alice raised to his exponent

215
00:10:45.400 --> 00:10:46.300
 XP.

216
00:10:47.600 --> 00:10:49.400
the functional guarantee from

217
00:10:51.700 --> 00:10:54.500
different key agreement protocol is that

218
00:10:54.500 --> 00:10:58.000
 these two keys are equal even that

219
00:10:57.200 --> 00:11:00.800
 they were computed with different formulas the

220
00:11:00.800 --> 00:11:01.800
 values much.

221
00:11:02.800 --> 00:11:05.200
You can verify that by looking at

222
00:11:05.200 --> 00:11:09.100
 this formulas here. So actually what at

223
00:11:08.100 --> 00:11:12.100
 least computed is the following YB, raise

224
00:11:11.100 --> 00:11:14.200
 to x a module B, which we can write

225
00:11:14.200 --> 00:11:17.200
 as G power XP first.

226
00:11:18.300 --> 00:11:18.900
power XA

227
00:11:20.200 --> 00:11:23.900
We can write it as the product of exponents and

228
00:11:23.900 --> 00:11:26.400
 as the product is commutative we can.

229
00:11:27.300 --> 00:11:30.800
Write it as G raised to XA times XP.

230
00:11:30.800 --> 00:11:33.600
 Then this is equal actually

231
00:11:33.600 --> 00:11:36.100
 to G raise to x a

232
00:11:36.800 --> 00:11:40.200
raise to XP which is y a raised

233
00:11:39.200 --> 00:11:42.300
 to XP module p

234
00:11:43.900 --> 00:11:46.800
So this is the functional guarantee and

235
00:11:46.800 --> 00:11:48.100
 the security guarantee.

236
00:11:48.900 --> 00:11:51.800
Is that if p is big

237
00:11:51.800 --> 00:11:54.300
 enough then the discrete logarithm problem

238
00:11:54.300 --> 00:11:57.300
 is computationally hard. So the

239
00:11:57.300 --> 00:12:01.000
 adversary cannot extract the exponents

240
00:12:00.100 --> 00:12:04.000
 XA and XB from ya

241
00:12:03.400 --> 00:12:04.800
 and Y.

242
00:12:05.500 --> 00:12:08.100
If he cannot do that, he will not

243
00:12:08.100 --> 00:12:11.400
 be able to compute key with one of

244
00:12:11.400 --> 00:12:12.900
 these two formulas.

245
00:12:14.700 --> 00:12:18.000
The protocol we described in the previous slide is

246
00:12:17.500 --> 00:12:21.000
 called the ephemeral version of dvl

247
00:12:20.200 --> 00:12:22.000
 monkey agreement protocol.

248
00:12:23.100 --> 00:12:27.100
In the ephemeral version both exponents XA

249
00:12:26.100 --> 00:12:30.000
 XP and Powers ya

250
00:12:29.200 --> 00:12:32.700
 and YB are refreshed and destroyed

251
00:12:32.700 --> 00:12:34.400
 after the protocol is completed.

252
00:12:35.500 --> 00:12:38.600
And the generated key K is

253
00:12:38.600 --> 00:12:41.800
 meant to be used during the session and is discarded

254
00:12:41.800 --> 00:12:42.100
 afterward.

255
00:12:42.900 --> 00:12:45.200
So for example if Alice is some

256
00:12:45.200 --> 00:12:48.400
 server and Bobby some client then they will

257
00:12:48.400 --> 00:12:51.500
 run this protocol to construct the key K. And

258
00:12:51.500 --> 00:12:54.600
 after that they will use

259
00:12:54.600 --> 00:12:58.100
 that key K to do some symmetry key

260
00:12:57.100 --> 00:13:00.600
 encryption. And once that session

261
00:13:00.600 --> 00:13:03.700
 is finished, they will destroy all the

262
00:13:03.700 --> 00:13:06.200
 session key, but also

263
00:13:06.200 --> 00:13:10.800
 the exponents that they needed to generate

264
00:13:09.800 --> 00:13:11.200
 this key.

265
00:13:12.600 --> 00:13:15.500
We can also have a static version of the

266
00:13:15.500 --> 00:13:18.300
 key agreement protocol in which the

267
00:13:18.300 --> 00:13:21.600
 exponents xnxb are

268
00:13:21.600 --> 00:13:24.400
 long-term secret keys and the

269
00:13:24.400 --> 00:13:27.800
 powers ya and YB are long-term public

270
00:13:27.800 --> 00:13:28.300
 keys.

271
00:13:29.300 --> 00:13:32.500
The advantage of this version is that we don't need

272
00:13:32.500 --> 00:13:35.900
 communication as the parties

273
00:13:35.900 --> 00:13:38.600
 know each other public keys and

274
00:13:38.600 --> 00:13:41.700
 they don't need to compute the key k each

275
00:13:41.700 --> 00:13:44.100
 time because it is

276
00:13:44.100 --> 00:13:44.500
 static.

277
00:13:45.700 --> 00:13:48.400
So this version is

278
00:13:48.400 --> 00:13:51.200
 very efficient, but in terms

279
00:13:51.200 --> 00:13:54.100
 of security, it does not provide the same

280
00:13:54.100 --> 00:13:57.200
 level of security as for the ephemeral version.

281
00:13:58.400 --> 00:14:01.100
For static version, there is

282
00:14:01.100 --> 00:14:02.600
 no forward secrecy.

283
00:14:03.500 --> 00:14:05.400
the notion of storage secrecy

284
00:14:06.200 --> 00:14:10.200
is related to the disclosure of the secrets. So

285
00:14:09.200 --> 00:14:13.100
 for the static version

286
00:14:12.100 --> 00:14:15.200
 if there is disclosure of

287
00:14:15.200 --> 00:14:19.400
 XA or XB then this eventually compromises

288
00:14:18.400 --> 00:14:21.800
 the key K and the

289
00:14:21.800 --> 00:14:24.000
 confidentiality of all messages encrypted with

290
00:14:24.300 --> 00:14:25.400
 the key will be

291
00:14:26.700 --> 00:14:27.900
compromise as well.

292
00:14:28.800 --> 00:14:30.400
while for ephemeral version

293
00:14:31.100 --> 00:14:34.400
the disclosure of the exponent XA or

294
00:14:34.400 --> 00:14:34.700
 xB

295
00:14:35.300 --> 00:14:38.300
compromise only the key of that session and the

296
00:14:38.300 --> 00:14:41.200
 keys of the other sessions are not compromised.

297
00:14:42.100 --> 00:14:42.300
so

298
00:14:43.200 --> 00:14:46.000
the ephemeral version provides a higher level

299
00:14:46.400 --> 00:14:46.900
 of security.

300
00:14:49.100 --> 00:14:53.000
For the key agreement protocol to be secure. I

301
00:14:52.200 --> 00:14:55.400
 listen Bob must communicate over Channel

302
00:14:55.400 --> 00:14:57.000
 which provides Authentication?

303
00:14:58.600 --> 00:15:01.600
Otherwise the key agreement protocol is vulnerable to

304
00:15:01.600 --> 00:15:03.100
 men in the middle letter.

305
00:15:04.300 --> 00:15:06.900
Let's see in detail this man in the middle attack.

306
00:15:08.300 --> 00:15:12.200
Assuming that the messages are not authenticated an adversary

307
00:15:11.200 --> 00:15:14.900
 that sits in the middle can run concrete

308
00:15:14.900 --> 00:15:16.900
 protocols with at least end up.

309
00:15:18.600 --> 00:15:21.700
First the adversary runs a

310
00:15:21.700 --> 00:15:24.500
 DV Herman protocol with Alice to construct

311
00:15:24.500 --> 00:15:25.900
 a first key K1.

312
00:15:27.500 --> 00:15:30.500
then he runs the second protocol with Bob

313
00:15:30.500 --> 00:15:33.000
 to construct a second key to

314
00:15:34.300 --> 00:15:37.200
At this step I listen Bob. We think that

315
00:15:37.200 --> 00:15:40.600
 they share the key with each other, but actually they

316
00:15:40.600 --> 00:15:43.000
 share two keys with the management.

317
00:15:44.900 --> 00:15:47.300
As we mentioned before the purpose of

318
00:15:47.300 --> 00:15:50.400
 constructing a common key is to use this key

319
00:15:50.400 --> 00:15:52.700
 for symmetric key encryption.

320
00:15:53.500 --> 00:15:56.300
So once the constructed the

321
00:15:56.300 --> 00:15:59.800
 shared key a list and Bob will encrypt messages

322
00:15:59.800 --> 00:16:02.900
 and decrypt ciphertext using this key.

323
00:16:04.500 --> 00:16:07.300
So what the adversary will do is that he will

324
00:16:07.300 --> 00:16:08.400
 continue to sit in the middle.

325
00:16:10.500 --> 00:16:13.500
Let's imagine that Alice sends a message wants to

326
00:16:13.500 --> 00:16:14.600
 send a message to ball.

327
00:16:15.300 --> 00:16:18.200
So she will use the key K1 that she

328
00:16:18.200 --> 00:16:21.600
 thinks is shared with Bob to encrypt

329
00:16:21.600 --> 00:16:22.000
 her message.

330
00:16:22.900 --> 00:16:24.800
And she sends the ciphertext.

331
00:16:25.900 --> 00:16:28.500
the men in the middle intercepts the ciphertext

332
00:16:29.200 --> 00:16:31.500
decrypted gets the information.

333
00:16:32.700 --> 00:16:35.600
And then re-encrypts it with the key K2 and

334
00:16:35.600 --> 00:16:36.900
 send it to pop.

335
00:16:38.100 --> 00:16:41.300
Uses the key K2 to decrypt the

336
00:16:41.300 --> 00:16:44.300
 message because he thinks that that's the key

337
00:16:44.300 --> 00:16:47.100
 that he shares with Alice.

338
00:16:47.800 --> 00:16:49.200
And he will get the information.

339
00:16:51.200 --> 00:16:54.400
This way the adversary can continue to listen to

340
00:16:54.400 --> 00:16:57.400
 their messages and Allison Bob will not

341
00:16:57.400 --> 00:16:57.900
 notice.

342
00:16:59.300 --> 00:17:02.200
Even worse the men in

343
00:17:02.200 --> 00:17:05.800
 the middle can even modify the message and really

344
00:17:05.800 --> 00:17:07.300
 encrypted the way he wants.

345
00:17:08.100 --> 00:17:11.600
Alice and Bob will not notice unless they

346
00:17:11.600 --> 00:17:14.400
 have some Integrity check a mechanism

347
00:17:14.400 --> 00:17:18.200
 that is run on another Channel

348
00:17:17.200 --> 00:17:19.500
 some side Channel.

349
00:17:21.500 --> 00:17:25.100
In this video we discussed the diffie-hellman key

350
00:17:24.100 --> 00:17:27.700
 agreement protocol that allows two parties

351
00:17:27.700 --> 00:17:30.500
 to jointly establish a shared secret

352
00:17:30.500 --> 00:17:32.900
 key over and insecure Channel.

353
00:17:34.100 --> 00:17:37.900
We have seen how exponentiation and discrete logarithmic Prime

354
00:17:37.900 --> 00:17:40.700
 Fields allowed us to construct

355
00:17:40.700 --> 00:17:44.200
 the secure one. We function that deviant Airman

356
00:17:43.200 --> 00:17:46.800
 used to construct their key limit

357
00:17:46.800 --> 00:17:47.200
 protocol.

358
00:17:48.100 --> 00:17:51.400
We also discussed the many the middle attack that can apply for

359
00:17:51.400 --> 00:17:54.200
 settings with non-authentication.

360
00:17:55.600 --> 00:17:58.300
Deviatement protocol is an elegant and secure

361
00:17:58.300 --> 00:17:58.700
 protocol.

362
00:17:59.400 --> 00:18:02.400
Of course, as long as the size of the Prime is big enough

363
00:18:02.400 --> 00:18:04.700
 and that there is Authentication.

364
00:18:05.600 --> 00:18:08.800
It is used in a variety of Internet services for

365
00:18:08.800 --> 00:18:10.900
 instance in the TLs protocol.

366
00:18:12.400 --> 00:18:15.700
In the next video, we'll move to discuss another important

367
00:18:15.700 --> 00:18:18.900
 algorithm in public key cryptography, which

368
00:18:18.900 --> 00:18:21.100
 is the RSA group system.

369
00:18:21.900 --> 00:18:23.400
So see you in the next video.
