Commit 56b3d22
committed
Add support for authenticating forwarding blinded path contexts
In the previous commit we added support for authenticating received
blinded paths by using an additional secret as the AAD in the MAC.
Here, we extend this to support authenticating blinded path
contexts received for forwarding, allowing us to authenticate dummy
hops added as padding. This will allow us to prevent a DoS attack
where someone could create a blinded path which has many forwarding
hops all for us as fictitious dummy hops, requiring us to decrypt
many times only to find no useful onion message.1 parent 1725a3b commit 56b3d22
2 files changed
+58
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1120 | 1120 | | |
1121 | 1121 | | |
1122 | 1122 | | |
1123 | | - | |
1124 | | - | |
1125 | | - | |
1126 | | - | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
1127 | 1130 | | |
1128 | 1131 | | |
1129 | 1132 | | |
1130 | 1133 | | |
1131 | 1134 | | |
1132 | 1135 | | |
1133 | 1136 | | |
| 1137 | + | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
1134 | 1148 | | |
1135 | 1149 | | |
1136 | 1150 | | |
| |||
2251 | 2265 | | |
2252 | 2266 | | |
2253 | 2267 | | |
2254 | | - | |
2255 | | - | |
2256 | | - | |
2257 | | - | |
| 2268 | + | |
| 2269 | + | |
| 2270 | + | |
| 2271 | + | |
| 2272 | + | |
| 2273 | + | |
| 2274 | + | |
2258 | 2275 | | |
2259 | 2276 | | |
2260 | 2277 | | |
| |||
2263 | 2280 | | |
2264 | 2281 | | |
2265 | 2282 | | |
2266 | | - | |
2267 | | - | |
2268 | | - | |
2269 | | - | |
| 2283 | + | |
| 2284 | + | |
| 2285 | + | |
| 2286 | + | |
| 2287 | + | |
| 2288 | + | |
| 2289 | + | |
2270 | 2290 | | |
2271 | 2291 | | |
2272 | 2292 | | |
2273 | 2293 | | |
2274 | 2294 | | |
2275 | 2295 | | |
2276 | | - | |
| 2296 | + | |
| 2297 | + | |
| 2298 | + | |
| 2299 | + | |
2277 | 2300 | | |
2278 | 2301 | | |
2279 | 2302 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
113 | | - | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
114 | 123 | | |
115 | 124 | | |
116 | 125 | | |
| |||
220 | 229 | | |
221 | 230 | | |
222 | 231 | | |
223 | | - | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
224 | 236 | | |
225 | 237 | | |
226 | 238 | | |
| |||
235 | 247 | | |
236 | 248 | | |
237 | 249 | | |
238 | | - | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
239 | 254 | | |
240 | 255 | | |
241 | 256 | | |
| |||
314 | 329 | | |
315 | 330 | | |
316 | 331 | | |
317 | | - | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
318 | 336 | | |
319 | 337 | | |
320 | 338 | | |
| |||
0 commit comments