a2way/laravel-hash

There is no license information available for the latest version (1.2.0) of this package.

1.2.0 2014-12-31 16:52 UTC

README

#A2Way Laravel Tenant Migrate

A2Way Laravel Hash is a Laravel package that adds a command to Laravel Artisan that can be used to hash strings from the command-line. It also provides an option to check a hash against a string.

##Commands Available

###hash:make (string)

Hashes the given string and prints it in the command-line.

Example:

$ php artisan hash:make test

$2y$10$ufVpBwO/dsPs5yc3NhLyXuKPuWgFW9.5XYNSrVWf.FbHQA9aKrPja

###hash:check (string) (hash)

Checks the given string against the given hash and prints “Match!” if matches — “Fail!” if not.

Note: The hash must be provided within single-quotes.

Example:

$ php artisan hash:check test '$2y$10$ufVpBwO/dsPs5yc3NhLyXuKPuWgFW9.5XYNSrVWf.FbHQA9aKrPja'

Match!

$ php artisan hash:check not-test '$2y$10$ufVpBwO/dsPs5yc3NhLyXuKPuWgFW9.5XYNSrVWf.FbHQA9aKrPja'

Fail

php artisan hash:check test 'not-$2y$10$ufVpBwO/dsPs5yc3NhLyXuKPuWgFW9.5XYNSrVWf.FbHQA9aKrPja'

Fail

##Installing

  1. Issue the following command:

    composer require a2way/laravel-hash 1.*
    
  2. Then add the following line to your Laravel app’s “app/config/app.php” file’s “providers” sub-array.

    A2Way\LaravelHash\LaravelHashServiceProvider
    
  3. Check the installation by issuing "php artisan command". If you are able to see the above commands in your list of commands, installation was successful.

##Contributing

Please read http://a2way.com/contributing/ before contributing.