Support the ongoing development of Laravel.io →
Authentication
Last updated 2 years ago.
0

i've the same problem....any suggest?

Last updated 2 years ago.
0

I have the same problem, I dig down to Symphony2 packages and the header is taking correctly and cut for user: and password (witch they correct) Any idea ??

Last updated 2 years ago.
0

Though not solved yet, think I got closer to defining the problem;

It seems the necessary PHP_AUTH_USER and PHP_AUTH_PW parameters are not included in the $_SERVER data.

Apparently this has to do with how the .htaccess file is set up.

My htaccess file now looks like this:

RewriteEngine On

RewriteCond %{HTTP_HOST} ^{weef}.{dev} [NC]
RewriteRule (.*) http:/api.{api.weef}.{dev}/$1 [R=301,L]

RewriteCond %{REQUEST_URI} !public/
RewriteRule (.*) /public/$1 [L]

RewriteCond %{HTTP:Authorization} ^(.+)$
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

This is not the default setup, as some other issues were successfully solved with this. The last 2 lines are from the Laravel documentation, as a solution to make auth.basic working on servers running FastCGI. I'm no knight in the order of .htaccess, so I have no idea what could be wrong with this code. For basic auth, it doesn't work for me. It is also unclear whether these 2 lines need to be added to the .htaccess in the main folder, or the .htaccess in the /public folder. Tried both, neither works.

AUTH_USER and AUTH_PW are still unavailable in $_SERVER. Probably still causing Laravel's auth.basic route filter to fail.

I'll keep this thread posted if a solution is found

Last updated 2 years ago.
0

This post inspired me to dig deep into my server to see if CGI was to blame.

Not sure if I have your exact problem, but I did find a workaround for my HTTP Basic Auth not working. Perhaps it can help you guys?

http://laravel.io/forum/05-10-2014-http-basic-auth-always-fails-on-ipage

Last updated 2 years ago.
0

The process mentioned in the following link helped me (should help you guys too) - http://codetheory.in/fixing-laravel-basic-auth-failure/

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

wimklerkx wimklerkx Joined 17 Mar 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.