-
v0.1.0 Pre-release
released this
2026-03-14 02:44:32 +01:00 | 36 commits to main since this releaseAdded
- File upload API (
POST /api/upload) with streaming writes, per-file size limits
(DD_MAX_FILE_SIZE_MB, 1-500 MB) and global storage quota enforcement
(DD_MAX_STORAGE_MB, default 1 GB) checked mid-stream during upload. - Short-link downloads (
GET /<short_id>) with streaming 64 KB chunked responses,
RFC 5987Content-Dispositionencoding for Unicode filenames, and ASCII fallback. - Link management: list links (
GET /api/links), expire individual links
(POST /api/links/{id}/expire), and view storage statistics (GET /api/stats)
including bytes used, capacity, and remaining space. - Background cleanup task that automatically purges expired links and files on a
configurable interval (DD_CLEANUP_INTERVAL_SECONDS). - CLI client (
ddrop) withupload,fetch,list,stats,expire, andserve
commands, Rich-formatted table output, and human-readable storage usage display. - CLI
fetchcommand with--outputflag for downloading files by link ID, with
automatic filename extraction fromContent-Dispositionheaders and fallback naming. stashalias for theuploadcommand.- Configurable upload TTL with
--ttlflag (e.g.30m,2h) and server-side
maximum (DD_MAX_TTL, default48h, supportsinf). - SQLite-backed metadata storage with schema validation on startup that fails fast
on incompatible legacy schemas. - Docker secrets support via
DD_API_TOKEN_FILEfor secure token injection from
secret managers, Swarm, or Kubernetes; mutually exclusive withDD_API_TOKEN. - Multi-platform container image builds via
docker buildx bake(linux/amd64+
linux/arm64) with local, default, and release targets indocker-bake.hcl. - Multi-stage Dockerfile based on
python:3.12.11-alpine3.21for minimal image size. - Production-hardened Docker Compose setup: localhost-only binding, read-only root
filesystem, all capabilities dropped,no-new-privileges,initfor PID 1
signal handling, health check, named volume for persistence, and graceful 20s
shutdown period. - Comprehensive test suite (54 tests) covering API, storage, CLI, configuration,
end-to-end flows, and security regression scenarios.
Security
- Secure-by-default authentication: server refuses to start without
DD_API_TOKEN
orDD_API_TOKEN_FILEunlessDD_ALLOW_ANON=trueis explicitly set. - Constant-time token comparison using
secrets.compare_digest()to prevent timing
side-channel leakage. - Filesystem path confinement: file paths are derived from validated link IDs at
runtime, never stored in or read from the database. - Symlink protection on downloads: rejects symlinked files with a security log entry
and opens files withO_NOFOLLOW(where available) to prevent TOCTOU races. - Symlink-safe deletion: expire and purge operations remove the symlink itself rather
than following it to an external target. - Collision-safe link ID generation: uses
INSERT(notINSERT OR REPLACE) with
automatic retry (up to 5 attempts) on ID collision, preventing silent overwrites. - Upload size and quota enforcement applied mid-stream with immediate abort and
cleanup on breach (HTTP 413 / 507). - Non-root container runtime (UID/GID 10001) with dedicated
deaddropuser. - Reverse-proxy rate limiting guidance with example nginx configuration in README.
Downloads
-
Source code (ZIP)
0 downloads
-
Source code (TAR.GZ)
0 downloads
- File upload API (