Looking to hire Laravel developers? Try LaraJobs

laravel-config-based-auth-basic maintained by rabianr

Description
A config file based HTTP Basic Authentication Middleware for Laravel
Author
ラ・ビ・アン・ローズ
Last update
2021/10/28 10:42 (dev-master)
License
Links
Downloads
11

Comments
comments powered by Disqus

Config file based HTTP Basic Authentication Middleware for Laravel

Installation

composer require rabianr/laravel-config-based-auth-basic 

Configuration

Publish the config to copy the file to your own config:

php artisan vendor:publish --tag="authbasic"

Usage

Set auth.basic.cb middleware to any route that require Basic Auth.

Define credentials in config/authbasic.php config file.

'credentials' => [
    [ 'user', 'password' ],
],

or in .env file

AUTHBASIC_USERS=user1:pass1,user2:pass2