Codex regression-gate findings on the shipped #3104 upload code, each verified with a repro and fixed: 1. Negative Content-Length bypassed the size cap → unbounded rfile.read(-1). The per-handler 'content_length > MAX_UPLOAD_BYTES' check is False for a negative value, so the guard is now centralized in parse_multipart() (validates [0, MAX_UPLOAD_BYTES]) — protects all four upload handlers. 2. .tar/.tbz2/.txz uploads silently skipped extraction (is_archive suffix set was narrower than extract_archive's) → now matches. 3. Rejected archives (zip-slip/zip-bomb/corrupt/too-many-members) showed a misleading 'Uploaded' success toast → workspace.js now surfaces extract_error. 4. An in-workspace symlink subpath let mkdir/writes escape the workspace root → target_dir is now required to be is_relative_to(workspace) before mkdir. Regression tests added (negative+oversize CL, .tar extraction, symlink target). |
||
|---|---|---|
| .. | ||
| vendor | ||
| apple-touch-icon.png | ||
| boot.js | ||
| commands.js | ||
| favicon-32.png | ||
| favicon-192.png | ||
| favicon-512.png | ||
| favicon-512.svg | ||
| favicon.ico | ||
| favicon.svg | ||
| i18n.js | ||
| icons.js | ||
| index.html | ||
| login.js | ||
| manifest.json | ||
| messages.js | ||
| onboarding.js | ||
| panels.js | ||
| pwa-startup.js | ||
| sessions.js | ||
| style.css | ||
| sw.js | ||
| terminal.js | ||
| ui.js | ||
| workspace.js | ||