Download the PHP package khoelck/phpazureauth without Composer
On this page you can find all versions of the php package khoelck/phpazureauth. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download khoelck/phpazureauth
More information about khoelck/phpazureauth
Files in khoelck/phpazureauth
Package phpazureauth
Short Description A library to generate Azure tokens for consuming services, using ROPC authentication method via PHP.
License MIT
Informations about the package phpazureauth
PhpAzureAuth
PhpAzureAuth is a very simple PHP library to generate Azure tokens for consuming services, specifically using ROPC authentication method via PHP. More on that from Microsoft here.
It is a dependency package of the PhpPowerBI package.
Installation
The recommended way to install is via composer
Composer install
Manual install
Copy the contents of the src folder to your include_path, and include the libraries in your authentication script as below:
Initial Configuration
Before using this in your code, navigate to the install folder (vendor/khoelck/phpazureauth/src for composer installs) and copy the AzureConfig.php file to your include_path.
The following values will need to be configured for your app:
- Azure Client ID
- Azure Client Secret
- Azure OAuth 2.0 token auth URL
- Azure Tenant ID
Because this project relies on the config file, be sure to also include it on any page AzureAuth is used in addition to your composer autoload.
Use
This package is primarily designed to be used inside of your app's authentication script. Used within this script, the username and password will be able to be passed through to the AzureAuth constructor, then used to obtain the token. Please see Example.php for more information.
Related packages
While this can certainly be used on it's own in your project, it's designed to use with the downstream project PhpPowerBI.