Disable CET enforcement #409
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Since canary build 1.2.97 when the project was moved to .NET 9 (ref:
ff6628149d
), Ryujinx has been failing to launch. The cause is the "Control-flow Enforcement Technology Shadow Stack (.NET 9+)" feature introduced in .NET 9This specifically affects Windows 10, and more specifically an install of Windows 10 that is not fully up-to-date
This fix allows (Windows 10) systems that are not completely up to date as of the current .NET 9 runtime release to launch Ryujinx. Without this fix the user will receive the following output and an application crash:
Possible fixes to this issue:
User disables Control-Flow Guard exploit protection in the Exploit Protection section of the Windows Security appletrefs:
https://github.com/dotnet/runtime/issues/108589
https://github.com/dotnet/docs/issues/42600
https://learn.microsoft.com/en-us/dotnet/core/compatibility/interop/9.0/cet-support
https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/security#control-flow-enforcement-technology-shadow-stack-net-9
edit:
Disabling CFG exploit protection does not allow Ryujinx to launch with CET enforcement enabled
Download the artifacts for this pull request:
GUI-less
Only for Developers
For anyone experiencing this issue:
To allow the .NET 9 Ryujinx builds to launch under the condition you are running Windows 10 and the operating system is not fully up-to-date:
This will allow you to launch and update Ryujinx normally without an immediate crash
(CET was not available in any prior .NET core framework that Ryujinx was compiled against, why is it necessary now?)
This will not be merged. I'm not disabling a security feature because some people insist on being insecure with their OS (aka not updating it) (and no I don't mean updating to Windows 11).
I'm going to have to disagree. "Control-flow Enforcement Technology" and more specifically the "Shadow Stack" feature only became available with 11th generation Intel processors and Zen 3 AMD Ryzen processors - saying this is a security feature for Ryujinx doesn't make any sense considering 10th generation Intel processors and older or Zen 2 AMD Ryzen processors or older cannot support this feature
Ryujinx acts as a hypervisor for the applications it executes and will halt an application trying to access address space it's not permitted to access. Likewise, .NET Core acts as a hypervisor for the applications it hosts and will block access to address space that a hosted application is not allowed to access. Likewise AGAIN, Windows acts as a hypervisor for .NET Core itself and will block access to address space that .NET Core and any application it's hosting is not allowed to access
By having CET enabled in Ryujinx, this specifically blocks users running Windows 10, that is not completely up-to-date (including being on 22H2), and has a 11th generation Intel CPU or a Zen 3 AMD Ryzen CPU or newer
{\textsf{\color{Green}Yes}}
{\textsf{\color{Red}No}}
{\textsf{\color{Green}Yes}}
{\textsf{\color{Red}No}}
{\textsf{\color{Green}Yes}}
{\textsf{\color{Red}No}}
{\textsf{\color{Green}Yes}}
{\textsf{\color{Red}No}}
{\textsf{\color{Red}No}}
{\textsf{\color{Red}No}}
{\textsf{\color{Red}No}}
{\textsf{\color{Red}No}}
ref: Zen 3
ref: Intel Software Development Manual (Page 116, Table 5-2)
My argument against having CET enabled is
It not needing to be enabled before now is entirely irrelevant. The world moves on past unsafe software and hardware.
Once again, this isn't getting merged. If people want to use it they can use an insecure version, that isn't latest. We're not regressing security because of outdated systems. Just because you don't see a reason for it to be on doesn't mean it's useless.
Pull request closed