Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/immense/php-macaroons
PHP implementation of Macaroons
https://github.com/immense/php-macaroons
Last synced: about 2 months ago
JSON representation
PHP implementation of Macaroons
- Host: GitHub
- URL: https://github.com/immense/php-macaroons
- Owner: immense
- License: mit
- Created: 2015-04-22T16:00:26.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2020-01-18T02:42:11.000Z (over 4 years ago)
- Last Synced: 2024-07-21T08:49:26.536Z (2 months ago)
- Language: PHP
- Homepage:
- Size: 86.9 KB
- Stars: 28
- Watchers: 10
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: MIT-LICENSE
Awesome Lists containing this project
README
## Macaroons
[![Build Status](https://img.shields.io/travis/immense/php-macaroons.svg)](https://travis-ci.org/immense/php-macaroons)
[![Latest Stable Version](https://img.shields.io/packagist/v/immense/macaroons.svg)](https://packagist.org/packages/immense/macaroons)
[![License](https://img.shields.io/packagist/l/immense/macaroons.svg)](https://packagist.org/packages/immense/macaroons)
[![Coverage Status](https://img.shields.io/coveralls/immense/php-macaroons.svg)](https://coveralls.io/r/immense/php-macaroons?branch=master)This PHP library provides an implementation of [macaroons](http://hackingdistributed.com/2014/05/16/macaroons-are-better-than-cookies) which allow decentralized delegation, attenuation, and verification.
## Requirements
* [PHP >= 5.4.0](http://php.net)
* [libsodium 1.x](https://github.com/jedisct1/libsodium)
* [libsodium-php 1.x](https://github.com/jedisct1/libsodium-php)__Note: libsodium-php 2.x may be used with the [compatibility layer](https://github.com/jedisct1/libsodium-php#libsodium-php-1x-compatibility-api-for-libsodium-php-2x) until this package is updated.__
__libsodium is available with PHP 7.2__
## Installing `libsodium-php`
* OS X using [homebrew](https://github.com/Homebrew/homebrew)
```bash
brew tap homebrew/php
brew install php55-libsodium
```* Using `pecl`
```bash
pecl install libsodium
```## Installation via [composer](https://getcomposer.org)
In your project directory:
* Create a `composer.json` in your project if necessary
```bash
composer init
```* Install the latest version as a project dependency
```bash
composer require immense/macaroons
```## Tests
N.B. phpunit 5 requires PHP >= 5.6
Files must end with `Test` e.g. `ClassTest.php`
* From the `php-macaroons` root directory:
```bash
phpunit
```* Run tests on file change (optional)
```bash
gem install watchr
watchr ./autotest-watchr.rb
```## License
[php-macaroons](https://github.com/immense/php-macaroons) is licensed under the MIT license. Please see the [license](MIT-LICENSE) for more information.