Support the ongoing development of Laravel.io →
Authentication Security
Last updated 3 weeks ago.
0

The curl parameter "--user" just passes basic auth info in the HTTP request. You can easily use the BasicAuth middleware => http://laravel.com/docs/5.0/authentication#http-basic-authenti...

However I don't think this is the best approach. If you have several servers/services doing requests on your Laravel instance, you should at least use a seperate user for each one. Otherwise if one of your passwords get compromised you have to change credentials on all servers.

A better solution in my opinion would be to use an access (or authentication) token based mechansim or even better certificates (if there are critical data involved). But that really depends on what kind of data you process.

0

Thanks Marcod

http://laravel.com/docs/5.0/authentication

i had added below line in htaccess as mention in above url

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

i remove this line and working properly usig auth.basic as middleware

0

Sign in to participate in this thread!

Cloudways

Your banner here too?

mukeshp004 mukeshp004 mukeshp004 Joined 23 Jun 2014

Moderators

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

Your logo here?

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

© 2022 Laravel.io - All rights reserved.