Skip to content
This repository was archived by the owner on Sep 24, 2018. It is now read-only.
This repository was archived by the owner on Sep 24, 2018. It is now read-only.

All authentication methods use "Authorization" header, which is unreliable #2512

@mnelson4

Description

@mnelson4

From what I can tell, all the authentication methods, except cookie authentication, recommended on http://v2.wp-api.org/guide/authentication/ use the "Authorization" header.
The "Authentcation" header isn't reliably received on all server configurations (see WP-API/Basic-Auth#1, WP-API/Basic-Auth#35, and https://wordpress.org/plugins/jwt-authentication-for-wp-rest-api/, see the section on "PHP HTTP Authorization Header enable"). The typical workaround seems to require changing your .htaccess file (although that of course only applies to Apache setups; I'm not sure what nginx setups need to do)

On basic auth plugin, there was this suggestion on an even-less-secure way to pass the username and password: WP-API/Basic-Auth#13. Yuck. But the querystring and request body are more reliable. Or maybe we should just use a different http header for storing authentication data?Thoughts on this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions