waycrate / swhkd

Sxhkd clone for Wayland (works on TTY and X11 too)
https://git.sr.ht/~shinyzenith/swhkd
BSD 2-Clause "Simplified" License
676 stars 47 forks source link

[refactor] Clean up privilege escalation process. #119

Closed Shinyzenith closed 2 years ago

Shinyzenith commented 2 years ago

Use root to bind to device fd's and then immediately call setresuid() and setresgid() from libc. Only then proceed to read config files etc etc.

This should fix CVE-2022-27814.