WP-API / Basic-Auth

Basic Authentication handler for the JSON API, used for development and debugging purposes
761 stars 281 forks source link

Login Warning #68

Open abcajax opened 4 years ago

abcajax commented 4 years ago

I have implemented this plugin. It works great for non logged in user but for logged in user used via Postman, it shows the following. Could you please help solve this. I have latest wordpress install till date.

Login Warning There was an issue with your log in. Your user account has logged in recently from a different location.

cuxaro commented 4 years ago

I have implemented this plugin. It works great for non logged in user but for logged in user used via Postman, it shows the following. Could you please help solve this. I have latest wordpress install till date.

Login Warning

There was an issue with your log in. Your user account has logged in recently from a different location.

Hello, have you this code in your .htaccess?

RewriteEngine on RewriteCond %{HTTP:Authorization} ^(.) RewriteRule ^(.) - [E=HTTP_AUTHORIZATION:%1]

abcajax commented 4 years ago

Earlier, I added RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}] but I commented and tried your suggested ones but still the same problem.

abcajax commented 4 years ago

It only happens to the normal users trying to access via REST. It works fine for the admin user. So some kind of issue with the normal user.

cuxaro commented 4 years ago

Are you sure that haven't any other plugin that limit the number of simultaneous users?

abcajax commented 4 years ago

no, I tried disabling all the possible plugins which can cause issue and tried. Just left the standard plugins but still the problem. I had wordfence installed but I disabled it.

Keeyan commented 4 years ago

@abcajax @cuxaro any luck? Having the same issue and tried the Rewrite Rules.