- Add noDirListing handler wrapper that returns 404 for directory requests (paths ending with "/" or empty path) instead of delegating to http.FileServerFS which would render an index page - Wrap the static file server in Register() with noDirListing - Add tests verifying GET /static/ returns 404 and GET /static/style.css still returns 200 Security: directory listings exposed the names of all static assets, leaking framework details. The wrapper blocks directory index responses while preserving normal file serving. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
18 KiB
18 KiB