Skip to content

Commit 48e633c

Browse files
azurelinux-securityakhila-gurujuKanishk-Bansal
authored
[AutoPR- Security] Patch edk2 for CVE-2025-2295 [LOW] (#15442)
Co-authored-by: akhila-guruju <v-guakhila@microsoft.com> Co-authored-by: Kanishk Bansal <103916909+Kanishk-Bansal@users.noreply.github.com>
1 parent 669544d commit 48e633c

3 files changed

Lines changed: 65 additions & 4 deletions

File tree

SPECS-SIGNED/edk2-hvloader-signed/edk2-hvloader-signed.spec

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
Summary: Signed HvLoader.efi for %{buildarch} systems
1212
Name: edk2-hvloader-signed-%{buildarch}
1313
Version: %{GITDATE}git%{GITCOMMIT}
14-
Release: 11%{?dist}
14+
Release: 12%{?dist}
1515
License: MIT
1616
Vendor: Microsoft Corporation
1717
Distribution: Azure Linux
@@ -74,7 +74,10 @@ popd
7474
/boot/efi/HvLoader.efi
7575

7676
%changelog
77-
* Tue Dec 18 2025 Jyoti kanase <v-jykanase@microsoft.com> - 20240524git3e722403cd16-11
77+
* Tue Jan 06 2026 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 20240524git3e722403cd16-12
78+
- Bump release for consistency with edk2 spec.
79+
80+
* Thu Dec 18 2025 Jyoti kanase <v-jykanase@microsoft.com> - 20240524git3e722403cd16-11
7881
- Bump release for consistency with edk2 spec.
7982

8083
* Fri Oct 03 2025 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 20240524git3e722403cd16-10

SPECS/edk2/CVE-2025-2295.patch

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
From 4029abaa6248f603007642077ee067131bb1c050 Mon Sep 17 00:00:00 2001
2+
From: Madhavan <madavtechy@gmail.com>
3+
Date: Fri, 14 Mar 2025 14:15:13 -0400
4+
Subject: [PATCH] NetworkPkg/IScsiDxe:Fix for Remote Memory Exposure in ISCSI
5+
bz4206
6+
7+
Used SafeUint32Add to calculate and validate OutTransferLength with
8+
boundary check in IScsiOnR2TRcvd to avoid integer overflow
9+
10+
Signed-off-by: Madhavan <madavtechy@gmail.com>
11+
Signed-off-by: rpm-build <rpm-build>
12+
Upstream-reference: https://github.com/tianocore/edk2/commit/17cdc512f02a2dfd1b9e24133da56fdda099abda.patch
13+
---
14+
NetworkPkg/IScsiDxe/IScsiProto.c | 10 ++++++++--
15+
1 file changed, 8 insertions(+), 2 deletions(-)
16+
17+
diff --git a/NetworkPkg/IScsiDxe/IScsiProto.c b/NetworkPkg/IScsiDxe/IScsiProto.c
18+
index ef58764..fb48e63 100644
19+
--- a/NetworkPkg/IScsiDxe/IScsiProto.c
20+
+++ b/NetworkPkg/IScsiDxe/IScsiProto.c
21+
@@ -1,7 +1,7 @@
22+
/** @file
23+
The implementation of iSCSI protocol based on RFC3720.
24+
25+
-Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
26+
+Copyright (c) 2004 - 2025, Intel Corporation. All rights reserved.<BR>
27+
SPDX-License-Identifier: BSD-2-Clause-Patent
28+
29+
**/
30+
@@ -2682,6 +2682,7 @@ IScsiOnR2TRcvd (
31+
EFI_STATUS Status;
32+
ISCSI_XFER_CONTEXT *XferContext;
33+
UINT8 *Data;
34+
+ UINT32 TransferLength;
35+
36+
R2THdr = (ISCSI_READY_TO_TRANSFER *)NetbufGetByte (Pdu, 0, NULL);
37+
if (R2THdr == NULL) {
38+
@@ -2712,7 +2713,12 @@ IScsiOnR2TRcvd (
39+
XferContext->Offset = R2THdr->BufferOffset;
40+
XferContext->DesiredLength = R2THdr->DesiredDataTransferLength;
41+
42+
- if (((XferContext->Offset + XferContext->DesiredLength) > Packet->OutTransferLength) ||
43+
+ Status = SafeUint32Add (XferContext->Offset, XferContext->DesiredLength, &TransferLength);
44+
+ if (EFI_ERROR (Status)) {
45+
+ return EFI_PROTOCOL_ERROR;
46+
+ }
47+
+
48+
+ if ((TransferLength > Packet->OutTransferLength) ||
49+
(XferContext->DesiredLength > Tcb->Conn->Session->MaxBurstLength)
50+
)
51+
{
52+
--
53+
2.45.4
54+

SPECS/edk2/edk2.spec

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ ExclusiveArch: x86_64
5555

5656
Name: edk2
5757
Version: %{GITDATE}git%{GITCOMMIT}
58-
Release: 11%{?dist}
58+
Release: 12%{?dist}
5959
Summary: UEFI firmware for 64-bit virtual machines
6060
License: Apache-2.0 AND (BSD-2-Clause OR GPL-2.0-or-later) AND BSD-2-Clause-Patent AND BSD-3-Clause AND BSD-4-Clause AND ISC AND MIT AND LicenseRef-Fedora-Public-Domain
6161
URL: https://www.tianocore.org
@@ -141,6 +141,7 @@ Patch1004: CVE-2024-2511.patch
141141
Patch1005: CVE-2024-4603.patch
142142
Patch1006: CVE-2025-3770.patch
143143
Patch1007: CVE-2025-9230.patch
144+
Patch1008: CVE-2025-2295.patch
144145

145146
# python3-devel and libuuid-devel are required for building tools.
146147
# python3-devel is also needed for varstore template generation and
@@ -802,7 +803,10 @@ done
802803
/boot/efi/HvLoader.efi
803804

804805
%changelog
805-
* Tue Nov 19 2025 Jyoti kanase <v-jykanase@microsoft.com> - 20240524git3e722403cd16-11
806+
* Tue Jan 06 2026 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 20240524git3e722403cd16-12
807+
- Patch for CVE-2025-2295
808+
809+
* Thu Dec 18 2025 Jyoti kanase <v-jykanase@microsoft.com> - 20240524git3e722403cd16-11
806810
- Patch for CVE-2025-2296
807811

808812
* Fri Oct 03 2025 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 20240524git3e722403cd16-10

0 commit comments

Comments
 (0)