Skip to content

Commit

Permalink
fix: use --password-store=basic when launching Signal
Browse files Browse the repository at this point in the history
See #300
An upstream Chrome issue blocks the correct inovation of libsecret from within
snap/flatpak environments, which means that Signal loses access to the encryption
key used to encrypt the local database, and needs to be re-linked (losing all message
history) every time it's launched.
  • Loading branch information
jnsgruk committed Oct 1, 2024
1 parent 93a8eef commit 0f68810
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions snap/local/usr/bin/signal-desktop-wrapper
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,21 @@ set -euo pipefail
tray_icon="$(snapctl get tray-icon)"

# Define an array of command line options
opts=()
opts=(
# Don't run the chrome sandbox inside the snap environment, rely on AppArmor confinement
"--no-sandbox"
# See https://github.com/snapcrafters/signal-desktop/issues/300
# An upstream Chrome issue blocks the correct inovation of libsecret from within
# snap/flatpak environments, which means that Signal loses access to the encryption
# key used to encrypt the local database, and needs to be re-linked (losing all message
# history) every time it's launched.
"--password-store="basic"
)
# If the the tray icon is enabled, add to the list of command line args
if [[ "${tray_icon}" == "true" ]]; then
opts+=("--use-tray-icon")
fi
# Run signal-desktop with the gathered arguments
exec "${SNAP}/opt/Signal/signal-desktop" "--no-sandbox" "${opts[@]}" "$@"
exec "${SNAP}/opt/Signal/signal-desktop" "${opts[@]}" "$@"

0 comments on commit 0f68810

Please sign in to comment.