summaryrefslogtreecommitdiff
path: root/CryptoPkg
diff options
context:
space:
mode:
authorQin Long <qin.long@intel.com>2015-09-05 02:19:31 +0000
committervanjeff <vanjeff@Edk2>2015-09-05 02:19:31 +0000
commit59f1fa8dec6ab2b48f5f00a5080af1aa85464fda (patch)
tree8417b20cb207b76e5a715ee073eea921ba2d57fb /CryptoPkg
parent09bcbf6219e3e22a308781ecf447489246be2a44 (diff)
downloadedk2-platforms-59f1fa8dec6ab2b48f5f00a5080af1aa85464fda.tar.xz
CryptoPkg: Fix one wrong parameter for weak key checking
Fix one wrong offset which is passed into DES weak key checking in TdesInit(). (Sync patch r18389 from main trunk.) Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qin Long <qin.long@intel.com> Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2015@18398 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'CryptoPkg')
-rw-r--r--CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c b/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c
index f89094a581..8025a49cc8 100644
--- a/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c
+++ b/CryptoPkg/Library/BaseCryptLib/Cipher/CryptTdes.c
@@ -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 @@ TdesInit (
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 @@ TdesInit (
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;
}