-
Notifications
You must be signed in to change notification settings - Fork 47
[Security] ZIP bomb vulnerability in plugin extraction no size limits #347
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't workingsecuritySecurity-related issueSecurity-related issuesquadSquad triage inbox — Lead will assign to a memberSquad triage inbox — Lead will assign to a membersquad:riverAssigned to River (Backend Dev)Assigned to River (Backend Dev)
Description
Summary
Plugin ZIP extraction in PluginManager.cs has no size limits, compression ratio checks, or path traversal protection. This enables ZIP bomb attacks.
Affected File
src/SharpSite.Web/PluginManager.cs (lines 244-294)
Risks
- ZIP bomb: A 42KB zip can decompress to petabytes
- Disk exhaustion: No total or per-file size caps
- Path traversal: Only empty-name entries are filtered;
../sequences not explicitly blocked
Recommended Fix
Add max total extracted size (100MB), max single file size (50MB), compression ratio check (100:1), and path normalization with directory containment validation.
Estimated Effort
2-3 hours
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingsecuritySecurity-related issueSecurity-related issuesquadSquad triage inbox — Lead will assign to a memberSquad triage inbox — Lead will assign to a membersquad:riverAssigned to River (Backend Dev)Assigned to River (Backend Dev)