Commit 11b50d3
authored
OpenSSL CVE-2022-0778 Fix possible infinite loop in BN_mod_sqrt() (#423)
OpenSSL CVE-2022-0778 Fix possible infinite loop in BN_mod_sqrt()
This commit fixes the issue released as OpenSSL CVE-2022-0778 that
affects AWS-LC as well. A bug in BN_mod_sqrt() can cause the function
to enter an infinite loop. The issue is now fixed and two test
cases are added to verify that the function returns a failure instead
of hanging.
Co-authored-by: Dusan Kostic <[email protected]>1 parent 5159ff5 commit 11b50d3
File tree
3 files changed
+32
-22
lines changed- crypto/fipsmodule/bn
- generated-src
3 files changed
+32
-22
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11149 | 11149 | | |
11150 | 11150 | | |
11151 | 11151 | | |
11152 | | - | |
| 11152 | + | |
| 11153 | + | |
11153 | 11154 | | |
11154 | 11155 | | |
11155 | 11156 | | |
| |||
11163 | 11164 | | |
11164 | 11165 | | |
11165 | 11166 | | |
| 11167 | + | |
| 11168 | + | |
| 11169 | + | |
| 11170 | + | |
| 11171 | + | |
11166 | 11172 | | |
11167 | 11173 | | |
11168 | 11174 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
| 65 | + | |
| 66 | + | |
66 | 67 | | |
67 | 68 | | |
68 | 69 | | |
| |||
359 | 360 | | |
360 | 361 | | |
361 | 362 | | |
362 | | - | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
373 | 373 | | |
374 | | - | |
375 | | - | |
| 374 | + | |
| 375 | + | |
376 | 376 | | |
377 | 377 | | |
378 | | - | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
379 | 383 | | |
380 | 384 | | |
381 | 385 | | |
| |||
0 commit comments