I'm in the process of configuring a new laptop for myself at work which sadly needs to run win11. Windows 11 has a native sudo command now it turns out. Now I had been running gsudo on my old laptop for a few years, found out they got in a little drama with Microsoft over this sudo stuff.
https://gerardog.github.io/gsudo/docs/gsudo-vs-sudo
Microsoft initially declined to create a similar tool, citing security concerns. However gsudo's documentation challenged this view arguing that absolute security is unattainable without altering Windows itself, and that the default same-desktop UAC is not completely secure either.
In February 2024, Microsoft reversed its stance and released Sudo for Windows.
Surprisingly, Microsoft's sudo does not leverage new OS features to enhance security. Its mechanisms are akin to gsudo, making their security models comparable. The question of which one is more secure depends on which version of each are you comparing, and how many open bugs it has. The initial release of Microsoft's sudo presented some critical issues that they will hopefully address very soon. gsudo has fixed similar issues in the past and may in the future.
I stuck with gsudo.