GNOME Bugzilla – Bug 524826
Should use glib to calculate md5 hash
Last modified: 2008-09-06 21:20:39 UTC
g_checksum_* will do the job.
g_checksum_* was added in glib 2.16 which was released this month, so for now, g_checksum_* use would have to be optional (or rb would need to ship a copy of gchecksum.[ch] for people with older glibs)
The 'MD5' used for DAAP hashing is actually not standard MD5, the algorithm was slightly modified. From http://crazney.net/programs/itunes/authentication.html - "Apple (obviously in a futile attempt to prevent people from reversing the algorithm) has changed one byte in the MD5 Transformation algorithm. Check out authentication/md5.c (in libopendaap) to see which one it is." I'm wondering whether we should just drop the hashing code, since it only works with itunes 6 and earlier, and isn't needed when talking to other daap servers.
Thanks for the bug report. This particular bug has already been reported into our bug tracking system, but please feel free to report any further bugs you find. *** This bug has been marked as a duplicate of 524827 ***