Owners and managers can change money, people and settings, so they sign in with two things: the password and a six digit code from an authenticator app. Set the app up once and use it at every sign-in. An existing owner or manager who has not set it up is asked to do so at the next sign-in; the password-change and set-up routes stay open for recovery.
Before you start #
- Use any authenticator app on a phone, such as the ones from your phone's app store. They are free.
- Other roles sign in with a password only.
Set it up #
- Sign in with your email and password. The server answers that the authenticator needs set-up (
totp_enrolment_required). - The sign-in screen starts set-up and shows a set-up key and a QR code. Scan the code with the authenticator app, or type the key.
- Save the key in a password manager, so you can add it to a new phone later.
- Type the six digit code the app shows and choose "Turn on and sign in". The server confirms the code. When the app shows the next code, type it to finish signing in.
Sign in afterwards #
- Enter your email and password.
- Enter the six digit code. A code works once, so wait for the next one if you have just used it.
- You are in. The code is accepted one 30 second step either side of the right time, so keep the phone clock on automatic time.
If you lose the phone #
The person who runs the server clears your authenticator with one command: dispatch-server reset-totp --tenant <business> --user <email>. You then sign in with your password and set up again on the new phone. The same command works for the owner.
Technical details
- Codes follow RFC 6238: SHA-1, 6 digits, 30 seconds, one step either side. A step is accepted once.
- The secret is stored sealed (AES-256-GCM, tied to the business and the person), so a copy of the database file keeps it hidden.
- Errors:
totp_required(401) asks for thetotpfield.totp_enrolment_required(401) asks for set-up.
If something goes wrong #
- "The code is wrong": check the phone clock, then try the next code.
- Locked after several failures (8 in a row): wait for the lockout to end, then try again.