From c2c1e4504b6c13201db1a832a94e5f1e6ba718eb Mon Sep 17 00:00:00 2001 From: eric_tian Date: Wed, 1 Jul 2009 00:47:09 +0000 Subject: sync tracker 210250&210253 of R8 into R9, which fix the issue of iSCSI CHAP Secret UI allows the minimum number of 13 characters while the spec only requires 12 git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8694 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Universal/Network/IScsiDxe/IScsiCHAP.h | 4 ++-- .../Network/IScsiDxe/IScsiConfigDxeStrings.uni | Bin 6652 -> 6652 bytes .../Network/IScsiDxe/IScsiConfigNVDataStruc.h | 13 +++++++++---- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiCHAP.h b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiCHAP.h index 2bae18fc33..cce7e5a324 100644 --- a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiCHAP.h +++ b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiCHAP.h @@ -50,9 +50,9 @@ typedef enum { typedef struct _ISCSI_CHAP_AUTH_CONFIG_NVDATA { UINT8 CHAPType; CHAR8 CHAPName[ISCSI_CHAP_NAME_MAX_LEN]; - CHAR8 CHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN]; + CHAR8 CHAPSecret[ISCSI_CHAP_SECRET_STORAGE]; CHAR8 ReverseCHAPName[ISCSI_CHAP_NAME_MAX_LEN]; - CHAR8 ReverseCHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN]; + CHAR8 ReverseCHAPSecret[ISCSI_CHAP_SECRET_STORAGE]; } ISCSI_CHAP_AUTH_CONFIG_NVDATA; #pragma pack() diff --git a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxeStrings.uni b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxeStrings.uni index 0c91ce61f1..c9ece91532 100644 Binary files a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxeStrings.uni and b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigDxeStrings.uni differ diff --git a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigNVDataStruc.h b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigNVDataStruc.h index 7b77a19e78..8f1aaeacb1 100644 --- a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigNVDataStruc.h +++ b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfigNVDataStruc.h @@ -66,8 +66,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #define KEY_DEVICE_ENTRY_BASE 0x1000 #define ISCSI_LUN_STR_MAX_LEN 21 -#define ISCSI_CHAP_SECRET_MIN_LEN 13 -#define ISCSI_CHAP_SECRET_MAX_LEN 17 +#define ISCSI_CHAP_SECRET_MIN_LEN 12 +#define ISCSI_CHAP_SECRET_MAX_LEN 16 +// +// ISCSI_CHAP_SECRET_STORAGE = ISCSI_CHAP_SECRET_MAX_LEN + sizeof (NULL-Terminator) +// +#define ISCSI_CHAP_SECRET_STORAGE 17 + #define ISCSI_CHAP_NAME_MAX_LEN 126 #pragma pack(1) @@ -89,9 +94,9 @@ typedef struct { UINT8 CHAPType; CHAR16 CHAPName[ISCSI_CHAP_NAME_MAX_LEN]; - CHAR16 CHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN]; + CHAR16 CHAPSecret[ISCSI_CHAP_SECRET_STORAGE]; CHAR16 ReverseCHAPName[ISCSI_CHAP_NAME_MAX_LEN]; - CHAR16 ReverseCHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN]; + CHAR16 ReverseCHAPSecret[ISCSI_CHAP_SECRET_STORAGE]; } ISCSI_CONFIG_IFR_NVDATA; #pragma pack() -- cgit v1.2.3