Skip to content

Commit e241b47

Browse files
supercomputer7awesomekling
authored andcommitted
Userland: Remove a bunch of unveil calls on /sys/kernel/processes
These are not needed anymore since the introduction of the new get_root_session_id syscall.
1 parent 16b6e64 commit e241b47

File tree

25 files changed

+0
-25
lines changed

25 files changed

+0
-25
lines changed

Userland/Applets/Audio/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
237237
Config::pledge_domain("AudioApplet");
238238
TRY(Core::System::unveil("/tmp/session/%sid/portal/audio", "rw"));
239239
TRY(Core::System::unveil("/res", "r"));
240-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
241240
TRY(Core::System::unveil(nullptr, nullptr));
242241

243242
auto window = TRY(GUI::Window::try_create());

Userland/Applications/3DFileViewer/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
370370

371371
TRY(Core::System::pledge("stdio thread recvfd sendfd rpath unix prot_exec"));
372372

373-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
374373
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
375374
TRY(Core::System::unveil("/home/anon/Documents/3D Models", "r"));
376375
TRY(Core::System::unveil("/res", "r"));

Userland/Applications/Browser/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
8888
if (!Browser::g_webdriver_content_ipc_path.is_empty())
8989
specified_urls.empend("about:blank");
9090

91-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
9291
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
9392
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
9493
TRY(Core::System::unveil("/tmp/session/%sid/portal/image", "rw"));

Userland/Applications/Help/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
2323
TRY(Core::System::pledge("stdio recvfd sendfd rpath unix"));
2424
auto app = TRY(GUI::Application::try_create(arguments));
2525

26-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
2726
TRY(Core::System::unveil("/res", "r"));
2827
// We specifically don't want to load this path from a library, as that can be hijacked with LD_PRELOAD.
2928
TRY(Core::System::unveil("/usr/share/man", "r"));

Userland/Applications/HexEditor/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
4343
return GUI::Window::CloseRequestDecision::StayOpen;
4444
};
4545

46-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
4746
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
4847
TRY(Core::System::unveil("/res", "r"));
4948
TRY(Core::System::unveil(nullptr, nullptr));

Userland/Applications/Magnifier/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
4747
TRY(Desktop::Launcher::seal_allowlist());
4848
Config::pledge_domain("Magnifier");
4949

50-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
5150
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
5251
TRY(Core::System::unveil("/res", "r"));
5352
TRY(Core::System::unveil(nullptr, nullptr));

Userland/Applications/Mail/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
2424

2525
Config::pledge_domain("Mail");
2626

27-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
2827
TRY(Core::System::unveil("/res", "r"));
2928
TRY(Core::System::unveil("/etc", "r"));
3029
TRY(Core::System::unveil("/tmp/session/%sid/portal/webcontent", "rw"));

Userland/Applications/NetworkSettings/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ ErrorOr<int> serenity_main(Main::Arguments args)
2222

2323
TRY(Core::System::unveil("/bin/NetworkServer", "x"));
2424
TRY(Core::System::unveil("/etc/Network.ini", "rwc"));
25-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
2625
TRY(Core::System::unveil("/sys/kernel/net/adapters", "r"));
2726
TRY(Core::System::unveil("/res", "r"));
2827
TRY(Core::System::unveil("/tmp/session/%sid/portal/clipboard", "rw"));

Userland/Applications/PDFViewer/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
3434

3535
TRY(Core::System::pledge("stdio recvfd sendfd rpath unix"));
3636

37-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
3837
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));
3938
TRY(Core::System::unveil("/res", "r"));
4039
TRY(Core::System::unveil(nullptr, nullptr));

Userland/Applications/PixelPaint/main.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
3131
args_parser.add_positional_argument(image_file, "Image file to open", "path", Core::ArgsParser::Required::No);
3232
args_parser.parse(arguments);
3333

34-
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
3534
TRY(Core::System::unveil("/res", "r"));
3635
TRY(Core::System::unveil("/tmp/session/%sid/portal/clipboard", "rw"));
3736
TRY(Core::System::unveil("/tmp/session/%sid/portal/filesystemaccess", "rw"));

0 commit comments

Comments
 (0)