diff options
author | Zhang, Lubo <C:/Program Files (x86)/Git/o=Intel/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=Zhang, Lubob8d> | 2016-03-24 16:45:32 +0800 |
---|---|---|
committer | Jiaxin Wu <jiaxin.wu@intel.com> | 2016-03-25 11:33:02 +0800 |
commit | 3decba3d32382e22357de4eb25da1aedf6462861 (patch) | |
tree | be7812565e03cf7b3b46212831e5b3caca99e1bf /NetworkPkg | |
parent | 651aeac67248c798c8c22dfd04580d8961cf09d0 (diff) | |
download | edk2-platforms-3decba3d32382e22357de4eb25da1aedf6462861.tar.xz |
NetworkPkg:Fix bug when parsing the dhcp6 option 16
when to parse the DHCP6 reply packet,there will be 6
bytes offset before the option data according to
RFC 3315.
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Wu Jiaxin <jiaxin.wu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Zhang Lubo <lubo.zhang@intel.com>
Reviewed-by: Reviewed-by: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Wu Jiaxin <jiaxin.wu@intel.com>
Diffstat (limited to 'NetworkPkg')
-rw-r--r-- | NetworkPkg/HttpBootDxe/HttpBootDhcp6.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/NetworkPkg/HttpBootDxe/HttpBootDhcp6.c b/NetworkPkg/HttpBootDxe/HttpBootDhcp6.c index d2960e4f6c..0157095edf 100644 --- a/NetworkPkg/HttpBootDxe/HttpBootDhcp6.c +++ b/NetworkPkg/HttpBootDxe/HttpBootDhcp6.c @@ -251,8 +251,8 @@ HttpBootParseDhcp6Packet ( Option = Options[HTTP_BOOT_DHCP6_IDX_VENDOR_CLASS];
if (Option != NULL &&
- NTOHS(Option->OpLen) >= 10 &&
- CompareMem (Option->Data, DEFAULT_CLASS_ID_DATA, 10) == 0) {
+ NTOHS(Option->OpLen) >= 16 &&
+ CompareMem ((Option->Data + 6), DEFAULT_CLASS_ID_DATA, 10) == 0) {
IsHttpOffer = TRUE;
}
|