Commit 2b3ce34
fix(sveltekit): Fix file system race condition in source map cleaning (#19714)
Replace `existsSync` guard with try/catch around read+write operations
to eliminate the time-of-check to time-of-use race condition (CWE-367)
flagged by CodeQL (code-scanning alert #439).
closes
https://github.com/getsentry/sentry-javascript/security/code-scanning/439
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>1 parent 98be6b0 commit 2b3ce34
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
213 | 213 | | |
214 | 214 | | |
215 | 215 | | |
216 | | - | |
| 216 | + | |
217 | 217 | | |
218 | 218 | | |
219 | 219 | | |
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
223 | 223 | | |
| 224 | + | |
| 225 | + | |
224 | 226 | | |
225 | 227 | | |
226 | 228 | | |
| |||
0 commit comments