mirror of
https://github.com/polius/Cryptex.git
synced 2026-07-25 01:27:35 +02:00
Self-hosted platform for sharing text and files securely.
- JavaScript 30.7%
- CSS 26.3%
- Python 22.7%
- HTML 20%
- Dockerfile 0.2%
- Other 0.1%
Bumps the pip group in /api with 1 update: [fastapi](https://github.com/fastapi/fastapi). Updates `fastapi` from 0.139.0 to 0.139.2 - [Release notes](https://github.com/fastapi/fastapi/releases) - [Commits](https://github.com/fastapi/fastapi/compare/0.139.0...0.139.2) --- updated-dependencies: - dependency-name: fastapi dependency-version: 0.139.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: pip ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|---|---|---|
| .github | ||
| api | ||
| web | ||
| .gitignore | ||
| Dockerfile | ||
| entrypoint.sh | ||
| LICENSE | ||
| nginx.conf | ||
| README.md | ||
Cryptex
Lock down your data. Send it securely.
Cryptex is a self-hosted platform for sharing text and files securely.
Features
- Self-hosted — deploy with a single Docker command. Your data stays on your server.
- Simple secure sharing — share text and files with optional password protection.
- Password protection — protect access with a password, or generate one automatically.
- Self-destruct — optionally destroy a cryptex automatically after it's been opened.
- Expiration — set a time limit (minutes, hours, or days) after which the cryptex is permanently deleted.
- Public / Private mode — run open to anyone, or require an invite link to create a cryptex.
- Invite links — create shareable invite links that allow others to create Cryptexs, even in private mode.
- Admin panel — monitor active Cryptexs, manage invite links, configure limits, and enable two-factor authentication.
- Multipart file uploads — large files are uploaded in chunks for reliability.
- QR code sharing — generate a QR code for easy mobile access.
- API support — fully documented API with API key authentication for programmatic access.
Quick Start
Docker CLI
docker run -d \
--name cryptex \
-p 80:80 \
-v ./data:/cryptex/data \
--restart unless-stopped \
poliuscorp/cryptex
Docker Compose
services:
cryptex:
image: poliuscorp/cryptex
container_name: cryptex
restart: unless-stopped
ports:
- "80:80"
volumes:
- ./data:/cryptex/data
Then open http://localhost.
The
./datavolume persists the database and uploaded files across container restarts. Replace it with any host path you prefer.
Configuration
| Variable | Default | Description |
|---|---|---|
MODE |
public |
public allows anyone to create a cryptex. private restricts creation to authenticated users or valid invite links |
ADMIN_PASSWORD |
— | Bcrypt hash used to override the default admin password (admin) |
MAX_MESSAGE_LENGTH |
1000 |
Max characters per cryptex |
MAX_FILE_COUNT |
3 |
Max file attachments per cryptex |
MAX_FILE_SIZE |
100mb (100 MB) |
Max size per file (500kb, 10mb, 1gb) |
MAX_EXPIRATION |
1d (1 day) |
Max expiration time (30m, 24h, 30d) |
RATE_LIMIT |
30 |
Max requests per minute per IP for create/open endpoints |
Admin Panel
Manage Cryptexs, invite links, settings, and 2FA at http://localhost/login.
Default password: admin — change it in production.
Generate a custom password hash:
pip install bcrypt
python3 -c "import bcrypt, getpass; p = getpass.getpass('Enter password: '); print(bcrypt.hashpw(p.encode(), bcrypt.gensalt()).decode())"
Then set ADMIN_PASSWORD in your environment:
environment:
- ADMIN_PASSWORD=$2b$12$LJ3m4ys3uz0Cb6PEhV7hXOBFg7b6I1MeZaYvLYEPYj5KzKIO/3Cxm
Note: If you're using the Docker CLI (-e flag), wrap the hash in single quotes:
-e ADMIN_PASSWORD='$2b$12$LJ3m4ys3uz0Cb6PEhV7hXOBFg7b6I1MeZaYvLYEPYj5KzKIO/3Cxm'
Upgrading
Docker CLI
docker pull poliuscorp/cryptex
docker stop cryptex && docker rm cryptex
docker run -d \
--name cryptex \
-p 80:80 \
-v ./data:/cryptex/data \
--restart unless-stopped \
poliuscorp/cryptex
Docker Compose
docker compose pull
docker compose up -d
The ./data volume preserves your database and files across upgrades.
License
This project is licensed under the MIT License.
