PHP Classes
elePHPant
Icontem

Yet Another Hash Package: Generate a hash of a string using text scrambling

Recommend this page to a friend!
  Info   View files Example   View files View files (5)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2017-12-20 (1 month ago) RSS 2.0 feedNot yet rated by the usersTotal: Not yet counted Not yet ranked
Version License PHP version Categories
yahp 1.0Custom (specified...5.3PHP 5, Cryptography, Text processing
Description Author

This class can generate a hash of a string using text scrambling.

It combines regular hashing algorithms with combined with text scrambling and character shuffling to generate different output of the usual hashing algorithms.

A cost number parameter can make the class use additional passes of hashing algorithms.

  Performance   Level  
Name: zinsou A.A.E.Moïse <contact>
Classes: 30 packages by
Country: Benin Benin
Innovation award
Innovation award
Nominee: 8x

Winner: 1x

Details
Yet Another Hash package is a simple package to generate hash for  string
That will be secure enough to be used for keeping track of user password or other
sensitive information.The generated hash has no default method to reverse it...The
generated hash has a max length of 32 characters just as a md5() hash but is more secure than
a simple md5 or sha1.An optional cost can be  specified to make the hash more difficult to 
be cracked one day.The hashmore class also take as parameter an array reference that will contains
in the output the timestamp salt value at index one and a shuffle value of this timestamp at the index two.
The only way to check a hash value is to used this array and the exact cost of the hashmore class 
used to generate the hash...

How to use:

$x=new Hashmore(new Hashids());
$e=$x->secretstr('leizmo@gmail.com','',10,$ti);  or $e=$x->secretstr('first string here','other string here',10,$ti); 
//$ti will then contains as said above the specific timestamp to use to check after if the passed string is the same
// you will need this array but also the cost here 10 
//just as:
$f=$x->secretstr('leizmo@gmail.com','',10,$ti); or $f=$x->secretstr('first string here','other string here',10,$ti); 

//then
if($f==$e) 'echo you are welcome';
else echo 'get out here .....';

Note:First time you use  the last parameter(&$time) you don't need to specify a value but you can specify a boolean value or a specific 
float value and even an array.A boolean value will be considered as if you have used time() or microtime() function .A float value 
will be taken as if you specify a specific timestamp.In the two cases a new hash string will be generated.

You can see some basic test in the testHashmore.php...

Finally you must be aware that the package has as dependency hashids/hashids  that you can simply install with composer(composer require hashids/hashids)
or manually by downloading it at https://github.com/ivanakimov/hashids.php.git and install it
You can also globally install dependencies and autoloader by simply use composer with update command.

Please report bug and other at leizmo@gmail.com or use the forum to do it...
  Files folder image Files  
File Role Description
Accessible without login Plain text file composer.json Conf. composer dependencies json file
Plain text file Ezama_Hashmore.php Class class source
Accessible without login Plain text file license.txt Lic. license file
Accessible without login Plain text file readme.txt Doc. readme
Accessible without login Plain text file testHashmore.php Example example script

 Version Control Unique User Downloads  
 0%
Total:0
This week:0