Revision: 18389
          http://sourceforge.net/p/edk2/code/18389
Author:   lgao4
Date:     2015-09-02 08:44:46 +0000 (Wed, 02 Sep 2015)
Log Message:
-----------
CryptoPkg: Fix one wrong parameter for weak key checking

Fix one wrong offset which is passed into DES weak key checking in TdesInit().

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qin Long <[email protected]>
Reviewed-by: Jiaxin Wu <[email protected]>

Modified Paths:
--------------
    trunk/edk2/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c

Modified: trunk/edk2/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c
===================================================================
--- trunk/edk2/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c        
2015-09-02 08:44:24 UTC (rev 18388)
+++ trunk/edk2/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c        
2015-09-02 08:44:46 UTC (rev 18389)
@@ -1,7 +1,7 @@
 /** @file
   TDES Wrapper Implementation over OpenSSL.
 
-Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2010 - 2015, Intel Corporation. All rights reserved.<BR>
 This program and the accompanying materials
 are licensed and made available under the terms and conditions of the BSD 
License
 which accompanies this distribution.  The full text of the license may be 
found at
@@ -90,7 +90,7 @@
     return TRUE;
   }
 
-  if (DES_is_weak_key ((const_DES_cblock *) Key + 8) == 1) {
+  if (DES_is_weak_key ((const_DES_cblock *) (Key + 8)) == 1) {
     return FALSE;
   }
 
@@ -101,7 +101,7 @@
     return TRUE;
   }
 
-  if (DES_is_weak_key ((const_DES_cblock *) Key + 16) == 1) {
+  if (DES_is_weak_key ((const_DES_cblock *) (Key + 16)) == 1) {
     return FALSE;
   }
 


------------------------------------------------------------------------------
Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
Get real-time metrics from all of your servers, apps and tools
in one place.
SourceForge users - Click here to start your Free Trial of Datadog now!
http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to