http://bugs.winehq.org/show_bug.cgi?id=59767 mata <sutupud@yahoo.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sutupud@yahoo.com --- Comment #19 from mata <sutupud@yahoo.com> --- xdg-open behaves differently based on which current desktop is running. For example, with KDE on arch I get: xdg-open /usr/lib/wine/x86_64-windows/winemine.exe For security reasons, launching executables is not allowed in this context. But if I force the flatpak behavior: gdbus call --session \ --dest org.freedesktop.portal.Desktop \ --object-path /org/freedesktop/portal/desktop \ --method org.freedesktop.portal.OpenURI.OpenFile \ --timeout 5 \ "" "3" {} 3< /usr/lib/wine/x86_64-windows/winemine.exe then the program is opened. The arch package basically does effectively the same as installing with, make prefix=/usr ... install so it does end up with wine.desktop in /usr/share/applications. The packages from dl.winehq.org don't, since they install to /opt/wine-devel or similar. Probably it's not the ony distribution that does that. But at least looking over at debian, according to https://packages.debian.org/trixie/all/wine/filelist the file is put into /usr/share/doc/wine/examples/wine.desktop instead. for `xdg-mime query ...` I get application/vnd.microsoft.portable-executabl, which seems to be a subclass of application/x-msdownload, which has as alias application/x-msdos-executable, so therfore wine.destop is selected. If I remove this file, I get a "choose application to open this file..." when running the dbus command. Looking through the installed .desktop files, I can find at least one other file that could also be used the same way - https://gitlab.archlinux.org/archlinux/packaging/packages/java-openjdk/-/blo... has: Exec=/usr/lib/jvm/java-26-openjdk/bin/java -jar MimeType=application/x-java-archive;application/java-archive;application/x-jar; That would also classify as runner, not as opener. But here there's also a second application that claims the same mime type, org.kde.ark.desktop, which prevents the automatic opening and causes the selection dialog to be shown. Without the org.kde.ark.desktop file, jars will be automatically executed. Lastly, the security note on xdg-mime advises to not set a runner as *default*, not against having runnes present in the first place. It's also prominently placed on the `xdg-mime default ...` sub-command. So it could be argued that since it can't be known if something is a runner or opener, choosing any application as default without it actually being explicitly set as default goes against that advice. But it's the portal which is doing that. "the default handler is an opener, not a runner" sounds strange in that context. Maybe it *should be* an opener, but there is no telling whether it is or not. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.