Title: Authorization Header missing
Last modified: May 9, 2018

---

# Authorization Header missing

 *  [mdeck](https://wordpress.org/support/users/mdeck/)
 * (@mdeck)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/authorization-header-missing/)
 * Hello Developers,
 * I started using this plugin for a site and was having trouble with getting the
   user from the authorization token. When looking through the validate_token method
   in `jwt-authentication-for-wp-rest-api/public/class-jwt-auth-public.php`, I noticed
   that the function only checks the global variables,, which does not seem to have
   all of the information pulled in from the request. However, if you add the following
   lines at line 237, it is able to get all of the headers from the request.
 *     ```
       if(!$auth) {
                   $auth = isset(getallheaders()['Authorization']) ? getallheaders()['Authorization'] : false;
               }
       ```
   
    -  This topic was modified 8 years, 1 month ago by [mdeck](https://wordpress.org/support/users/mdeck/).

The topic ‘Authorization Header missing’ is closed to new replies.

 * ![](https://ps.w.org/jwt-authentication-for-wp-rest-api/assets/icon-256x256.jpg?
   rev=3372068)
 * [JWT Authentication for WP REST API](https://wordpress.org/plugins/jwt-authentication-for-wp-rest-api/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/jwt-authentication-for-wp-rest-api/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/jwt-authentication-for-wp-rest-api/)
 * [Active Topics](https://wordpress.org/support/plugin/jwt-authentication-for-wp-rest-api/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/jwt-authentication-for-wp-rest-api/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/jwt-authentication-for-wp-rest-api/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [mdeck](https://wordpress.org/support/users/mdeck/)
 * Last activity: [8 years, 1 month ago](https://wordpress.org/support/topic/authorization-header-missing/)
 * Status: not resolved