Download the PHP package spoova/hasher without Composer

On this page you can find all versions of the php package spoova/hasher. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package hasher

Hasher

Hasher is a php package for generating dynamic or static hashes by combining varying hashing algorithms in a specific number of times.

Initializing Class

The hasher class can be instantiated as shown below

Definining Hash Data

The data to be hashed can be defined by using the method using the syntax below

An example of data specified to be hashed is shown below

Defining Hashing Algorithm

The method is being used to define the hashing algorithm to be used for hashing a data. For example, after the method, we can supply a list of algorithms as below

In the code above, each function will be used for hashing the data specified in method

Processing and obtaining static hashed data

In order to execute the hashing and obtain the hash data the method is called. This method will execute and return the hashed data.

Process and return hashed data

The method also takes an integer parameter which makes it possible to execute the hashing in a number of specified times.

Processing and obtaining dynamic hashed data

While method returns a static hashed data by default, the returned data can be specified as dynamic through the method. This means that different hashed data will be generated when the method is called.

Generate a random hash from specified data

Generate a random hash by using dynamic functions

Behavioural Pattern of Hashify

The hashify function keeps track of its last state and generates a new hash once it is recalled. This means that every time method is called, a newly hashed data is generated from its last state. For example

In the code above, the hashify will continue to generate a new data until the hash node is restarted by supplying an argument of zero(0) to the hashify method. Once the hash node is restarted the data returned will be the first hash while the subsequent called will reflect its previous pattern. We may however try to be specific in the number of calls through the argument supplied. For example:

In the code above the data will be recorded as the same data with . This is because contains a data returned after three(3) successful calls of hashify. This data matches the exact number of times supplied as argument in the . This means that rather than running the without arguments for 4 consecutive times, we can easily supply the number of specific times of hash as arguments and the corresponding data will be returned. Also, in other to prevent hashify() from constantly changing, the first argument supplied must be false as shown below:

The hashify function also assumes a list of hash function which overides any default declared if an array is supplied as first argument

In cases where two arguments are supplied, the first must be integer or boolean while the second array argument should contain the hashing algorithm. For example:

Generate an independent random hash

Other random hashes can be generated independently through the method. This method is a stand alone method that does not depend on any other method to perform its functions.

Generate random hash of specific length of characters

Generate random hash of specific length using specific range of characters

Generate random hash using specfied alogithms. Note that hash length can only be specified by the last algorithm used, hence the length is not applied.


All versions of hasher with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package spoova/hasher contains the following files

Loading the files please wait ....