diff options
author | Timothy Flynn <trflynn89@pm.me> | 2021-12-29 13:10:12 -0500 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-12-30 14:18:12 +0100 |
commit | 565a880ce5a14bac817c73916e91ebfa04c8b99b (patch) | |
tree | c72ea83b52dd43711c4f0fc32367165d839e77ba /Userland/Applications/Help | |
parent | 0c84957eba4ef71ac45d7b1dcf6a79146448ebd5 (diff) | |
download | serenity-565a880ce5a14bac817c73916e91ebfa04c8b99b.zip |
Userland: Link directly against LibUnicodeData where needed
This is partially a revert of commits:
10a8b6d4116c6a627a6c189154af032f69b29c21
561b67a1add82538502ef2f5733f1d86718898ad
Rather than adding the prot_exec pledge requried to use dlopen(), we can
link directly against LibUnicodeData in applications that we know need
that library.
This might make the dlopen() dance a bit unnecessary. The same purpose
might now be fulfilled with weak symbols. That can be revisted next, but
for now, this at least removes the potential security risk of apps like
the Browser having prot_exec privileges.
Diffstat (limited to 'Userland/Applications/Help')
-rw-r--r-- | Userland/Applications/Help/CMakeLists.txt | 1 | ||||
-rw-r--r-- | Userland/Applications/Help/main.cpp | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Applications/Help/CMakeLists.txt b/Userland/Applications/Help/CMakeLists.txt index 1af4a46404..dad69f3f57 100644 --- a/Userland/Applications/Help/CMakeLists.txt +++ b/Userland/Applications/Help/CMakeLists.txt @@ -14,3 +14,4 @@ set(SOURCES serenity_app(Help ICON app-help) target_link_libraries(Help LibWeb LibMarkdown LibGUI LibDesktop LibMain) +link_with_unicode_data(Help) diff --git a/Userland/Applications/Help/main.cpp b/Userland/Applications/Help/main.cpp index be5574d708..afebffbfd3 100644 --- a/Userland/Applications/Help/main.cpp +++ b/Userland/Applications/Help/main.cpp @@ -36,14 +36,13 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) { - TRY(Core::System::pledge("stdio recvfd sendfd rpath unix prot_exec")); + TRY(Core::System::pledge("stdio recvfd sendfd rpath unix")); auto app = TRY(GUI::Application::try_create(arguments)); TRY(Core::System::unveil("/res", "r")); TRY(Core::System::unveil("/usr/share/man", "r")); TRY(Core::System::unveil("/tmp/portal/launch", "rw")); TRY(Core::System::unveil("/tmp/portal/webcontent", "rw")); - TRY(Core::System::unveil("/usr/lib/libunicodedata.so.serenity", "r")); TRY(Core::System::unveil(nullptr, nullptr)); char const* start_page = nullptr; |