harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r832728 - /harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java
Date Wed, 04 Nov 2009 12:49:30 GMT
Author: tellison
Date: Wed Nov  4 12:49:30 2009
New Revision: 832728

URL: http://svn.apache.org/viewvc?rev=832728&view=rev
Log:
Clarify comment on ensuring constant time equality checking.

Modified:
    harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java

Modified: harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java?rev=832728&r1=832727&r2=832728&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/MessageDigest.java
Wed Nov  4 12:49:30 2009
@@ -296,8 +296,8 @@
         if (digesta.length != digestb.length) {
             return false;
         }
-        // No early return is allowed to avoid timing attack
-        // We have to return false until all elements are compared 
+        // No early return is allowed to avoid timing attack.
+        // We must not return false until all elements are compared 
         // to keep the computing time constant
         boolean result = true;
         for (int i = 0; i < digesta.length; i++) {



Mime
View raw message