Md 5 online

MD5 FUNCTION

MD5 is a message digest algorithm and is also a hash function. It is a hash function not an encryption or decryption function. The meaning of hash is “chopped meat into small pieces”. We give any input in string form of any arbitrary size. And it is converted into fixed size hexadecimal or binary characters. But we cannot be able to convert our message in its original form.  In a simple way, it is one way process in which you cannot reverse back.  In MD5 function, data which is sent is totally changed with processed data. It is used for verification of any data.

 

MD5 used in verification

Md5 function is implemented in a website or any security devices.  A user uses this implemented site, put password or any other data.  Data is hashed and saved in database. When he/she logs in again, his/her input compares with saved data. If it matches, he/she can take access in this site.

MD5 algorithm

Md5 has a simple syntax.

Md5 (string raw)

String; our message or input data

It is essential to be filled this.

Raw; in which size our input data should be

It has two values “true” and “false”. By default it has “false” value.

True; 16 characters binary format

False; 32 characters hexa number

Implementation of md5

Example 1;

<! DOCTYPE html>
<html>
<body>

<?php
$psw= “my password is password”;
echo md5($psw);

?>
  
</body>
</html>

It gives output: 5c614f9d32a387f9f95eab1ada957313

 

Example 2;

<! DOCTYPE html>
<html>
<body>

<?php
$psw = “using this md5 function I encrypt my data into fixed size array”;
echo md5($psw);

?>
  
</body>
</html>

It gives output: 64d9e87cd58fc9a5bdbf531313563b85

Both messages give output of same size of 32 bit. No matter how can be long an input. If we write “true” in md5 function its output is in 16 bit.