From nobody Thu May 16 15:11:37 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+108044+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108044+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1693133843; cv=none; d=zohomail.com; s=zohoarc; b=Mvggw+k9ctNL4CfAQ5mNhNLoeVXDstOLCr6q80MD6zpz4A/1JPITqQW0Te9aMxDqhwyTZVOIpjCzWGktJ96cdY3FMszJjjINogYfyb7Aj4OE+kj67x041y/uO/gwPN5Qt29UcYbx4DmqZRl913w9N5C8YLUid44e5mEPVuA+cVY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693133843; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=nzTd/tseHzecKZIfHrYNJuylk5nBEqdbIyI/O/6bqFU=; b=UsqlzflsyBKCKyrzEsF0bj99dhC8CAEXRSamFsOZvDVtolk9l0hrgrZy2sYtIchGKCT+8H9WAuGehiuCKAJmtIzmUkDMJuM6GzomteoyjdZ5MfZokyDDWtBVAq7iFDGgmcXJH1SlXpjlSq9rTRiMbOscY4Y7Cd60/HZQdDPE180= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108044+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1693133843257924.1404353836417; Sun, 27 Aug 2023 03:57:23 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=vAaeHdy/qCA9v3L1DgViaTybCSo8i81tBwjdqigdqak=; 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=1693133842; v=1; b=fkm0CwMl7PqP+o5oMOtdAr5zID4hDTKa1SjWeMV3N2lTOWi2pgjx0BKdbY5XBl3zYic5uUMC 68bkvtESnrTiLewhKKoUThZl+J9MnVGi+GO3YbTesJ1uTI0++rAEdMl4+7Af1xqbNpJYJ3oHfMt 9jn37uQrvHeTIcBbsrDUw/oQ= X-Received: by 127.0.0.2 with SMTP id rhCvYY1788612xYqUsqswYjw; Sun, 27 Aug 2023 03:57:22 -0700 X-Received: from mail-lf1-f45.google.com (mail-lf1-f45.google.com [209.85.167.45]) by mx.groups.io with SMTP id smtpd.web11.25130.1693133842129748370 for ; Sun, 27 Aug 2023 03:57:22 -0700 X-Received: by mail-lf1-f45.google.com with SMTP id 2adb3069b0e04-500b0f06136so1376701e87.0 for ; Sun, 27 Aug 2023 03:57:21 -0700 (PDT) X-Gm-Message-State: x1n4iwRksZPLdwCel6RuucJTx1787277AA= X-Google-Smtp-Source: AGHT+IGU6KXWd5Wid/f+LVjVWoeJmspceN1GWwm2pnO/jvqaVR0ViALb+9QnpTb9jSzcYlMLt9zMcg== X-Received: by 2002:a05:6512:368c:b0:500:9946:9c69 with SMTP id d12-20020a056512368c00b0050099469c69mr7432683lfs.29.1693133840028; Sun, 27 Aug 2023 03:57:20 -0700 (PDT) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id i11-20020ac2522b000000b004fb9fe34c27sm1085825lfl.92.2023.08.27.03.57.18 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 27 Aug 2023 03:57:19 -0700 (PDT) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 1/5] RedfishClientPkg: fix crash on access to uninialized list variable. Date: Sun, 27 Aug 2023 13:56:36 +0300 Message-Id: <20230827105640.94731-2-mike.maslenkin@gmail.com> In-Reply-To: <20230827105640.94731-1-mike.maslenkin@gmail.com> References: <20230827105640.94731-1-mike.maslenkin@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,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1693133844825100005 Content-Type: text/plain; charset="utf-8" Signed-off-by: Mike Maslenkin --- RedfishClientPkg/Features/Bios/v1_0_9/Common/BiosCommon.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/RedfishClientPkg/Features/Bios/v1_0_9/Common/BiosCommon.c b/Re= dfishClientPkg/Features/Bios/v1_0_9/Common/BiosCommon.c index b9c799e07684..a1738de46fdf 100644 --- a/RedfishClientPkg/Features/Bios/v1_0_9/Common/BiosCommon.c +++ b/RedfishClientPkg/Features/Bios/v1_0_9/Common/BiosCommon.c @@ -97,6 +97,8 @@ RedfishConsumeResourceCommon ( if (BiosCs->Attributes =3D=3D NULL) { BiosCs->Attributes =3D AllocateZeroPool (sizeof (RedfishBios_V1_0_9_At= tributes_CS)); ASSERT (BiosCs->Attributes !=3D NULL); + // initialize list + BiosCs->Attributes->Prop.ForwardLink =3D &BiosCs->Attributes->Prop; } =20 // --=20 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#108044): https://edk2.groups.io/g/devel/message/108044 Mute This Topic: https://groups.io/mt/100988471/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Thu May 16 15:11:37 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+108045+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108045+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1693133844; cv=none; d=zohomail.com; s=zohoarc; b=mFZ1hNPGeZtk3ImJZuSfkZ36wgaNqIsOAhkZY8/X1hd3VVeDzsasqXbABMe46zrN6etvUrWP0sbP8cUetnz/MdpDK53BpoeeZmI5xqsa+8zQqOrQDGCUnT7yRzYHCiv4QwC8LcVrmUgfsQysH0wASjXorXcVWQbAaWuT8hgQRlw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693133844; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=m7hIPbIkvvE2cF9ae62ed8Cd8bZsim3Bhhc8figX7SE=; b=SsF9z7XrAhwuhTaMtJC6PG/6/x5OSWxDYFOn3QtP+ox2ketw16F9e9FErQg/95L/ULGAtu+nJAyNGYZcqo0pGRjMOYOpQaANfR0X6fcp0Y7Jt2+HTtGWVV3TjJRgCEyAnA78pVj/TOlSLo/NFuzA5soZScwmdEKLJ1YpSde5DZU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108045+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1693133844216300.2783049172566; Sun, 27 Aug 2023 03:57:24 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=1qAdvviNzG3psZm+/0D8LSfLQ4OpFx9d2fi7Y77OEnU=; 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=1693133843; v=1; b=O50FR1ZF5UxaMmYU37W9cFCiDJQ4G1smGDi7N4AJvdGjE49T1rKycBNlYEWFJ+uxmdftSlW5 I79whSKgIas/5X+mZuCOv7NoShH5hxmlhyZahMMA9iYiX5LAcO7NYLZ2Qv9NyIs6+dkWOfRlt9j ZtBZrx5LKf4swED6+6GXYbwI= X-Received: by 127.0.0.2 with SMTP id emnyYY1788612xDjvsEcHKXB; Sun, 27 Aug 2023 03:57:23 -0700 X-Received: from mail-lf1-f46.google.com (mail-lf1-f46.google.com [209.85.167.46]) by mx.groups.io with SMTP id smtpd.web11.25131.1693133843138782705 for ; Sun, 27 Aug 2023 03:57:23 -0700 X-Received: by mail-lf1-f46.google.com with SMTP id 2adb3069b0e04-5007f3d3235so3559755e87.2 for ; Sun, 27 Aug 2023 03:57:22 -0700 (PDT) X-Gm-Message-State: cXO1KnugM6hWT9577u9uutunx1787277AA= X-Google-Smtp-Source: AGHT+IE4jSVfGW2ys5rEyEWZRB9T/b6CzMWazSl/Tq+uljV7hPIKL0gmYtiDyqk1YPNYZ0VseS+a5w== X-Received: by 2002:a19:4302:0:b0:500:7a21:3e78 with SMTP id q2-20020a194302000000b005007a213e78mr12503504lfa.55.1693133841315; Sun, 27 Aug 2023 03:57:21 -0700 (PDT) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id i11-20020ac2522b000000b004fb9fe34c27sm1085825lfl.92.2023.08.27.03.57.20 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 27 Aug 2023 03:57:20 -0700 (PDT) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 2/5] RedfishClientPkg: fix access to uninitialized variable Date: Sun, 27 Aug 2023 13:56:37 +0300 Message-Id: <20230827105640.94731-3-mike.maslenkin@gmail.com> In-Reply-To: <20230827105640.94731-1-mike.maslenkin@gmail.com> References: <20230827105640.94731-1-mike.maslenkin@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,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1693133844982100008 Content-Type: text/plain; charset="utf-8" This patch fixes access to uninitialized variable, causing ASSERT from FreePool at least. Before this patch RedfishSettingsResponse was initialized by GetResourceByUri under 'if (JsonValue !=3D NULL)' condition. But freed under 'if (Private->Payload !=3D NULL)' condition. Thus uninitialized pointers caused ASSERT on attempt to free memory. Signed-off-by: Mike Maslenkin --- RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c b/RedfishC= lientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c index e7ac8779581c..f5562fb49cab 100644 --- a/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c +++ b/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c @@ -128,6 +128,8 @@ RedfishResourceConsumeResource ( return Status; } =20 + ZeroMem (&RedfishSettingsResponse, sizeof (REDFISH_RESPONSE)); + ExpectedResponse =3D &Response; RedfishSettingsUri =3D NULL; JsonValue =3D RedfishJsonInPayload (Response.Payload); --=20 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#108045): https://edk2.groups.io/g/devel/message/108045 Mute This Topic: https://groups.io/mt/100988472/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Thu May 16 15:11:37 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+108046+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108046+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1693133845; cv=none; d=zohomail.com; s=zohoarc; b=fdmf+SUuWo/YCGIcuijoG/fcfcMnWzf0HmQL+FoUcYwnef2ZFkty1l102PuzveNV7Z4987ycGvQr1MqDguhRNRDsj60D93ppc4R3cngqAPzfot2Ax/Vh5lEay6raCPkqinfJf0tb3e/WgBn9MXyt/jMba/C6jc995BuTwTkEkZI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693133845; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=3zfOx0NB/Ym+BS6ApA1fhKHwkfIsljN3Hf0wj/iAAuc=; b=DW6+bJpZ5IX66xhdVeTliiYJthSYABr27+Qz6BwQYgx2qKbgedl5453pE/Qg2pQzSZ7U0tOMIaVt/a/DABpFrtJMKlxHXzuux/oabKcJhnbV53A60CdZNk6NhtM/uoe07k6s3otN1fa7oxXpdqk1q7xhx1gJgdRx4jWo6kP+z9w= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108046+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1693133845723505.4679926816739; Sun, 27 Aug 2023 03:57:25 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=z/qucIpF3WQlt0JbUE3tqIiin6OLfqySBPY4f31ldaY=; 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=1693133845; v=1; b=dOBTet98LB1K7noKGwOkjTDIAjZGsPIQC2tUI1VDkU6fjIpWTlUNGw7O5dycDndIECyT0ZcF PJOMwLs8czANZhxR8hMxuyJ5hlk7x0djPNgCPFRxZo5CxONEYfp6f6FR+GzGp9KGykoHhHGjBw8 wws0S7u3krDPvk7FCu4RM4tU= X-Received: by 127.0.0.2 with SMTP id eCchYY1788612xXF0gdsqeaI; Sun, 27 Aug 2023 03:57:25 -0700 X-Received: from mail-lj1-f182.google.com (mail-lj1-f182.google.com [209.85.208.182]) by mx.groups.io with SMTP id smtpd.web10.25219.1693133844465531652 for ; Sun, 27 Aug 2023 03:57:24 -0700 X-Received: by mail-lj1-f182.google.com with SMTP id 38308e7fff4ca-2bcb50e194dso34680021fa.3 for ; Sun, 27 Aug 2023 03:57:24 -0700 (PDT) X-Gm-Message-State: 4LwBqNc7G5VgcaU3oZlw4l57x1787277AA= X-Google-Smtp-Source: AGHT+IEwca23uxwMY510wfiFygyShqqcJTtedQqb+j4dffNtGYyrR+JNt9p8ukcufi8n5V4DOambgw== X-Received: by 2002:ac2:5f4e:0:b0:4f8:49a8:a0e2 with SMTP id 14-20020ac25f4e000000b004f849a8a0e2mr13128001lfz.16.1693133842509; Sun, 27 Aug 2023 03:57:22 -0700 (PDT) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id i11-20020ac2522b000000b004fb9fe34c27sm1085825lfl.92.2023.08.27.03.57.21 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 27 Aug 2023 03:57:21 -0700 (PDT) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 3/5] RedfishClientPkg: fix leak of allocated Etag data Date: Sun, 27 Aug 2023 13:56:38 +0300 Message-Id: <20230827105640.94731-4-mike.maslenkin@gmail.com> In-Reply-To: <20230827105640.94731-1-mike.maslenkin@gmail.com> References: <20230827105640.94731-1-mike.maslenkin@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,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1693133846561100013 Content-Type: text/plain; charset="utf-8" Signed-off-by: Mike Maslenkin --- RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c | 3 +++ .../Features/ComputerSystem/v1_5_0/Dxe/ComputerSystemDxe.c | 3 +++ RedfishClientPkg/Features/Memory/V1_7_1/Dxe/MemoryDxe.c | 3 +++ 3 files changed, 9 insertions(+) diff --git a/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c b/RedfishC= lientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c index f5562fb49cab..b27f1de77660 100644 --- a/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c +++ b/RedfishClientPkg/Features/Bios/v1_0_9/Dxe/BiosDxe.c @@ -220,6 +220,9 @@ RedfishResourceConsumeResource ( Private->Json =3D NULL; } =20 + if (Etag !=3D NULL) { + FreePool (Etag); + } return Status; } =20 diff --git a/RedfishClientPkg/Features/ComputerSystem/v1_5_0/Dxe/ComputerSy= stemDxe.c b/RedfishClientPkg/Features/ComputerSystem/v1_5_0/Dxe/ComputerSys= temDxe.c index 91968dbe488f..c5a168a06a98 100644 --- a/RedfishClientPkg/Features/ComputerSystem/v1_5_0/Dxe/ComputerSystemDxe= .c +++ b/RedfishClientPkg/Features/ComputerSystem/v1_5_0/Dxe/ComputerSystemDxe= .c @@ -164,6 +164,9 @@ RedfishResourceConsumeResource ( Private->Json =3D NULL; } =20 + if (Etag !=3D NULL) { + FreePool (Etag); + } return Status; } =20 diff --git a/RedfishClientPkg/Features/Memory/V1_7_1/Dxe/MemoryDxe.c b/Redf= ishClientPkg/Features/Memory/V1_7_1/Dxe/MemoryDxe.c index c55a6848c74e..91fdb85d3e08 100644 --- a/RedfishClientPkg/Features/Memory/V1_7_1/Dxe/MemoryDxe.c +++ b/RedfishClientPkg/Features/Memory/V1_7_1/Dxe/MemoryDxe.c @@ -164,6 +164,9 @@ RedfishResourceConsumeResource ( Private->Json =3D NULL; } =20 + if (Etag !=3D NULL) { + FreePool (Etag); + } return Status; } =20 --=20 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#108046): https://edk2.groups.io/g/devel/message/108046 Mute This Topic: https://groups.io/mt/100988473/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Thu May 16 15:11:37 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+108047+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108047+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1693133847; cv=none; d=zohomail.com; s=zohoarc; b=egmNS7E20AQMA1FaHR58dejNIMpQwNHGgSgof9E2mHEbZWNKtQlz1MDg9/e/L3osRl4nIg971TPfLllHmf/RHXYoQdXWXnc7COgCBZLPLri+DX3O956es2eVSb/126wcxzxCLj9w0CwnVhFkIsLoAF/M1OSo3LfLt0QyAZUMzgU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693133847; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=eOMxSW7IKPdEbuIjnyb4PE1YXU5p8/VGCfzke6Sd2a4=; b=PyPrcB4FDbbLuMCiofr0RUmbGKdza/xJIVGezLTYs3wO8qvb1h7gKfZ1TQP3lMK8efxOa68sAmeT/WKQ6P4t9zHBm05xt0fCrbzzYhLKtb8xjFALQTM91YyaY+a5r4FRz9+dMy1z2M1im2CYG+JpP4MQ2wVMu9E+Jr8c6xxZVvo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108047+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1693133847121952.3152682922241; Sun, 27 Aug 2023 03:57:27 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=dgArTude6JWvZ5pgitzcXgeosFIE8Z0EceYIbrJw13Q=; 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=1693133846; v=1; b=hWnetgb6k1+B/FY0yBSe8r4gW7NfQw4/vMlLCatwvTu7zpM6C6HZu1tKH7PNzOdMLCgaUQlW KtFcuflDxuqs49IN1+Fltp6pc0E2mq0QHl6vSb+1TqVOL5NXnWD8ihTbU+ACLGvi7OCtt+IE1rk DckkHu/UActSwmDQKWwLI80A= X-Received: by 127.0.0.2 with SMTP id C5WjYY1788612xpFE0rN9amk; Sun, 27 Aug 2023 03:57:26 -0700 X-Received: from mail-lf1-f44.google.com (mail-lf1-f44.google.com [209.85.167.44]) by mx.groups.io with SMTP id smtpd.web10.25220.1693133845994867964 for ; Sun, 27 Aug 2023 03:57:26 -0700 X-Received: by mail-lf1-f44.google.com with SMTP id 2adb3069b0e04-50098cc8967so3685217e87.1 for ; Sun, 27 Aug 2023 03:57:25 -0700 (PDT) X-Gm-Message-State: 9MWv8K0D75QjXIz7ePg97Xe5x1787277AA= X-Google-Smtp-Source: AGHT+IFkM4gTuE8pizkiDMbjasqWNJyGWe8Zxz76aeDWgTRaOcqPp2qnFI7QqZWwhW0a/NpNOFLrDA== X-Received: by 2002:a05:6512:2252:b0:500:8ffe:7486 with SMTP id i18-20020a056512225200b005008ffe7486mr11181607lfu.4.1693133843905; Sun, 27 Aug 2023 03:57:23 -0700 (PDT) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id i11-20020ac2522b000000b004fb9fe34c27sm1085825lfl.92.2023.08.27.03.57.22 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 27 Aug 2023 03:57:23 -0700 (PDT) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 4/5] RedfishClientPkg: fix memory leak during EFI variables write. Date: Sun, 27 Aug 2023 13:56:39 +0300 Message-Id: <20230827105640.94731-5-mike.maslenkin@gmail.com> In-Reply-To: <20230827105640.94731-1-mike.maslenkin@gmail.com> References: <20230827105640.94731-1-mike.maslenkin@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,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1693133848617100017 Content-Type: text/plain; charset="utf-8" Signed-off-by: Mike Maslenkin --- .../RedfishConfigLangMapDxe/RedfishConfigLangMapDxe.c | 6 +++++- RedfishClientPkg/RedfishETagDxe/RedfishETagDxe.c | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/RedfishClientPkg/RedfishConfigLangMapDxe/RedfishConfigLangMapD= xe.c b/RedfishClientPkg/RedfishConfigLangMapDxe/RedfishConfigLangMapDxe.c index 86684cc72e1e..6a72afed8715 100644 --- a/RedfishClientPkg/RedfishConfigLangMapDxe/RedfishConfigLangMapDxe.c +++ b/RedfishClientPkg/RedfishConfigLangMapDxe/RedfishConfigLangMapDxe.c @@ -424,7 +424,11 @@ SaveConfigLangMapList ( gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGuid, VARIAB= LE_ATTRIBUTE_NV_BS, 0, NULL); } =20 - return gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGuid, V= ARIABLE_ATTRIBUTE_NV_BS, VarSize, (VOID *)VarData); + Status =3D gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGui= d, VARIABLE_ATTRIBUTE_NV_BS, VarSize, (VOID *)VarData); + + FreePool (VarData); + + return Status; } =20 /** diff --git a/RedfishClientPkg/RedfishETagDxe/RedfishETagDxe.c b/RedfishClie= ntPkg/RedfishETagDxe/RedfishETagDxe.c index 7ac6e885dea6..a892ced984c8 100644 --- a/RedfishClientPkg/RedfishETagDxe/RedfishETagDxe.c +++ b/RedfishClientPkg/RedfishETagDxe/RedfishETagDxe.c @@ -411,7 +411,11 @@ SaveETagList ( gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGuid, VARIAB= LE_ATTRIBUTE_NV_BS, 0, NULL); } =20 - return gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGuid, V= ARIABLE_ATTRIBUTE_NV_BS, VarSize, (VOID *)VarData); + Status =3D gRT->SetVariable (VariableName, &gEfiRedfishClientVariableGui= d, VARIABLE_ATTRIBUTE_NV_BS, VarSize, (VOID *)VarData); + + FreePool (VarData); + + return Status; } =20 /** --=20 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#108047): https://edk2.groups.io/g/devel/message/108047 Mute This Topic: https://groups.io/mt/100988474/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Thu May 16 15:11:37 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+108048+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108048+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1693133848; cv=none; d=zohomail.com; s=zohoarc; b=X3E4TXbElLmGEdbwUfhyUmNDDP5pPTWEYuy802tZRWC5rPK10jsUiLdJf6yqq7PIk/eVAhXfJzapFz9ZHmKbSTgup1qAus77PalFllZXNe4wAux7HBvhDzMdByNU/bs5zWkFbOv9mMiUZ9KiZSj0/Fca/sOFH7KTr2mMC1HxP+8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693133848; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=yazxwdKs4UcLKH9TFyVW4ag4nnbksO+0GlBz2ETw1S8=; b=nPyUSynNS6yuAXVQCpmE1K30mrMOBlctIIHk/Wa0D7nep5oURYqwHtBuDRtq2PrzJvPHrO6uT7NMDvlyc5LGYsMLt2+bBNuqnuG2du7CNXcjgCjjA+fzP13ZLIaA8CZ9k3knTmSvQbZUTqHg0O9nU5KhogSBNvYWbMYM3GfBDQE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+108048+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1693133848617969.3025219610134; Sun, 27 Aug 2023 03:57:28 -0700 (PDT) Return-Path: DKIM-Signature: a=rsa-sha256; bh=yazxwdKs4UcLKH9TFyVW4ag4nnbksO+0GlBz2ETw1S8=; 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=1693133848; v=1; b=YSUPH7NZyR1YGlX1jHvHJH4I+E9ljY5eKnAtutyaThmqG2Et5HMFTtnB1onKphZqxm22a4hj vK7BQNYjZ9fQU6omnTtWUVdxvlab3Ye3cuNsp6WAcCHyPPI55lZh6tvOitCU5MIg7+w1odVQ3i/ v6AibYNWkmA0/GOWpDgKikbg= X-Received: by 127.0.0.2 with SMTP id WbBSYY1788612xsBO2xWz3m3; Sun, 27 Aug 2023 03:57:28 -0700 X-Received: from mail-lf1-f50.google.com (mail-lf1-f50.google.com [209.85.167.50]) by mx.groups.io with SMTP id smtpd.web11.25133.1693133847525081624 for ; Sun, 27 Aug 2023 03:57:27 -0700 X-Received: by mail-lf1-f50.google.com with SMTP id 2adb3069b0e04-4ffa6e25ebbso3949161e87.0 for ; Sun, 27 Aug 2023 03:57:27 -0700 (PDT) X-Gm-Message-State: vj7gle6umXa68gx0E8HMOU3bx1787277AA= X-Google-Smtp-Source: AGHT+IFw022hwx8MZt6gFfGSWMyJJ64ZJrKY1rjxqihMEw2PpGdqnVmXGdRzsUSN4JyYQPOWxZSO4w== X-Received: by 2002:a19:651a:0:b0:500:a93d:fc78 with SMTP id z26-20020a19651a000000b00500a93dfc78mr1733571lfb.31.1693133845516; Sun, 27 Aug 2023 03:57:25 -0700 (PDT) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id i11-20020ac2522b000000b004fb9fe34c27sm1085825lfl.92.2023.08.27.03.57.24 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Sun, 27 Aug 2023 03:57:24 -0700 (PDT) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 5/5] RedfishClientPkg: fix misprints in Readme.md Date: Sun, 27 Aug 2023 13:56:40 +0300 Message-Id: <20230827105640.94731-6-mike.maslenkin@gmail.com> In-Reply-To: <20230827105640.94731-1-mike.maslenkin@gmail.com> References: <20230827105640.94731-1-mike.maslenkin@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,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1693133849000100020 Content-Type: text/plain; charset="utf-8" Signed-off-by: Mike Maslenkin --- RedfishClientPkg/Readme.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/RedfishClientPkg/Readme.md b/RedfishClientPkg/Readme.md index 18a27633cf45..0aec0580aa5c 100644 --- a/RedfishClientPkg/Readme.md +++ b/RedfishClientPkg/Readme.md @@ -40,7 +40,7 @@ Below are the block diagrams of UEFI Redfish Client EDK2 = Implementation. ![UEFI Redfish Client Implementation](https://github.com/changab/edk2-stag= ing/blob/edk2-redfish-client/RedfishClientPkg/Documents/Media/RedfishClient= DriverStack.svg?raw=3Dtrue) =20 ## EFI EDK2 Redfish Client Framework -The functionality of each block in the diagrams are described in belwo sec= tions, +The functionality of each block in the diagrams are described in below sec= tions, =20 ### EDK2 Redfish Foundation ***[[1]](#[0])*** EDK2 Redfish Redfish Foundation provides the facilities of communicating w= ith @@ -68,7 +68,7 @@ project. =20 ### EDK2 Redfish JSON Schema to C Structure Convertor ***[[3]](#[0])*** This is the script auto-generated EDK2 drivers and libraries that provide = the -Redfish schema naming based JSON to C structure and vise versa converters.= C +Redfish schema naming based JSON to C structure and vice versa converters.= C structure is another representation of Redfish properties other than JSON = and CSDL(XML). The higher layer Redfish client application can deal with C str= ucture instead of using JSON library to manipulate Redfish properties. The script @@ -85,7 +85,7 @@ sits between **JSON Schema to C Structure converters** an= d **EFI Platform Configuration to Redfish Protocol**. The Redfish feature driver gets and s= ets the platform configuration and incorporates it with Redfish JSON schema C structure to manipulate Redfish JSON resources. Then applies the settings = from -Redfish service to platform configurations, or vise versa to update platfo= rm +Redfish service to platform configurations, or vice versa to update platfo= rm configurations to Redfish service. Both EDK2 Redfish Non-Collection and Collection Feature drivers are script auto-generated base on Redfish schema naming. The EDK2 Redfish Non-Collection feature driver manages the resourc= e of --=20 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#108048): https://edk2.groups.io/g/devel/message/108048 Mute This Topic: https://groups.io/mt/100988475/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-