Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/plusauth/plusauth-php-starter
PHP starter project demonstrating OIDC authentication using Jumbojett\OpenIDConnectClient.
https://github.com/plusauth/plusauth-php-starter
example oidc openidconnect php php7 plusauth
Last synced: about 17 hours ago
JSON representation
PHP starter project demonstrating OIDC authentication using Jumbojett\OpenIDConnectClient.
- Host: GitHub
- URL: https://github.com/plusauth/plusauth-php-starter
- Owner: PlusAuth
- Created: 2020-06-18T23:57:08.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-01-18T21:50:23.000Z (about 3 years ago)
- Last Synced: 2024-12-03T07:15:57.426Z (about 2 months ago)
- Topics: example, oidc, openidconnect, php, php7, plusauth
- Language: PHP
- Homepage:
- Size: 27.3 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
PlusAuth PHP Starter Project
Simple PHP project demonstrates basic authentication flows with PlusAuth
Explore the PlusAuth PHP docs »Table of Contents
---
## About The Project
It is a simple `PHP` project demonstrating basic authentication flows such as register, login, and logout. `Jumbojett\OpenIDConnectClient` is used for authentication to keep things simple.
## Prerequisites
Before running the project, you must first follow these steps:
1. Create a PlusAuth account and a tenant at https://dashboard.plusauth.com
2. Navigate to the `Clients` tab and create a client of type `Regular Web Application`
3. Go to the details page of the client that you've just created and set the following fields as:
- Redirect Uris: http://localhost:3000/login.php
- Post-Logout Redirect Uris: http://localhost:3000/
Finally, write down your Client Id and Client Secret for server configuration
## Getting Started
First, we need to configure the server. Rename `.env.example` to `.env`.
Then configure the `.env` file using your Client Id, Client Secret, and your PlusAuth tenant name.
**_Note:_** `composer` must be installed on your system to install project dependencies.
You can run the project with the following options:
### With PHP command
**_Note:_** You must have `curl` and `XML` extensions for PHP installed and enabled.
Install following packages if not installed on your system
sudo apt-get install composer zip php-curl php-xml
Install dependencies:
composer install
Start the server:
php -S localhost:3000 -t public
### With Docker-Compose
Install dependencies:
composer install
Finally, start the server:
docker-compose up
The example is hosted at http://localhost:3000/
## License
The project is licensed under the MIT license. See the [LICENSE](LICENSE) file for more info.
## What is PlusAuth
PlusAuth helps individuals, teams, and organizations to implement authorization and authentication systems in a secure, flexible and easy way.