daypress
admin route/d-admin/users · /d-admin/profile
doc versionv1.0.4
reading time6 min read
section group30 · Hosting, Security & Ops
Docs/Hosting, Security & Ops
/d-admin/users · /d-admin/profile6 min readv1.0.4

Users, 5 RBAC Roles, Argon2id, TOTP 2FA & Session Control

Daypress hardens every user account by default with OWASP-grade Argon2id password hashing, IP login rate-limiting, WordPress-parity five-role access control, RFC 6238 TOTP Two-Factor Authentication, and instant global session revocation.

Five-role RBAC capability matrix

Create and assign user roles in Users → All Users (/d-admin/users and /d-admin/user-new). Every HTTP handler, REST route, and MCP tool enforces role capabilities server-side:

RolePermitted Capabilities
AdministratorFull system control: site settings, themes/templates, Wasm crates, users, backups, self-updater, imports, and edge publishing.
EditorCreate, edit, publish, schedule, and delete any user's posts, pages, CPT entries, media assets, taxonomies, and comments.
AuthorCreate, edit, publish, and upload media for their own posts only; cannot modify pages or other authors' entries.
ContributorWrite and edit their own unpublished drafts and submit for editorial review; cannot publish live or upload raw files.
SubscriberManage their own profile and read members_only / subscribers_only gated content on the public site.

RFC 6238 TOTP 2FA & backup recovery codes

Enable Two-Factor Authentication for any account under Users → Profile (/d-admin/profile):

  1. Scroll to Two-Factor Authentication (TOTP) and click Set Up Authenticator App (POST /wp-json/daypress/v1/users/{id}/2fa/setup).
  2. Scan the provisioning QR code in 1Password, Proton Pass, Google Authenticator, or Raivo, then enter the 6-digit RFC 6238 code to activate.
  3. Store the 8 single-use XXXX-XXXX backup recovery codes offline (hashed in SQLite; regenerable anytime). Interactive logins at /login will now prompt at /login/2fa before issuing a session cookie.
/d-admin/profile · TOTP 2FA, Application Passwords & Session Control
Daypress User Profile screen showing color scheme picker, TOTP Two-Factor Authentication setup, Application Passwords manager, and Log Out Everywhere Else button
Users -> Profile (/d-admin/profile): enroll TOTP 2FA, mint scoped Application Passwords for REST/MCP clients, and revoke all other active sessions in 1 click.

Application Passwords & global session revocation

Every user record maintains a monotonic session_ver counter in SQLite. Clicking Log Out Everywhere Else on /d-admin/profile (POST /wp-json/daypress/v1/users/{id}/sessions/destroy-others) increments session_ver—immediately invalidating every previously issued browser cookie and JWT token on other devices without touching scoped Application Passwords.

GDPR personal data export & erasure

Handle GDPR / CCPA data-subject requests natively under Tools → Export Personal Data (/d-admin/export-personal-data) and Erase Personal Data (/d-admin/erase-personal-data). Enter an email address to compile a portable JSON archive of profile metadata, comments, FormStudio entries, and newsletter subscriptions—or anonymize/purge them in 1 click.