maikschneider / steganography
Simple implementation of Steganography (Hiding a hidden message within an image)
v1.0.2
2023-10-08 10:39 UTC
Requires
- ext-gd: *
- ext-zlib: *
- symfony/options-resolver: >4.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.12
- php-coveralls/php-coveralls: ^2.0
- phpunit/phpunit: ^10.3
- rector/rector: ^0.18.0
This package is auto-updated.
Last update: 2024-11-14 21:09:04 UTC
README
Simple PHP implementation of Steganography (Hiding a hidden message within an image)
Requirements
- PHP8.1+
Installation
composer require maikschneider/steganography
Usage
Put your message into an image
<?php use MaikSchneider\Steganography\Processor; $processor = new Processor(); $image = $processor->encode('/path/to/image.jpg', 'Message to hide'); // jpg|png|gif // Save image to file $image->write('/path/to/image.png'); // png only // Or outout image to stdout $image->render();
Extract message from an image
<?php use MaikSchneider\Steganography\Processor; $processor = new Processor(); $message = $processor->decode('/path/to/image.png'); echo $message; // "Message to hide"
License
The MIT License
Author
Kazuyuki Hayashi (@kzykhys)