Request for allow connect: rare:dot-local-share-applications

name: rare
description: Open source alternative for Epic Games Launcher, using Legendary
snapcraft: https://github.com/Kyuyrii/Snap-Rare/blob/main/snapcraft.yaml
upstream: https://github.com/RareDevs/Rare
upstream-relation: I only made the Snap version
plugs:
  dot-local-share-applications:
    interface: personal-files
    attributes:
      write: $HOME/.local/share/applications
    request-type: installation | manual-connection
    reasoning: Rare allows you to create .desktop files that launch the games available to be played within it.

This request has been added to the queue for review by the @reviewers team.

Write access to ~/.local/share/applications allows a snap to create any desktop launcher to launch anything outside of snap confinement and hence to effectively escape snap confinement. As such this should be treated the same as a super-privileged interface request and so would likely require publisher vetting etc.

Any Snap app can escape its confinement by creating .desktop files in the Desktop folder, thanks to the home interface.

My request isn’t even for an automatic connection; it’s just so that I can publish the app, and then the user can connect the interface themselves via the terminal.

It is possible to use the Document Portal to access $SNAP_REAL_HOME/.config and $SNAP_REAL_HOME/.local instead of using the personal-files interface. Zordeer, my launcher, does this.

It’s likely possible to do the same in Rare, though I suspect it would be more complicated than it is in Zordeer.

I added the leyline-weaver script to the Snap version of Rare, revision 12.

It’s now possible to use the Document Portal to create a symlink from the $SNAP_REAL_HOME/.local/share/applications folder inside $SNAP_USER_COMMON/.local/share , allowing Rare to create and remove .desktop files.

I’ve only tested it with KDialog so far, but I hope it works with Zenity and Yad as well.

The expected outcome using this approach is that apps will be able to access folders that are hidden within $SNAP_REAL_HOME , depending less on the personal-files interface.

Demonstration: https://youtu.be/KNHqT2zT0bM?si=GT_y0EWel1Iuv9TT

Repository: