md5
in php:
md5 ( string $str [, bool $raw_output = false ] )
If the optional raw_output is set to TRUE, then the md5 digest is instead returned in raw binary format with a length of 16.
so you can do this following in php:
$ php -a
>>> md5('data', true)
=> b"ìw\x7F8]=■╚ü] ¸I`&▄"
I was tried using crypto in nodejs:
$ node
>>> crypto.createHash('md5').update('data').digest('binary')
'w8]=þÈ] ÷I`&Ü'
But the result not same
I want to encrypt data with raw_output option in nodejs, how to achieve it?