Commit 8bede63
committed
fix(component-tests): dynamic import invocation without existence check
A module loader function is resolved from `metaGlobComponents[componentPath]` and invoked without verifying it exists. A crafted route param that does not match a key can result in invoking `undefined`, causing runtime errors and potential repeated 500 responses (DoS-by-error for that endpoint).
Signed-off-by: tomaioo <203048277+tomaioo@users.noreply.github.com>1 parent 3fda36b commit 8bede63
1 file changed
Lines changed: 14 additions & 3 deletions
Lines changed: 14 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | | - | |
16 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
17 | 28 | | |
18 | 29 | | |
19 | 30 | | |
| |||
0 commit comments