Site icon LinuxAndUbuntu

Snap Application Permissions

Snap Application Permissions

Snap Application Permissions

We have already written about snaps and its advantages against other packaging application system. If we compare RPM and DEB packages to snaps we can see on snaps automatic background updates allowing up-to-date applications, with bugs fixes more frequently.

A snap app is packaged with all dependencies making the application very big in comparison with other packages. We can add to snap disadvantages the old-style cursor on some applications and configuration or data loss on eclipse – Snapcrafters version (Note that this is not an official release from eclipse.org, if you want an official release, grab it here. But this doesn’t mean that snaps are all disadvantages, below you can see some advantages:

How to access home folder if my app has only access to it on snap home folder?

snaps have plugs that allow the certain functionality of applications this plugs can be called Permissions and interfaces. These Interfaces are declared in the yaml file when the snap applications are being generated. Some plugs are connected by default, two examples are the plug to connect to home folder and the plug to connect to the network.

There are also some permissions of plugs that have to be connected manually by the users, as an example we have a plug for removable media and printing services or cups-control.

There are times where applications needs auto-connection for plugs that don’t allow auto-connection, on this cases is where snap reviewers come in.

​Manual connection on this type of applications can reduce performance or functionality, snap reviewers analyze if the application really needs to have that special plugs auto-connected and through a  voting method the application can have plugs automatically connected.

Connected interfaces can be viewed through Software Store or through command line allowing a user with permissions to connect or remove plugs.

Below is a Gimp application –

and these are the permissions  –

Through the command line, it follows below:

$ snap interfaces gimp
Slot      plug
:home     gimp, gnome-characters, gnome-logs
-         gimp:cups-control
-         gimp:removable-media
-    (...)

The code and image above show that printing and removable media doesn’t have any permissions. To change permission the user needs to allow as a superuser to change the interfaces statutes.

Conclusion

snap applications have come to make our life much easier, we now can install applications with just one click and forget about updates. No PPAs added, don’t have to control if an app has a new version that you missed. Have you used a snap application? Give it a try and leave your thoughts below

SOURCE: https://blog.ubuntu.com/2018/11/01/a-guide-to-snap-permissions-and-interfaces

Exit mobile version