From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 7CE85D80591 for ; Thu, 8 Feb 2024 23:30:57 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=FLvRdZSSHyk90BdXQ3v2VWlILwAgf7PH061ytnpqJv4=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20140610; t=1707435056; v=1; b=uvGtZDA850Ky0HIsjKS2ftEPXJ7XbLnnlzTfaPpMaqH0cvBvNPNl2MqV5+Sf9Kqzx67M3QPo 1TfgMBwETLEMwa9M6wSzrYaJmjruQFzuS1YJ2uc79ekfT/tapyfRzaVIVAI5wgISdeNTXOSleZC z2TLd+4ETzq/v7CVYCoRPuOA= X-Received: by 127.0.0.2 with SMTP id iSNAYY7687511xcBM01wmIDj; Thu, 08 Feb 2024 15:30:56 -0800 X-Received: from mail-pg1-f174.google.com (mail-pg1-f174.google.com [209.85.215.174]) by mx.groups.io with SMTP id smtpd.web11.4651.1707435055648821819 for ; Thu, 08 Feb 2024 15:30:55 -0800 X-Received: by mail-pg1-f174.google.com with SMTP id 41be03b00d2f7-5d8df34835aso341494a12.0 for ; Thu, 08 Feb 2024 15:30:55 -0800 (PST) X-Gm-Message-State: U7ZctO9Q67BsYnkkyScmTXvox7686176AA= X-Google-Smtp-Source: AGHT+IHBTVO6ftiDdDZc/yR7NxJsboe+O64J+6aVLFLt/bcMNJ2dHpHleAPpF9/NJAcpFK409aRqJw== X-Received: by 2002:a05:6a20:3c91:b0:19e:5e80:2802 with SMTP id b17-20020a056a203c9100b0019e5e802802mr2126396pzj.9.1707435054523; Thu, 08 Feb 2024 15:30:54 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCWH2flTlr3L7wdx+ZPTHna9UZX/JwwbbDUy0jt5qbEbk3Cu2s3/z7UAzRaD6KoBkLF05ggA1z0MegRf1639qoHWbcy8bwdNWKD1LmLSgnqpmg== X-Received: from localhost.localdomain ([24.17.138.83]) by smtp.gmail.com with ESMTPSA id fn6-20020a056a002fc600b006e03c2f96fbsm331391pfb.148.2024.02.08.15.30.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 15:30:54 -0800 (PST) From: "Doug Flick via groups.io" To: devel@edk2.groups.io Cc: Saloni Kasbekar , Zachary Clark-williams Subject: [edk2-devel] [PATCH v1 1/3] NetworkPkg: Dhcp6Dxe: SECURITY PATCH CVE-2023-45229 Related Patch Date: Thu, 8 Feb 2024 16:20:35 -0800 Message-ID: <20240209002037.10414-2-doug.edk2@gmail.com> In-Reply-To: <20240209002037.10414-1-doug.edk2@gmail.com> References: <20240209002037.10414-1-doug.edk2@gmail.com> MIME-Version: 1.0 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,dougflick@microsoft.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: base64 X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=uvGtZDA8; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io; dmarc=pass (policy=none) header.from=groups.io RnJvbTogRG91ZyBGbGljayA8ZG91Z2ZsaWNrQG1pY3Jvc29mdC5jb20+CgpSRUY6IGh0dHBzOi8v YnVnemlsbGEudGlhbm9jb3JlLm9yZy9zaG93X2J1Zy5jZ2k/aWQ9NDY3MwpSRUY6IGh0dHBzOi8v YnVnemlsbGEudGlhbm9jb3JlLm9yZy9zaG93X2J1Zy5j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B7DQorICAgIC8vDQorICAgIC8vIFZlcmlmeSB3ZSBoYXZlIGEgZnVsbHkgZm9y bWVkIElBX05BDQorICAgIC8vDQorICAgIGlmIChPcHRpb25MZW4gPCBESENQNl9NSU5fU0laRV9P Rl9JQV9OQSkgew0KKyAgICAgIHJldHVybiBFRklfREVWSUNFX0VSUk9SOw0KKyAgICB9DQorDQor ICAgIC8vDQorICAgIC8vIEdldCB0aGUgSUEgSW5uZXIgT3B0aW9uIGFuZCBMZW5ndGgNCisgICAg Ly8NCisgICAgSWFJbm5lck9wdFRtcCA9IERIQ1A2X09GRlNFVF9PRl9JQV9OQV9JTk5FUl9PUFQg KE9wdGlvbik7DQorDQorICAgIC8vDQorICAgIC8vIFZlcmlmeSB0aGUgSWFJbm5lckxlbiBpcyB2 YWxpZC4NCisgICAgLy8NCisgICAgSWFJbm5lckxlblRtcCA9IChVSU5UMTYpTlRPSFMgKFJlYWRV bmFsaWduZWQxNiAoKFVJTlQxNiAqKURIQ1A2X09GRlNFVF9PRl9PUFRfTEVOIChPcHRpb24pKSk7 DQorICAgIGlmIChJYUlubmVyTGVuVG1wIDwgREhDUDZfU0laRV9PRl9DT01CSU5FRF9JQUlEX1Qx X1QyKSB7DQorICAgICAgcmV0dXJuIEVGSV9ERVZJQ0VfRVJST1I7DQorICAgIH0NCisNCisgICAg SWFJbm5lckxlblRtcCAtPSBESENQNl9TSVpFX09GX0NPTUJJTkVEX0lBSURfVDFfVDI7DQorICB9 IGVsc2UgaWYgKElhVHlwZSA9PSBEaGNwNk9wdElhdGEpIHsNCisgICAgLy8NCisgICAgLy8gVmVy aWZ5IHRoZSBPcHRpb25MZW4gaXMgdmFsaWQuDQorICAgIC8vDQorICAgIGlmIChPcHRpb25MZW4g PCBESENQNl9NSU5fU0laRV9PRl9JQV9UQSkgew0KKyAgICAgIHJldHVybiBFRklfREVWSUNFX0VS Uk9SOw0KKyAgICB9DQorDQorICAgIElhSW5uZXJPcHRUbXAgPSBESENQNl9PRkZTRVRf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Skgew0KLSAgICAgIHJldHVybiBFRklfREVWSUNF X0VSUk9SOw0KLSAgICB9DQotDQotICAgIElhSW5uZXJPcHRUbXAgPSBESENQNl9PRkZTRVRfT0Zf SUFfVEFfSU5ORVJfT1BUIChPcHRpb24pOw0KLQ0KLSAgICAvLyBWZXJpZnkgdGhlIElhSW5uZXJM ZW4gaXMgdmFsaWQuDQotICAgIElhSW5uZXJMZW5UbXAgPSAoVUlOVDE2KU5UT0hTIChSZWFkVW5h bGlnbmVkMTYgKChVSU5UMTYgKikoREhDUDZfT0ZGU0VUX09GX09QVF9MRU4gKE9wdGlvbikpKSk7 DQotICAgIGlmIChJYUlubmVyTGVuVG1wIDwgREhDUDZfU0laRV9PRl9JQUlEKSB7DQotICAgICAg cmV0dXJuIEVGSV9ERVZJQ0VfRVJST1I7DQotICAgIH0NCi0NCi0gICAgSWFJbm5lckxlblRtcCAt PSBESENQNl9TSVpFX09GX0lBSUQ7DQotICB9IGVsc2Ugew0KLSAgICByZXR1cm4gRUZJX0RFVklD RV9FUlJPUjsNCi0gIH0NCi0NCi0gICpJYUlubmVyT3B0ID0gSWFJbm5lck9wdFRtcDsNCi0gICpJ YUlubmVyTGVuID0gSWFJbm5lckxlblRtcDsNCi0NCi0gIHJldHVybiBFRklfU1VDQ0VTUzsNCi19 DQotDQogLyoqDQogICBTZWVrIFN0YXR1c0NvZGUgT3B0aW9uIGluIHBhY2thZ2UuIEEgU3RhdHVz IENvZGUgb3B0aW9uIG1heSBhcHBlYXIgaW4gdGhlDQogICBvcHRpb25zIGZpZWxkIG9mIGEgREhD UCBtZXNzYWdlIGFuZC9vciBpbiB0aGUgb3B0aW9ucyBmaWVsZCBvZiBhbm90aGVyIG9wdGlvbi4N Ci0tIAoyLjQzLjAKCg== -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#115276): https://edk2.groups.io/g/devel/message/115276 Mute This Topic: https://groups.io/mt/104249912/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-