[GH-ISSUE #4175] Discord Canary profile doesn't work FireJail using its own profile #2564

Closed
opened 2026-05-05 09:14:16 -06:00 by gitea-mirror · 3 comments
Owner

Originally created by @yusi1 on GitHub (Apr 10, 2021).
Original GitHub issue: https://github.com/netblue30/firejail/issues/4175

Bug and expected behavior
Today I installed Discord-Canary edition and it launched with the profile "electron", but it did not launch with it's own profile "discord-canary". When it launches with it's own profile it exits with: "/usr/bin/discord-canary: line 2: exec: electron: not found".

No profile and disabling firejail
Although I could of launched this application with "--noprofile", I wanted to sandbox Discord anyway. It launched when I tried "--noprofile" and "--profile=electron". When Discord (non-canary) edition is launched with its own profile, it works and does not produce such error.

Reproduce
Steps to reproduce the behavior:

  1. Run in bash firejail discord-canary or 'firejail --profile=discord-canary discord-canary' or 'firejail /usr/bin/discord-canary' or 'firejail --profile=discord-canary /usr/bin/discord-canary'
  2. See error /usr/bin/discord-canary: line 2: exec: electron: not found

Environment
OS: Arch Linux x86_64
Kernel: 5.11.12-arch1-1
Firejail Version: 0.9.64.4 (everything at compile time is enabled except overlayfs and SELinux support)

Additional context
This issue does not occur with the normal Discord version and its corresponding profile. Nor does it occur when Discord-canary is launched with the profile 'electron'.

Checklist

  • [N] The profile (and redirect profile if exists) hasn't already been fixed upstream.
  • [Y] The program has a profile. (If not, request one in https://github.com/netblue30/firejail/issues/1139)
  • [Y] I have performed a short search for similar issues (to avoid opening a duplicate).
  • [Not an AppImage, but has been tried anyway] If it is a AppImage, --profile=PROFILENAME is used to set the right profile.
  • [Y (UK)] Used LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 PROGRAM to get english error-messages.
  • [Y] I'm aware of browser-allow-drm yes/browser-disable-u2f no in firejail.config to allow DRM/U2F in browsers.
  • [Y] This is not a question. Questions should be asked in https://github.com/netblue30/firejail/discussions.
debug output
https://pastebin.com/P5W6Lb6J
Originally created by @yusi1 on GitHub (Apr 10, 2021). Original GitHub issue: https://github.com/netblue30/firejail/issues/4175 **Bug and expected behavior** Today I installed Discord-Canary edition and it launched with the profile "electron", but it did not launch with it's own profile "discord-canary". When it launches with it's own profile it exits with: "/usr/bin/discord-canary: line 2: exec: electron: not found". **No profile and disabling firejail** Although I could of launched this application with "--noprofile", I wanted to sandbox Discord anyway. It launched when I tried "--noprofile" and "--profile=electron". When Discord (non-canary) edition is launched with its own profile, it works and does not produce such error. **Reproduce** Steps to reproduce the behavior: 1. Run in bash `firejail discord-canary` or 'firejail --profile=discord-canary discord-canary' or 'firejail /usr/bin/discord-canary' or 'firejail --profile=discord-canary /usr/bin/discord-canary' 2. See error `/usr/bin/discord-canary: line 2: exec: electron: not found` **Environment** OS: Arch Linux x86_64 Kernel: 5.11.12-arch1-1 Firejail Version: 0.9.64.4 (everything at compile time is enabled except overlayfs and SELinux support) **Additional context** This issue does not occur with the normal Discord version and its corresponding profile. Nor does it occur when Discord-canary is launched with the profile 'electron'. **Checklist** - [N] The profile (and redirect profile if exists) hasn't already been fixed [upstream](https://github.com/netblue30/firejail/tree/master/etc). - [Y] The program has a profile. (If not, request one in `https://github.com/netblue30/firejail/issues/1139`) - [Y] I have performed a short search for similar issues (to avoid opening a duplicate). - [Not an AppImage, but has been tried anyway] If it is a AppImage, `--profile=PROFILENAME` is used to set the right profile. - [Y (UK)] Used `LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 PROGRAM` to get english error-messages. - [Y] I'm aware of `browser-allow-drm yes`/`browser-disable-u2f no` in `firejail.config` to allow DRM/U2F in browsers. - [Y] This is not a question. Questions should be asked in https://github.com/netblue30/firejail/discussions. <details><summary> debug output </summary> ``` https://pastebin.com/P5W6Lb6J ``` </details>
Author
Owner

@rusty-snake commented on GitHub (Apr 10, 2021):

Does it work with this discord-canary.local?

private-bin electron,electron[0-9],electron[0-9][0-9]
<!-- gh-comment-id:817115892 --> @rusty-snake commented on GitHub (Apr 10, 2021): Does it work with this discord-canary.local? ``` private-bin electron,electron[0-9],electron[0-9][0-9] ```
Author
Owner

@yusi1 commented on GitHub (Apr 10, 2021):

Does it work with this discord-canary.local?

private-bin electron,electron[0-9],electron[0-9][0-9]

Yes! this worked, thanks a lot!

<!-- gh-comment-id:817116835 --> @yusi1 commented on GitHub (Apr 10, 2021): > Does it work with this discord-canary.local? > > ``` > private-bin electron,electron[0-9],electron[0-9][0-9] > ``` Yes! this worked, thanks a lot!
Author
Owner

@rusty-snake commented on GitHub (Apr 10, 2021):

These extra electron binaries seem to be an Arch thing, we should check if there are more then the current 2 + discord-canary.

$ grep "electron\[0-9\]" /etc/firejail/*
/etc/firejail/jitsi-meet-desktop.profile:private-bin bash,electron,electron[0-9],electron[0-9][0-9],jitsi-meet-desktop,sh
/etc/firejail/wire-desktop.profile:private-bin bash,electron,electron[0-9],electron[0-9][0-9],env,sh,wire-desktop
<!-- gh-comment-id:817117864 --> @rusty-snake commented on GitHub (Apr 10, 2021): These extra electron binaries seem to be an Arch thing, we should check if there are more then the current 2 + discord-canary. ``` $ grep "electron\[0-9\]" /etc/firejail/* /etc/firejail/jitsi-meet-desktop.profile:private-bin bash,electron,electron[0-9],electron[0-9][0-9],jitsi-meet-desktop,sh /etc/firejail/wire-desktop.profile:private-bin bash,electron,electron[0-9],electron[0-9][0-9],env,sh,wire-desktop ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#2564
No description provided.