Package Data | |
---|---|
Maintainer Username: | amaroRafael |
Maintainer Contact: | contact@rafaelamaro.com (Rafael Luis Neves Amaro) |
Package Create Date: | 2015-06-04 |
Package Last Update: | 2015-06-19 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2025-03-29 15:16:14 |
Package Statistics | |
---|---|
Total Downloads: | 30 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 0 |
Total Watchers: | 1 |
Total Forks: | 1 |
Total Open Issues: | 0 |
OAuth 2.0 authorization server and resource server for the Laravel framework. Standard compliant thanks to the amazing work by The League of Extraordinary Packages OAuth 2.0 authorization server and resource server.
The package assumes you have a good-enough knowledge of the principles behind the OAuth 2.0 Specification.
Lumen | OAuth Server | PHP :---------|:-------------|:---- 5.0.x | 4.1.x |>= 5.5
This package features an extensive wiki to help you getting started implementing an OAuth 2.0 Server in your Laravel app.
Bugs and feature request are tracked on GitHub
This package is released under the MIT License.
#The code on which this package are based:
PHP OAuth 2.0 Server for Lumen
Run composer require 'rapiro/oauth2server-lumen:0.1.*'
In your bootstrap/app.php
register service providers
$app->register('Rapiro\OAuth2Server\Providers\StorageServiceProvider');
$app->register('Rapiro\OAuth2Server\Providers\OAuth2ServerServiceProvider');
... and middleware
$app->middleware([
'Rapiro\OAuth2Server\Middleware\OAuthExceptionHandlerMiddleware'
]);
... and route middleware
$app->routeMiddleware([
'check-authorization-params' => 'Rapiro\OAuth2Server\Middleware\CheckAuthCodeRequestMiddleware',
'csrf' => 'Laravel\Lumen\Http\Middleware\VerifyCsrfToken',
'oauth' => 'Rapiro\OAuth2Server\Middleware\OAuthMiddleware',
'oauth-owner' => 'Rapiro\OAuth2Server\Middleware\OAuthOwnerMiddleware'
]);
Copy vendor/Rapiro/oauth2server-lumen/config/oauth2.php
to your own config folder (config/oauth2.php
in your project root).
Copy vendor/Rapiro/oauth2server-lumen/config/auth.php
to your own config folder (config/oauth2.php
in your project root).
It has to be the correct config folder as it is registered using $app->configure()
.
Copy vendor/Rapiro/oauth2server-lumen/Models/
folder to your own app folder (app/
in your project root).
In bootstrap/app.php
file and uncomment $app->withFacades();
and $app->withEloquent();
Run php artisan migrate --path=vendor/Rapiro/oauth2server-lumen/database/migrations