From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-002e3701.pphosted.com (mx0b-002e3701.pphosted.com [148.163.143.35]) by mx.groups.io with SMTP id smtpd.web12.5721.1663629044690918371 for ; Mon, 19 Sep 2022 16:10:45 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@hpe.com header.s=pps0720 header.b=hZnUwzfZ; spf=permerror, err=parse error for token &{10 18 %{ir}.%{v}.%{d}.spf.has.pphosted.com}: invalid domain name (domain: hpe.com, ip: 148.163.143.35, mailfrom: prvs=0261932226=brian.johnson@hpe.com) Received: from pps.filterd (m0150245.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 28JNAURC021390; Mon, 19 Sep 2022 23:10:31 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hpe.com; h=content-type : message-id : date : subject : to : cc : references : from : in-reply-to : mime-version; s=pps0720; bh=fqe71iVLGoe2UcuVlzwlf/NndCGhKZFWo1p20Cl8oLY=; b=hZnUwzfZEpDCSNedlPSN60gv5MspClPjN/v73mEuN4C9+ivaZtoQ0/C3AJIegM4b/PK9 pOCFpL2gX2C296izBYB68L623XryfEcmYkDUccc7DIjK5KDXCQ1ZiwME2c9zP199U9xN k2Ka+QGERcVt7b7vAVkt9VV/qlkkbbamwaHlj2fWKXMwJ/KHfjInCUp0IpaodPudV2uA 8GQoTEjsjdHbCAMCxmbrrSCJnE6LFPlfFatLDw5487FjAK6w3tsGtGc1hCkCy5tUJaF1 qCbn7sUGIBAqA9gTvVW/h7XHowewZeSu+HCtayXzBc0m1xcUfmy1EV5qR2PTj4JDGkPI Sw== Received: from p1lg14880.it.hpe.com (p1lg14880.it.hpe.com [16.230.97.201]) by mx0b-002e3701.pphosted.com (PPS) with ESMTPS id 3jpwc425ww-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 19 Sep 2022 23:10:30 +0000 Received: from p1wg14926.americas.hpqcorp.net (unknown [10.119.18.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by p1lg14880.it.hpe.com (Postfix) with ESMTPS id 6A1EF80171B; Mon, 19 Sep 2022 23:09:37 +0000 (UTC) Received: from p1wg14924.americas.hpqcorp.net (10.119.18.113) by p1wg14926.americas.hpqcorp.net (10.119.18.115) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.15; Mon, 19 Sep 2022 11:09:37 -1200 Received: from p1wg14921.americas.hpqcorp.net (16.230.19.124) by p1wg14924.americas.hpqcorp.net (10.119.18.113) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.15 via Frontend Transport; Mon, 19 Sep 2022 11:09:37 -1200 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (192.58.206.38) by edge.it.hpe.com (16.230.19.124) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.15; Mon, 19 Sep 2022 11:09:36 -1200 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kHawxp0nAJK4R4kuf/4Ep5et/k3D/NCGYyVf/Je9pBj6uPKxIG28mM6zhvOmSkzABPv/ulYyS24CyyaNDpLIT05QsJtcjfeC6Lj/7xIvpITazFlRzoOw2EO2Jt/AD3jSW3SecsdGWyyFvGKOZxJhDmaXv58y1OnCIJKOcAep/NgGivYYHGuVAFug+xivv19iIOPFPIevD6cKkiKxFBTHrUcWAanPxq8U13kO4+VMl5MGiUQ/3Y/cudbPNVET2fQHDLVTP9OHty3o01ltpAjQ1Wz3T8qgLflWsVSADeW7gxVZ8EEYVzlV81spLt8I9lBM3exL4UKcbd0Urwws5tEinw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=IliunMjRJJk98vdRut7dCsmqjS0CI3jyCtms3GjSohA=; b=Tv0TgtKTUyXqftOIGVmIhTaB1vSE7ZiIFallUoutXUpqaJJAJPW2VEk1VuhvHDtGCcYrEOvavrp1Yl22J8OaStRZ5sEfsBUqnDDeGwnWWfWSH2fzmBkXQoW9jOiVU+vT3neBwuPiT1GIQBge9HmJKci009VOv+2+5MppxLrYeR7H7tKXqCTiVzyYwu5wou271NANAjqIx1y1ap8mQ6xOZGb/aoX4S+GP5/VrKKaOh//pfa2oOo1Kzh7fLs/EcjEb6w3ctw4+ISCVQDg0NIPFVKoLaw4K7ZOJYRiWE3327+oBZv+dnNbnMGb3dgfguZUtNM2zQwpucKyrvqNhyQtvag== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=hpe.com; dmarc=pass action=none header.from=hpe.com; dkim=pass header.d=hpe.com; arc=none Received: from MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM (2603:10b6:303:1c0::21) by MW4PR84MB1659.NAMPRD84.PROD.OUTLOOK.COM (2603:10b6:303:1a6::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5632.15; Mon, 19 Sep 2022 23:09:35 +0000 Received: from MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM ([fe80::c057:5a77:540f:1cf4]) by MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM ([fe80::c057:5a77:540f:1cf4%5]) with mapi id 15.20.5632.019; Mon, 19 Sep 2022 23:09:35 +0000 Message-ID: Date: Mon, 19 Sep 2022 18:09:30 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [edk2-devel] How to guard CAR's stack overflow To: , , "tigerliu@zhaoxin.com" CC: "Fan, Jeff" References: From: "Brian J. Johnson" Organization: HPE In-Reply-To: X-ClientProxiedBy: DM6PR12CA0006.namprd12.prod.outlook.com (2603:10b6:5:1c0::19) To MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM (2603:10b6:303:1c0::21) X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MW5PR84MB1354:EE_|MW4PR84MB1659:EE_ X-MS-Office365-Filtering-Correlation-Id: cbde01be-f8e2-4e2a-46c8-08da9a9404b7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: mV8yz5KjtGTRakdD2TG2A0W0qNnILrwMgyz6fshr8LaZ6ZR1ZCPQoCXQcKYkY++/osVJMpIddjfVKwglUfos964F24JyFgk/Iuq4fdg68dvRKcM9CLCwJxcaRdC+FzamtMYp84QGxdh4QJ8QNOwweNn/aWMIjOn6SbycPZUTCB/ap/gdiHHaJaE91/2qm9iLhBHj4lGcVTKB2+fB3+GBIAWD0/c2D8SpRQTAI50+QgarWM5f/9rzvyguPnIQCyd8u5be+vQCPU6qtAMQSzXPmdGZmE45P1j3uO6gaUPtUg//B1fpTzQ2c7qhWyUPx1/TXqI8ZY9nj2yCg8AaScHfj5qXRCCtXRva6zloBUzjM36fESrKcx9qx9ks8jeVVbI7lMe07lM7z8AH0siNqn5cXqcnxATp33siNF00X7XyI4vLzauOLxes4Rhvl58VaFwO6oG+nWTRUHdIfZjOka0rKoLwYn/1KAqnNMXmdb3yKyIT+iF7eaPlidGxPXjIDsWFwJRp8WtPgvxwbpDhiVPvjrb8OXJAZKiJT6baSBu6qRQR4pzcQmPXYYQ5QDpow0ra1jiNGWsMtBgjmB407YuwzdG0xE05Bu8nScv28kW546tKkjMsQwb78S3HU1UfHWQzJvnC27AKGN6PCAar8M9qk38V2Oi1HBOQCRHq/6oGfGjauMbxFa6pEAFXeNfzIRmDFdJTwjCk2YUylbz1WEhGfWeU4yg33w+ebEw88ZLmQ5qS13D8TikcwHUNXFk3Ijvx6vj+tIbcGsYcCQCNBDUNS2fd2hC0goBcaZuLxmUoyVgR3elyDTSfM31c9dLp7n+4rxuzZwJ8JSbvS0+tig/v0CzmisCuPdSFfbIJkD6UBIjh8Yvtcnf9hhKRtIE8kCyy X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(13230022)(136003)(376002)(366004)(39860400002)(346002)(396003)(451199015)(31686004)(66476007)(478600001)(36756003)(33964004)(4326008)(76236004)(36916002)(83380400001)(8936002)(31696002)(6486002)(8676002)(6506007)(66556008)(86362001)(316002)(6916009)(66946007)(53546011)(6512007)(41300700001)(6666004)(38100700002)(5660300002)(82960400001)(166002)(2906002)(186003)(2616005)(26005)(45980500001)(43740500002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?SVI3VGlGR0YvRTdSb0lPYXRuaHNVYXlQd0t2UDRMNFBJSXBTNE9JellsOXFq?= =?utf-8?B?ZGg5MFJndmcrS3d4dS9GZmdKanV6SEt1N3hHQTJHWSs5UkxVcEo5OXFSOGlt?= =?utf-8?B?NWhXYVhEVUJzS2NYaWpXMWw2aU16RElzWVplUHFQOFJTNXl5WW0raWdlSTdo?= =?utf-8?B?OTQwMTlzVTJadmVuOXdwUXpxUWJSdkxUOVI4LzhyQVE4dzQrK3Zyc0NSQnh3?= =?utf-8?B?WlhTbTN6QUk1RVlYYWhweUZ2Z29RaGljVVdiSzB0enhrSVZXeUVyVTZaN0Uw?= =?utf-8?B?THJmYWtIVzV2UjZYOFloNklKaGRkZHluTm5EWi8xaFdqRGMyVm5YNjFabUcw?= =?utf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RkJMNzNaWjg2ZVdibkZYVWRGR1cxck9jWXNLN2JFRDJN?= =?utf-8?B?alE9PQ==?= X-MS-Exchange-CrossTenant-Network-Message-Id: cbde01be-f8e2-4e2a-46c8-08da9a9404b7 X-MS-Exchange-CrossTenant-AuthSource: MW5PR84MB1354.NAMPRD84.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Sep 2022 23:09:35.2397 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 105b2061-b669-4b31-92ac-24d304d195dc X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: UP/yFTrx5SRuLW4x2j9WLzaQktcrWz4NSJiPO0RvlezRCenfWSQas19NUi396y4ZQuNbNuMghlZxkCOLBDQ48Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW4PR84MB1659 X-OriginatorOrg: hpe.com X-Proofpoint-GUID: nw65kB9rqlrqHkruRiQ1sjsfNGZzZSl2 X-Proofpoint-ORIG-GUID: nw65kB9rqlrqHkruRiQ1sjsfNGZzZSl2 X-Proofpoint-UnRewURL: 10 URL's were un-rewritten MIME-Version: 1.0 X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.528,FMLib:17.11.122.1 definitions=2022-09-19_05,2022-09-16_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 mlxlogscore=999 phishscore=0 spamscore=0 adultscore=0 mlxscore=0 malwarescore=0 clxscore=1011 lowpriorityscore=0 bulkscore=0 suspectscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2209130000 definitions=main-2209190154 Content-Type: multipart/alternative; boundary="------------hRkR8HIo1tSfGi0eVYZzRd2o" Content-Language: en-US --------------hRkR8HIo1tSfG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A0KPiA8aHR0 cHM6Ly9lZGsyLmdyb3Vwcy5pby9nL2RldmVsL21lc3NhZ2UvOTM3OTc+IA0KPiB8IHwgTXV0ZSBU aGlzIFRvcGljIA0KPiA8aHR0cHM6Ly9ncm91cHMuaW8vbXQvOTM2OTEwODgvMTc2MTgxMT4gDQo+ IHwgTmV3IFRvcGljIA0KPiA8aHR0cHM6Ly9lZGsyLmdyb3Vwcy5pby9nL2RldmVsL3Bvc3Q+DQo+ IFlvdXIgU3Vic2NyaXB0aW9uIA0KPiA8aHR0cHM6Ly9lZGsyLmdyb3Vwcy5pby9nL2RldmVsL2Vk aXRzdWIvMTc2MTgxMT4gDQo+IHwgQ29udGFjdCBHcm91cCBPd25lciA8bWFpbHRvOmRldmVsK293 bmVyQGVkazIuZ3JvdXBzLmlvPiB8IA0KPiBVbnN1YnNjcmliZSANCj4gPGh0dHBzOi8vZWRrMi5n cm91cHMuaW8vZy9kZXZlbC91bnN1Yj4gDQo+IFticmlhbi5qb2huc29uQGhwZS5jb21dDQo+DQo+ IF8NCg0K --------------hRkR8HIo1tSfGi0eVYZzRd2o Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
You could also try modifying the Ia32 segment descriptors to mark the stack segment as an "expand down" type with a limit set just below the low end of the stack area.  That should generate a stack-fault exception if the sta= ck overflows, and wouldn't require building page tables.  See sections 5.1 - 5.3 of the Intel SDM, volume 3.

Brian J. Johnson


From: Ni, Ray [mailto:ray.ni@intel.com]
Sent: Wednesday, September 14, 2022, 10:25 PM
Subject: [edk2-devel] How to guard CAR's stack overflow

=20=20=20=20=20=20

It=E2=80=99s doable.

You need to enable paging and mark the very low 4K area of the stack as not-present.

You could use the UefiCpuPkg/Library/CpuPageTableLib to help you create the 1:1 page table with the specific
4K area as not-present (if you are using x86 processors).<= /o:p>

 

Thanks,

Ray

 

From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Tiger Liu(BJ-RD)
Sent: Thursday, September 15, 2022 8:50 AM
To: devel@edk2.groups.io
Subject: [edk2-devel] How to guard CAR's stack overflow

 

Hi, Experts:

Usually, we use Cache As Ram to setup stack and heap for C language running environment before permanent memory has been initialized.

 

So, is there a method to guard this phase=E2=80=99s stack overflow?

 

Note:

I find udk has introduced a method to guard stack overflow after memory has been initialized and discovered.

 

Thanks

=  

=E4=BF=9D=E5=AF=86=E5=A3=B0=E6=98=8E=EF=BC=9A

=E6=9C=AC=E9=82=AE=E4=BB=B6=E5=90=AB=E6=9C=89=E4=BF= =9D=E5=AF=86=E6=88=96=E4=B8=93=E6=9C=89=E4=BF=A1=E6=81=AF=EF=BC=8C=E4=BB=85= =E4=BE=9B=E6=8C=87=E5=AE=9A=E6=94=B6=E4=BB=B6=E4=BA=BA=E4=BD=BF=E7=94=A8=E3= =80=82=E4=B8=A5=E7=A6=81=E5=AF=B9=E6=9C=AC=E9=82=AE=E4=BB=B6=E6=88=96=E5=85= =B6=E5=86=85=E5=AE=B9=E5=81=9A=E4=BB=BB=E4=BD=95=E6=9C=AA=E7=BB=8F=E6=8E=88= =E6=9D=83=E7=9A=84=E6=9F=A5=E9=98=85=E3=80=81=E4=BD=BF=E7=94=A8=E3=80=81=E5= =A4=8D=E5=88=B6=E6=88=96=E8=BD=AC=E5=8F=91=E3=80=82

CONFIDENTIAL NOTE:

This email contains confidential or legally privileged information and is for the sole use of its intended recipient. Any unauthorized review, use, copying or forwarding of this email or the content of this email is strictly prohibited.

_._,_._,_

Groups.io Links:

You receive all messages sent to this group.

View/Reply Online (#93797) | | Mute This Topic | New Topic
Your Subscription | Contact Group Owner | Unsubscribe [brian.johnson@hpe.com]

_

--------------hRkR8HIo1tSfGi0eVYZzRd2o--