title: Arduino & Python MD5
body: <p>Well I tried hashing a string or at least a set of numbers in Python and compare it with the one generated using the MD5 Library updated by Scott MacVicar on the Arduino but the results I get are differents.</p>
  
  <p>Arduino Code:</p>
  
  <pre><code>#include &lt;MD5.h&gt; 
  
  void setup()
  {
     //initialize serial
     Serial.begin(9600);
     //give it a second
     delay(1000);
     //generate the MD5 hash for our string
     unsigned char* hash=MD5::make_hash("hello");
     //generate the digest (hex encoding) of our hash
     char *md5str = MD5::make_digest(hash, 16);
     //print it on our serial monitor
     Serial.println(md5str);
  }
  </code></pre>
  
  <p>Result: 5d41402abc4b2a76b9e4080020008c00</p>
  
  <p>Python Code:</p>
  
  <pre><code>from hashlib import md5
  
  m = md5('hello').hexdigest()
  print m    
  </code></pre>
  
  <p>Result: 5d41402abc4b2a76b9719d911017c592</p>
  
  <p>From what I can see in every attempt is that the difference comes at the last 14 characters. But the length of the generated hashes are the same!</p>
  
  <p>What am I doing wrong?? Thanks</p>
  
  <p>Edit:</p>
  
  <p>I used a command from the terminal and got:</p>
  
  <pre><code>echo -n 'hello' | openssl md5
  </code></pre>
  
  <p>Result: 5d41402abc4b2a76b9719d911017c592</p>
  
  <p>Which makes me think that the root of the problem is in the arduino code</p>