Public bug reported:

# Bug report: transmission-gtk AppArmor blocks xdg-desktop-portal
FileChooser

**Title:** transmission-gtk: missing xdg-desktop-portal FileChooser
rules block "Open File" dialog

**Where to file:**
- Launchpad (preferred): `ubuntu-bug apparmor`, or
  https://bugs.launchpad.net/ubuntu/+source/apparmor/+filebug
- Upstream: https://gitlab.com/apparmor/apparmor/-/issues
- Mailing list: [email protected]

---

The AppArmor profile for transmission (abstractions/transmission-common, shipped
in the apparmor package) is missing the xdg-desktop-portal FileChooser rules.
With the transmission-gtk profile in enforce mode, clicking File -> Open
does nothing: the file chooser window never appears.

## Environment
- Ubuntu 26.04 (development)
- apparmor 5.0.0~beta1-0ubuntu7
- transmission-gtk / transmission-common 4.1.1+dfsg-1ubuntu1.1
- xdg-desktop-portal 1.21.1+ds-1ubuntu3 (backends: -gnome, -gtk)

## Analysis
transmission 4.x uses GtkFileChooserNative, which routes the dialog through
xdg-desktop-portal (org.freedesktop.portal.FileChooser) on the session bus.
The dialog is drawn by the unconfined portal process, so no window appears when
the D-Bus call is denied.

abstractions/transmission-common already carries partial portal rules
(Properties.Get, portal.Settings.ReadAll, portal.Inhibit.CreateMonitor,
a11y.Bus.GetAddress) but NOT the FileChooser portal, so OpenFile is blocked.

The denial is NOT in dmesg; it is emitted by the session dbus-daemon and only
appears in the journal:

    dbus-daemon: apparmor="DENIED" operation="dbus_method_call"
      bus="session" path="/org/freedesktop/portal/desktop"
      interface="org.freedesktop.portal.FileChooser" member="OpenFile"
      mask="send" name="org.freedesktop.portal.Desktop"
      label="transmission-gtk"

Additional related denials during the same action:
- org.freedesktop.DBus.Properties.GetAll on the portal (only Get is allowed)
- org.freedesktop.host.portal.Registry.Register
- org.freedesktop.portal.Session.Close
- receive of org.freedesktop.portal.Request.Response signals
- org.a11y.atspi.Registry events on the accessibility bus (only 
a11y.Bus.GetAddress allowed)

## Steps to reproduce
1. Ensure the transmission-gtk profile is loaded in enforce mode.
2. Launch transmission-gtk.
3. Click File -> Open.
- Expected: the file chooser dialog appears.
- Actual: nothing happens; journal shows the DENIED entry above.

Distinct from LP #2137395 (transmission-gtk failing to own its D-Bus name, Fix
Released in apparmor 5.0.0~beta1-0ubuntu5), which added some portal integration
but did not cover the FileChooser path.

## Proposed fix — add to abstractions/transmission-common

    dbus (send)
        bus=session
        path=/org/freedesktop/portal/desktop
        interface=org.freedesktop.portal.FileChooser
        peer=(name=org.freedesktop.portal.Desktop),
    dbus (send)
        bus=session
        path=/org/freedesktop/portal/desktop
        interface=org.freedesktop.DBus.Properties
        member=GetAll
        peer=(name=org.freedesktop.portal.Desktop),
    dbus (send)
        bus=session
        path=/org/freedesktop/portal/desktop
        interface=org.freedesktop.portal.Session
        member=Close
        peer=(name=org.freedesktop.portal.Desktop),
    dbus (receive)
        bus=session
        path=/org/freedesktop/portal/desktop/request/**
        interface=org.freedesktop.portal.Request
        member=Response,

Allowing the atspi accessibility bus events would additionally silence the
remaining a11y denials.

ProblemType: Bug
DistroRelease: Ubuntu 26.04
Package: apparmor 5.0.0~beta1-0ubuntu7
ProcVersionSignature: Ubuntu 7.0.0-27.27-generic 7.0.6
Uname: Linux 7.0.0-27-generic x86_64
ApportVersion: 2.34.0-0ubuntu2
Architecture: amd64
CasperMD5CheckResult: pass
CurrentDesktop: ubuntu:GNOME
Date: Wed Jul  8 01:59:06 2026
InstallationDate: Installed on 2026-03-21 (108 days ago)
InstallationMedia: Ubuntu 25.10 "Questing Quokka" - Release amd64 (20251007)
ProcEnviron:
 LANG=ru_RU.UTF-8
 PATH=(custom, no user)
 SHELL=/bin/bash
 TERM=xterm-256color
 XDG_RUNTIME_DIR=<set>
ProcKernelCmdline: BOOT_IMAGE=/boot/vmlinuz-7.0.0-27-generic 
root=UUID=a6c9f75c-697a-4c87-bf33-5f8a50341f57 ro quiet splash 
crashkernel=2G-4G:320M,4G-32G:512M,32G-64G:1024M,64G-128G:2048M,128G-:4096M
SourcePackage: apparmor
UpgradeStatus: Upgraded to resolute on 2026-05-16 (52 days ago)

** Affects: apparmor (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug resolute wayland-session

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2160078

Title:
  transmission-gtk: missing xdg-desktop-portal FileChooser rules block
  "Open File" dialog

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apparmor/+bug/2160078/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to