Commit dfd1bb2
committed
Wrap JWKSet parsing errors in InvalidJWKValue
Moved the dictionary iteration and key creation logic inside the try-except
block. This ensures that any exceptions raised during the instantiation of
individual JWK objects or validation checks are properly caught and safely re-
raised as an InvalidJWKValue exception, rather than leaking unhandled errors.
Assisted-by: Gemini <gemini@google.com>
Signed-off-by: Simo Sorce <simo@redhat.com>1 parent db03d4c commit dfd1bb2
2 files changed
Lines changed: 24 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1356 | 1356 | | |
1357 | 1357 | | |
1358 | 1358 | | |
| 1359 | + | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
| 1363 | + | |
| 1364 | + | |
| 1365 | + | |
| 1366 | + | |
| 1367 | + | |
1359 | 1368 | | |
1360 | 1369 | | |
1361 | 1370 | | |
1362 | | - | |
1363 | | - | |
1364 | | - | |
1365 | | - | |
1366 | | - | |
1367 | | - | |
1368 | | - | |
1369 | | - | |
1370 | | - | |
1371 | | - | |
1372 | 1371 | | |
1373 | 1372 | | |
1374 | 1373 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
562 | 562 | | |
563 | 563 | | |
564 | 564 | | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
565 | 580 | | |
566 | 581 | | |
567 | 582 | | |
| |||
0 commit comments