From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f169.google.com (mail-pl1-f169.google.com [209.85.214.169]) by mx.groups.io with SMTP id smtpd.web11.2278.1617738785540540559 for ; Tue, 06 Apr 2021 12:53:05 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20161025 header.b=cEvPshlC; spf=pass (domain: gmail.com, ip: 209.85.214.169, mailfrom: kuqin12@gmail.com) Received: by mail-pl1-f169.google.com with SMTP id g10so8083933plt.8 for ; Tue, 06 Apr 2021 12:53:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=P4IN9NekuKSlD08Ie4YNu6ZtpXjmX5nU9lRyVSKkV3E=; b=cEvPshlClAtZJ/LG67V3F5biti76/5NBHjuGUoLWOHR1QwHPuGPaPlkXB0TS/X1HMs bOnHOxrZ7g/+U1aPP+ZbTvBDOcumprHv7mUYlWZ6nFrsP4PSnW5JFf3RnCmMCDWm6m8t BFnEP4J9ObJw8WsVT6rzRYBCz0LLhhkQoFO9n9gTXAudzGywfp8/+Rc+q9q80cadTKRl 93ij5Nv24iom17eBgh23m5p31t0R3kKstEl953y3ZzwixQZdQwwKWyoMFFcqAjA+TzVE cYItJSPkniNZU0Y2NV5Y8buxCsTJvG4mZqK7+1SBsEAc4LASKzN1JNge0Oqz59e+roUr 5x0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=P4IN9NekuKSlD08Ie4YNu6ZtpXjmX5nU9lRyVSKkV3E=; b=EgJ4WrMzSvYvjVRO24C7D8pmTzZrfMm7x19CerLnxa/dr4FiomN6ZwgfINvqxYgGSZ fmjxa4VlJ827SVNAAN3TE4z8UZTiIdWpa9dL6tU33ICRjMYQiqqlm8qOih015s/s8e8x WQbc3e1lwbCWmwXULYt2uajJsjVfdv+ncZ6PF3kF3Sr+jqgbmWEQIFzx0KHCHyNkv6x2 DsBcEF7Ie7SDT6IDe571tOTKZUWHhIsSJMbvw645l+zWxMQZeg4+KFiPhTxwclvl7Yx5 mSgHMpk9Q7/FFYRQ0PNJQ58svghypy87zcW7rTsw4NLXKYjwn6ZJG4IWOIrZUyUYfwwL yrAQ== X-Gm-Message-State: AOAM5324mcw4oDs2S8shnegKJ8Db0KF4qInrvp+kBMv8BbjoVh8Pyrvu xK6YmflBrFnQlRgeBOghH/OITLHsL2U+6g== X-Google-Smtp-Source: ABdhPJyTR39RzTK4LIiP+phtKVtah5hFo9ZIYen+kAVSYd1PMWib7hrpW4tSXXQ7H9LHsuXS/vP7Hg== X-Received: by 2002:a17:90a:c293:: with SMTP id f19mr5758188pjt.222.1617738784670; Tue, 06 Apr 2021 12:53:04 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([50.35.88.161]) by smtp.gmail.com with ESMTPSA id 67sm20229577pfb.148.2021.04.06.12.53.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Apr 2021 12:53:04 -0700 (PDT) From: "Kun Qin" To: devel@edk2.groups.io Cc: Eric Dong , Ray Ni , Laszlo Ersek , Rahul Kumar Subject: [PATCH v1 0/1] Add buffer size check before save state read Date: Tue, 6 Apr 2021 12:52:53 -0700 Message-Id: <20210406195254.1018-1-kuqin12@gmail.com> X-Mailer: git-send-email 2.31.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3283 This change is validated on two different physical platforms. v2 mainly focus on feedback for v1 patche, including: a. Adding "Reviewed-by" tags; b. Updated return code description for modified function; Patch v2 branch: https://github.com/kuqin12/edk2/tree/svst_width_v2 Cc: Eric Dong Cc: Ray Ni Cc: Laszlo Ersek Cc: Rahul Kumar Kun Qin (1): UefiCpuPkg: PiSmmCpuDxeSmm: Check buffer size before accessing UefiCpuPkg/PiSmmCpuDxeSmm/SmramSaveState.c | 9 ++++++++- UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.h | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) -- 2.31.0.windows.1