mirror of
https://github.com/swaywm/sway.git
synced 2024-11-23 00:11:28 +00:00
Unset LD_PRELOAD on startup (before dropping root)
LD_PRELOAD enables keyloggers to easily be made. This solution isn't perfect - really a secure system wouldn't have LD_PRELOAD at all. It was a stupid idea in the first place.
This commit is contained in:
parent
04fc10feeb
commit
10c2125040
|
@ -220,6 +220,8 @@ int main(int argc, char **argv) {
|
||||||
" --get-socketpath Gets the IPC socket path and prints it, then exits.\n"
|
" --get-socketpath Gets the IPC socket path and prints it, then exits.\n"
|
||||||
"\n";
|
"\n";
|
||||||
|
|
||||||
|
unsetenv("LD_PRELOAD"); // Security
|
||||||
|
|
||||||
int c;
|
int c;
|
||||||
while (1) {
|
while (1) {
|
||||||
int option_index = 0;
|
int option_index = 0;
|
||||||
|
|
Loading…
Reference in a new issue