Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor authentication to prevent conflicts with plugins that determine the current user too early. #97

Merged
merged 3 commits into from
Mar 27, 2019

Commits on Mar 26, 2019

  1. Prevent conflicts with plugins that determine the current user too ea…

    …rly. See #94
    
    This seeks to work around conflicts with plugins that determine the current user
    during plugins_loaded by wiring up the determine_current_user filter immediately,
    so that authentication can be handled whenever wp_get_current_user() is called.
    
    Authentication servers have been refactored to simplify the interface and move
    state management and type gymnastics into the Authentication provider.
    bradyvercher committed Mar 26, 2019
    Configuration menu
    Copy the full SHA
    74fc50b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2128f06 View commit details
    Browse the repository at this point in the history
  3. Remove the handle_error() method from authentication servers.

    This creates a new AuthenticationException exception to transport authentication
    errors, including headers and status code, from the authenticate() method
    instead of using a handle_error() method.
    
    If the current request is a REST request, the Authentication provider will
    convert the exception to an error instead of allowing the exception to bubble
    up.
    bradyvercher committed Mar 26, 2019
    Configuration menu
    Copy the full SHA
    9168411 View commit details
    Browse the repository at this point in the history