svn commit: r1335267 - /ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1335267 - /ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java

doogie-3
Author: doogie
Date: Mon May  7 21:27:25 2012
New Revision: 1335267

URL: http://svn.apache.org/viewvc?rev=1335267&view=rev
Log:
FIX: Bare passwords(circa 595296) comparisons were broken; they actually
used the oldFunnyHex encoding, not the fixed correct hex encoding.

Modified:
    ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java?rev=1335267&r1=1335266&r2=1335267&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/crypto/HashCrypt.java Mon May  7 21:27:25 2012
@@ -96,8 +96,7 @@ public class HashCrypt {
         String hashed = crypted;
         MessageDigest messagedigest = getMessageDigest(hashType);
         messagedigest.update(bytes);
-        char[] digestChars = Hex.encodeHex(messagedigest.digest());
-        return hashed.equals(new String(digestChars));
+        return hashed.equals(oldFunnyHex(messagedigest.digest()));
     }
 
     /*