Opened 13 years ago

Closed 13 years ago

#132 closed defect (fixed)

Switch the scripts auth code to using UNUSABLE_PASSWORD

Reported by: adehnert Owned by:
Priority: minor Milestone: Sometime
Component: Infrastructure Version:
Keywords: Cc:
Size: medium

Description (last modified by adehnert)

We have some issues that are ultimately caused by the scripts cert auth code using "ScriptsSSLAuth" as the password for users who auth using certs. Really, this should probably(?) be UNUSABLE_PASSWORD (from contrib/auth/hashers.py, in Django 1.4). We should change the auth code to set that as the password, and migrate current ScriptsSSLAuth passwords (and maybe empty string, see ASA-#133) to be UNUSABLE_PASSWORD instead.

See https://diswww.mit.edu/menelaus/asa-db/2131.

Change History (3)

comment:1 Changed 13 years ago by adehnert

  • Description modified (diff)
  • Summary changed from Consider adding ScriptsSSLAuth to PASSWORD_HASHERS to Switch the scripts auth code to using UNUSABLE_PASSWORD

I did some considering, so update the description and title to reflect the current state.

Last edited 13 years ago by adehnert (previous) (diff)

comment:2 Changed 13 years ago by adehnert

See Remit-#38 (http://remit.scripts.mit.edu/trac/ticket/38) for some history. It looks like the fix for that was always wrong. Oops.

comment:3 Changed 13 years ago by adehnert

  • Resolution set to fixed
  • Status changed from new to closed

Fixed:

Author: Alex Dehnert <adehnert@mit.edu>
Date:   Mon Dec 24 03:28:00 2012 -0500

    Set a password of UNUSABLE_PASSWORD
    
    * Changes ScriptsRemoteUserBackend's configure_user method to set the default
      password to UNUSABLE_PASSWORD instead of ScriptsSSLAuth. UNUSABLE_PASSWORD
      displays in the admin as "Password: None", instead of an ugly error message.
      This should fix "Unknown password hashing algorithm" errors for users
      correctly created in the future. (ASA-#132)
    
    * Adds a migration to change current users with passwords of "" or
      "ScriptsSSLAuth" to a password of UNUSABLE_PASSWORD ("!"). This will fix
      ASA-#132 and the symptoms of ASA-#133 for already-existent users.
Note: See TracTickets for help on using tickets.