Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/theimpossibleastronaut/php-sam
Basic SAMv3 implementation for I2P in PHP
https://github.com/theimpossibleastronaut/php-sam
i2p i2pd library php php7 sam
Last synced: 2 months ago
JSON representation
Basic SAMv3 implementation for I2P in PHP
- Host: GitHub
- URL: https://github.com/theimpossibleastronaut/php-sam
- Owner: theimpossibleastronaut
- License: mit
- Created: 2019-07-25T15:52:41.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2021-02-06T11:18:35.000Z (almost 4 years ago)
- Last Synced: 2024-08-04T04:04:54.359Z (6 months ago)
- Topics: i2p, i2pd, library, php, php7, sam
- Language: PHP
- Size: 34.2 KB
- Stars: 4
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-i2p - php-sam - Basic SAMv3 implementation in PHP (Libraries / I2Pd)
README
[![License](https://poser.pugx.org/theimpossibleastronaut/php-sam/license)](https://packagist.org/packages/theimpossibleastronaut/php-sam)
[![SourceLevel](https://app.sourcelevel.io/github/theimpossibleastronaut/-/php-sam.svg)](https://app.sourcelevel.io/github/theimpossibleastronaut/-/php-sam)
[![Latest Stable Version](https://poser.pugx.org/theimpossibleastronaut/php-sam/v/stable)](https://packagist.org/packages/theimpossibleastronaut/php-sam)
[![Latest Unstable Version](https://poser.pugx.org/theimpossibleastronaut/php-sam/v/unstable)](https://packagist.org/packages/theimpossibleastronaut/php-sam)
[![PHP Stan](https://github.com/theimpossibleastronaut/php-sam/workflows/PHP%20Stan/badge.svg)](https://packagist.org/packages/theimpossibleastronaut/php-sam)
[![PHP Composer](https://github.com/theimpossibleastronaut/php-sam/workflows/PHP%20Composer/badge.svg)](https://packagist.org/packages/theimpossibleastronaut/php-sam)# php-sam
Implementation for the SAMv3 bridge in PHP.(Based on the article ["So you want to write a SAM library"](http://geti2p.net/en/blog/post/2019/06/23/sam-library-basics))
Most basic features are implemented. Go ahead and play with the examples.
It's very basic as well. Requires PHP 7.2+.```php
connect( false );
$sam->commandSAM( "HELLO VERSION MIN=3.0 MAX=3.1 \n" );
```You can also use composer for this.
```
composer require theimpossibleastronaut/php-sam
```And then use the autoloader:
```php
connect( false );
$sam->commandSAM( "HELLO VERSION MIN=3.0 MAX=3.1 \n" );
```In order to run the tests, enable zend.assertions in your php.ini (don't do that in production) and run
```
php test/assert.php
```