Repository navigation
User Management and Security
thenotoriousJeremy edited this page Aug 20, 2026
·
2 revisions
Bindarr is built from the ground up as a multi-user, self-hosted platform. It ensures strict data isolation between users while providing administrators with full control over instance access, backups, and scan models.
Bindarr uses a database-backed opaque session token authentication model rather than stateless JWTs:
- Password Storage: Passwords are cryptographically hashed using PBKDF2 with individual salts and iterations embedded in the hash string.
-
Session Tokens: Upon login, a cryptographically secure random token is generated and stored in the
sessionstable with an expiration timestamp. -
Header Transmission: Clients transmit the token via the HTTP
Authorization: Bearer <token>header. - Instant Revocation: Logging out deletes the session row from the database, instantly invalidating the session token across all devices.
On a fresh install with an empty database:
-
Web Bootstrap: Navigating to the web interface presents the Setup screen. Submitting a password initializes the default
adminaccount. Passwords are never written to container logs. -
Environment Variable Bootstrap: If you set
DEFAULT_ADMIN_PASSWORD=your_passwordin your.envordocker-compose.yml, Bindarr initializes theadminaccount on first boot automatically. (Note: This variable is only evaluated when theuserstable is completely empty. It will not alter the password of an existing user).
Bindarr supports two distinct user roles:
| Capability | Standard User (user) |
Administrator (admin) |
|---|---|---|
| Manage personal card collection & inventory | Yes | Yes |
| Create binders, boxes & custom sorting rules | Yes | Yes |
| Build & check out deck lists | Yes | Yes |
| Generate read-only personal API keys | Yes | Yes |
| Share collection via public read-only link | Yes | Yes |
| Access Admin Dashboard | No | Yes |
| Create, edit, or delete other user accounts | No | Yes |
| Trigger automated scan catalog builds | No | Yes |
| Create and download database backup snapshots | No | Yes |
| Modify global instance settings & registration toggles | No | Yes |
In the Admin Panel, or via the ALLOW_REGISTRATION environment variable:
- Invite-Only (Default - Recommended): Self-registration is disabled. Only administrators can create new user accounts in Admin → Users.
-
Open Registration (
ALLOW_REGISTRATION=true): A "Register" tab is displayed on the login screen, allowing anyone with access to the URL to create an account.
Each user can optionally generate a public share link to showcase their collection to friends or trading communities without exposing account credentials:
- Go to Settings → Public Sharing.
- Toggle Enable Public Share Link.
- Copy your unique share URL (e.g.
https://cards.example.com/share/abc123token). - Visitors can search, filter, and view high-resolution card artwork and pricing without being able to edit your inventory.
- You can disable or regenerate the share token at any time to immediately revoke access.
- Helmet & Content Security Policy (CSP): Protects against cross-site scripting (XSS), clickjacking, and content sniffing. Card image domains (Scryfall, Pokémon TCG API, TCGCSV) are explicitly allow-listed.
-
Built-in Rate Limiting: Protects authentication endpoints (
/api/auth/*), search queries, and import operations against brute-force attacks. -
Reverse Proxy Protection (
TRUST_PROXY): SetTRUST_PROXY=1when behind a reverse proxy so that rate limiters track the client's actual remote IP rather than the internal proxy IP. -
Read-Only API Credentials: External API keys generated under Settings → API Keys are strictly restricted to HTTP
GEToperations. Non-GET operations and admin endpoints return403 Forbidden.
Bindarr is licensed under the MIT License.
Need help? Check Troubleshooting & FAQ or open an issue on GitHub.