Support e-mail address logins in the API

Review Request #8578 — Created Dec. 16, 2016 and submitted

Information

Review Board
release-2.5.x
fa3ea10...

Reviewers

The API now supports logging in with an e-mail address just like the
normal login view. A new WebAPI auth backend has been added that
translates supplied e-mail addresses to usernames so that they can be
used in the standard auth backend.

Authenticated with an e-mail address via the API.

Description From Last Updated

'django_reset' imported but unused

reviewbotreviewbot

'from settings_local import *' used; unable to detect undefined names

reviewbotreviewbot

'PIPELINE_JS' imported but unused

reviewbotreviewbot

'PIPELINE_CSS' imported but unused

reviewbotreviewbot

I think the official capitalization is "HTTP Basic authentication". It's not an acronym.

daviddavid

"@" is a valid character in the User.username field. We should try to look up User by username, and if …

daviddavid
reviewbot
  1. Tool: PEP8 Style Checker
    Processed Files:
        reviewboard/webapi/auth_backends.py
        reviewboard/settings.py
    
    
    
    Tool: Pyflakes
    Processed Files:
        reviewboard/webapi/auth_backends.py
        reviewboard/settings.py
    
    
  2. reviewboard/settings.py (Diff revision 1)
     
     
    Show all issues
     'django_reset' imported but unused
    
  3. reviewboard/settings.py (Diff revision 1)
     
     
    Show all issues
     'from settings_local import *' used; unable to detect undefined names
    
  4. reviewboard/settings.py (Diff revision 1)
     
     
    Show all issues
     'PIPELINE_JS' imported but unused
    
  5. reviewboard/settings.py (Diff revision 1)
     
     
    Show all issues
     'PIPELINE_CSS' imported but unused
    
  6. 
      
david
  1. 
      
  2. reviewboard/webapi/auth_backends.py (Diff revision 1)
     
     
    Show all issues

    I think the official capitalization is "HTTP Basic authentication". It's not an acronym.

  3. reviewboard/webapi/auth_backends.py (Diff revision 1)
     
     
    Show all issues

    "@" is a valid character in the User.username field. We should try to look up User by username, and if that doesn't exist, then look up by e-mail address.

  4. 
      
brennie
reviewbot
  1. Tool: PEP8 Style Checker
    Processed Files:
        reviewboard/webapi/auth_backends.py
        reviewboard/settings.py
    
    
  2. 
      
brennie
david
  1. You can add bug 4448.

  2. 
      
brennie
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-2.5.x (bf7bd55)
Loading...