Skip to content

Commit

Permalink
Merge pull request beeware#2075 from freakboy3742/flatpak-default-per…
Browse files Browse the repository at this point in the history
…missions

Remove D-Bus session access as a default Flatpak permission.
  • Loading branch information
mhsmith authored Dec 5, 2024
2 parents 98b3cb0 + ba428de commit edb35d4
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 5 deletions.
1 change: 1 addition & 0 deletions changes/2074.removal.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Flatpak apps no longer request D-Bus session access by default. Most apps have no need to access the D-Bus session, unless they're a development tool that is inspecting D-Bus messages at runtime. If you experience errors related to this change, it is likely caused by an inconsistency between the ``bundle`` definition in your app configuration, and the way the app describes its bundle ID at runtime. If you *do* require D-Bus access, adding ``finish_arg."socket=session-bus" = true`` to the Flatpak configuration for your app will restore D-Bus session access.
2 changes: 0 additions & 2 deletions src/briefcase/platforms/linux/flatpak.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,6 @@ def permissions_context(self, app: AppConfig, x_permissions: dict[str, str]):
"filesystem=xdg-config": True,
"filesystem=xdg-data": True,
"filesystem=xdg-documents": True,
# DBus access
"socket=session-bus": True,
}

finish_args.update(getattr(app, "finish_arg", {}))
Expand Down
3 changes: 0 additions & 3 deletions tests/platforms/linux/flatpak/test_create.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ def test_output_format_template_context(create_command, first_app_config):
"filesystem=xdg-config": True,
"filesystem=xdg-data": True,
"filesystem=xdg-documents": True,
"socket=session-bus": True,
}


Expand Down Expand Up @@ -89,7 +88,6 @@ def test_output_format_template_context(create_command, first_app_config):
"filesystem=xdg-config": True,
"filesystem=xdg-data": True,
"filesystem=xdg-documents": True,
"socket=session-bus": True,
"allow=bluetooth": True,
},
},
Expand Down Expand Up @@ -221,7 +219,6 @@ def test_output_format_template_context(create_command, first_app_config):
"filesystem=xdg-config": True,
"filesystem=xdg-data": True,
"filesystem=xdg-documents": True,
"socket=session-bus": True,
"allow=bluetooth": True,
},
},
Expand Down

0 comments on commit edb35d4

Please sign in to comment.