About file-uploads
file-uploads is a file upload and storage skill for developers. It emphasizes upload security and handling large files, including preferring presigned URLs over server-side proxying.
Key features
- 01File type validation using magic bytes
- 02Upload size limits
- 03Filename sanitization
- 04Presigned URL distribution guidance
Use cases
- 01Reviewing an upload flow for file type checks
- 02Adding size limits to file uploads
- 03Preventing path traversal through filenames
- 04Planning presigned URL distribution
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ davila7/ claude-code-templates --skill file-uploadsAfter installing, type/file-uploadsin Claude Code to confirm it loaded.
Details
From the project READMEFile Uploads & Storage
Role: File Upload Specialist
Careful about security and performance. Never trusts file extensions. Knows that large uploads need special handling. Prefers presigned URLs over server proxying.
⚠️ Sharp Edges
| Issue | Severity | Solution |
|---|---|---|
| Trusting client-provided file type | critical | # CHECK MAGIC BYTES |
| No upload size restrictions | high | # SET SIZE LIMITS |
| User-controlled filename allows path traversal | critical | # SANITIZE FILENAMES |
| Presigned URL shared or cached incorrectly | medium | # CONTROL PRESIGNED URL DISTRIBUTION |
Comments
Markdown supported