irto / oauth2-proxy
There is no license information available for the latest version (dev-master) of this package.
A PHP Proxy for OAuth2 APIs to create safe Web Apps.
dev-master
2016-02-05 18:46 UTC
Requires
- clue/redis-react: ~0.5.0
- guzzle/parser: >=3.9
- illuminate/container: 5.1.*
- illuminate/filesystem: 5.1.*
- illuminate/pipeline: 5.1.*
- illuminate/session: 5.1.*
- illuminate/support: 5.1.*
- react/http: 0.*
- react/http-client: 0.*
- symfony/http-foundation: 2.*
Requires (Dev)
- phpunit/phpunit: 4.5.*
This package is not auto-updated.
Last update: 2025-03-29 19:51:54 UTC
README
oauth2-proxy
A PHP Proxy for OAuth2 APIs to create safe Web Apps.
This project will help create Web App over OAuth2 API, working how a proxy (or translator) using CSRF and Session for front-end and translating in OAuth2 to back-end API. Project is working over awesome ReactPHP libs and Illuminate (from Laravel) components.
Example example\server.php
:
<?php require '../vendor/autoload.php'; $proxy = Irto\OAuth2Proxy\Server::create(array( 'api_url' => 'http://api.web.domain', 'port' => 8080, 'client_id' => 'e22aa202216e86c42beac80f9a6ac2da505dc', 'client_secret' => '471d2e22aa202216e86c42beac80f9a6ac2da5', 'grant_path' => '/auth/token', 'revoke_path' => '/auth/revoke', 'grant_type' => 'client_grant', 'session' => [ 'driver' => 'file', 'folder' => '../storage/sessions/', 'name' => 'tests', 'path' => '/', 'domain' => 'web.domain', 'lifetime' => 3600, ] )); $proxy->run(); ?>
It's easy to run
$ php ./server.php
...or in background with nohup
$ nohup php ./server.php &
TODO
- Unit Tests
- OAuth2 authorization flow
- Friendly configuration
- Documentation (my english is to bad .-.)