deemru/cryptash

Hash-based encrypt/decrypt

1.0.1 2019-01-19 17:51 UTC

This package is auto-updated.

Last update: 2021-07-20 04:15:17 UTC


README

packagist php-v travis codacy license

Cryptash implements hash based encryption with user-defined size of IV and MAC.

It is a pretty simple way to protect and verify your data transfers which goes outside.

Usage

$cryptash = new Cryptash( 'Password' );
$msg = 'Hello, world!';

$encrypted = $cryptash->encryptash( $msg );
$decrypted = $cryptash->decryptash( $encrypted );

if( $decrypted !== $msg )
    exit( 1 );

Requirements

Installation

Require through Composer:

{
    "require": {
        "deemru/cryptash": "1.0.*"
    }
}