silverstripe-admin icon indicating copy to clipboard operation
silverstripe-admin copied to clipboard

Indeterminate behaviour when editing a member that is a "default admin"

Open NightJar opened this issue 5 years ago • 0 comments

Like Schrödinger's cat, default admin is both a user, and not a user - in that the account exists always, but only while being observed. Editing this magically inserted default record causes strange behaviour.

Recreate:

  1. Install SilverStripe using SS_DEFAULT_ADMIN_... combo of admin:password
  2. Log in to /admin/security using admin:password
  3. Open only user (admin)
  4. Change "Default Admin" email address
    - admin
    + admin@localhost
    
  5. save ("Apply changes").
  6. wait for session to time out, perhaps whilst you eat lunch.
  7. Click save again.
  8. When presented with the "please re-authenticate that you are you" modal, enter the password (password)
  9. Be told by the modal reload that your user does not exist, you are a fraud, and watch your whole DEFAULT_ADMIN life crumble before your eyes as if it were all an elaborate fabrication.
  10. visit /admin/security and try to log in as admin@localhost:password - and be denied also.
  11. visit /admin/security and log in as normal; using admin:password still.
  12. Now there are two "Default Admin" users - admin and admin@localhost

image

NightJar avatar Apr 23 '19 02:04 NightJar