util: Add inotify_rm_watch to syscall sandbox (AllowFileSystem) #24690

pull hebasto wants to merge 1 commits into bitcoin:master from hebasto:220328-sys changing 1 files +1 −0
  1. hebasto commented at 7:17 am on March 28, 2022: member

    This PR fixes the current master (3297f5c11c72dd83479ff8335e047555e3f8cb3b) when running bitcoin-qt on Ubuntu 22.04 and quitting:

    0$ ./src/qt/bitcoin-qt -signet -sandbox=log-and-abort
    1Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
    2ERROR: The syscall "inotify_rm_watch" (syscall number 255) is not allowed by the syscall sandbox in thread "main". Please report.
    3terminate called without an active exception
    4Aborted (core dumped)
    

    Also see #24659 (review)

  2. util: Add inotify_rm_watch to syscall sandbox (AllowFileSystem) f05a4cdf5a
  3. hebasto commented at 7:20 am on March 28, 2022: member
    Backport into 23.x?
  4. MarcoFalke commented at 7:23 am on March 28, 2022: member

    So this only happens in the GUI, not bitcoind?

    I always wondered how to add GUI-specific syscalls to the sandbox.

  5. MarcoFalke added the label Utils/log/libs on Mar 28, 2022
  6. MarcoFalke added the label Needs backport (23.x) on Mar 28, 2022
  7. hebasto commented at 7:26 am on March 28, 2022: member

    So this only happens in the GUI, not bitcoind?

    Correct. Btw, #24536 and #24659 were GUI only as well.

  8. fanquake approved
  9. fanquake commented at 9:18 am on March 30, 2022: member
    ACK f05a4cdf5a0363e1c12f00c034afb60e7ea0c775 - checked that qt is using this in it’s filesystem watcher code.
  10. fanquake merged this on Mar 30, 2022
  11. fanquake closed this on Mar 30, 2022

  12. jonatack commented at 10:34 am on March 30, 2022: member
    Backported to v23 in #24512.
  13. fanquake removed the label Needs backport (23.x) on Mar 30, 2022
  14. jonatack referenced this in commit c5cc0e5865 on Mar 30, 2022
  15. hebasto deleted the branch on Mar 30, 2022
  16. hebasto referenced this in commit e4ed65830f on Mar 31, 2022
  17. jonatack referenced this in commit 174af33d5d on Mar 31, 2022
  18. laanwj commented at 10:14 am on March 31, 2022: member

    I always wondered how to add GUI-specific syscalls to the sandbox.

    I think ideally we’d add a separate profile for the GUI thread, so that the GUI specific syscalls (which is pretty much an open uncontainable set and pit of despair, given the tree of dependencies) don’t clutter the more contained bitcoind ones.

    Another option would be to not sandbox Qt’s threads at all. Maybe that is the best.

  19. laanwj commented at 10:17 am on March 31, 2022: member

    open uncontainable set and pit of despair

    To illustrate: Qt indirectly uses the graphics driver (at for non-statically linked builds which link against the OS). There’s no saying what it might do and might depend on the hardware.

  20. fanquake referenced this in commit c243e08351 on Mar 31, 2022
  21. sidhujag referenced this in commit 393dc49055 on Apr 3, 2022
  22. laanwj referenced this in commit c5c4fb3182 on Apr 6, 2022
  23. DrahtBot locked this on Mar 31, 2023

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-07-03 10:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me