* POST /account/create (email,srpV,srpSalt) -> ok (server sends verification email)
* POST /session/auth/start (email) -> loginSrpTokensrpToken,SRP stuff* POST /session/auth/finish (loginSrpTokensrpToken,SRP stuff,deviceInfo) -> authToken* POST /session/create [authed with authToken]() -> keyFetchToken, sessionToken* GET /accountrecovery_email/recovery_methods status [authedsessionToken] () -> list of recovery methods with "verified " status** (optional, only if user requests resend) POST /account/recovery_methodsrecovery_email/send_code resend_code [authedsessionToken] (recovery_method) -> ok** POST /account/recovery_methodsrecovery_email/verify_code (code) -> ok* GET /account/keys [authed with keyFetchToken] () -> kA/wrap(kB)* POST /certificate/sign [authedsessionToken] (pubkey) -> cert
Attach to new device
* POST /session/auth/start (email) -> loginSrpTokensrpToken,SRP stuff* POST /session/auth/finish (loginSrpTokensrpToken,SRP stuff,deviceInfo) -> authToken* POST /session/create [authToken] () -> keyFetchToken, sessionToken* GET /account/keys [authed with keyFetchToken] () -> kA/wrap(kB)
** (if unverified-error, do waitUntilEmailVerified, then try again)
* POST /certificate/sign [authedsessionToken] (pubkey) -> cert
Forgot password
* POST /password/forgot/send_code (recovery methodemail) -> forgotPasswordToken
* POST /password/forgot/verify_code (forgotPasswordToken, code) -> accountResetToken
* POST /account/reset [authed+encrypted by accountResetToken] (wrap(kB)0000,srpV,srpSalt) -> ok
* GOTO "Attach to new device"
Change Password
* POST /auth/start in logged(email) -in state> srpToken,SRP stuff* POST /password/change/auth/start [authed] finish (srpToken,SRP stuff,deviceInfo) -> changePasswordSrpToken, SRP stuffauthToken* POST /password/change/auth/finish start [authedauthToken] (changePasswordSrpToken, SRP stuff) -> accountResetToken, keyFetchToken, accountResetToken* GET /account/keys [authed with keyFetchToken] () -> kA/wrap(kB)
* POST /account/reset [authed+encrypted by accountResetToken] (wrap(kB),srpV,srpSalt) -> ok
* GOTO "Attach to new device"