Hi,
I am trying to MD5 a string in ActionScript using the MD5 algorithm that was created by Adobe and is part of AS3corelib. (http://as3corelib.googlecode.com/svn/trunk/src/com/adobe/crypto/MD5.as).
I am comparing this to an MD5 created in php that I know is correct.
If I create MD5s using AS and PHP for say a string like "abcd1234" they both are equal, as is to be expected. The problem is, when my string contains some hexadecimal in it ie "abcd\x28\xBF\x4E", the MD5s from ActionSCript and php return different value.
Now the really strange part is as long as the hexadecimal is in the form of a number when its a string its fine and still matches:
ie
"abcd\x28\x46" will have matching values from AS's MD5 and php's MD5. While "abcd\x28\xBF" will yield different hashes.
Anyone have any ideas? I've tested the php MD5 thoroughly and I know it is correct and the ActionScript is incorrect. I appreciate the help, thanks for reading and I apologize if this was confusing. I'm a noob when it comes to string encoding, representation etc. Thanks, Drew S.