Conver char-Array to MD5-Hash
hello,
i´m trying convert char array md5 hash arduino mega libary: https://github.com/tzikis/arduinomd5
here's source:
the problem is, if use array test1 in hash funktion hash result not same hashed test2 variable. why?
i´m trying convert char array md5 hash arduino mega libary: https://github.com/tzikis/arduinomd5
here's source:
code: [select]
#include <md5.h>
char test1[6]={'1','2','3','4','5','7'};
char *test2="123457";
byte zaehler;
void setup()
{
//initialize serial
serial.begin(9600);
//give second
delay(1000);
//generate md5 hash our string
unsigned char* hash=md5::make_hash(test);
//generate digest (hex encoding) of our hash
char *md5str = md5::make_digest(hash, 16);
free(hash);
//print on our serial monitor
serial.println(md5str);
//give memory system if run md5 hash generation in loop
free(md5str);
serial.println(md5str);
}
void loop()
{
serial.println(test);
}
the problem is, if use array test1 in hash funktion hash result not same hashed test2 variable. why?
Arduino Forum > Using Arduino > Networking, Protocols, and Devices (Moderator: fabioc84) > Conver char-Array to MD5-Hash
arduino
Comments
Post a Comment