[GH-ISSUE #2126] Problem with running 'wine' on different user, can't connect to X display #1443

Closed
opened 2026-05-05 08:06:23 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @antsn on GitHub (Sep 29, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2126

My system is Suse Leap 15.

I created a separate user, e.g. 'wine_jailed' to run 'wine'. Open 'Konsole' from my current login:

$su wine_jailed
$cp /etc/firejail/wine.profile ~/.config/firejail/

and edit the wine.profile, I added the following lines:

#############
blacklist /media
blacklist /mnt

noblacklist ${HOME}/.wine
whitelist ${HOME}/.wine

include /etc/firejail/whitelist-common.inc
include /etc/firejail/default.profile

then, run:
firejail wine explorer

but get errors:

No protocol specified
No protocol specified
0009:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded.
0009:err:winediag:nodrv_CreateWindow Make sure that your X server is running and that $DISPLAY is set correctly.

I tried to add:

noblacklist /tmp/.X11-unix
whitelist /tmp/.X11-unix

but not sucess.

It works if remove the lines:

noblacklist ${HOME}/.wine
whitelist ${HOME}/.wine

include /etc/firejail/whitelist-common.inc
Originally created by @antsn on GitHub (Sep 29, 2018). Original GitHub issue: https://github.com/netblue30/firejail/issues/2126 My system is Suse Leap 15. I created a separate user, e.g. 'wine_jailed' to run 'wine'. Open 'Konsole' from my current login: ``` $su wine_jailed $cp /etc/firejail/wine.profile ~/.config/firejail/ ``` and edit the `wine.profile`, I added the following lines: ``` ############# blacklist /media blacklist /mnt noblacklist ${HOME}/.wine whitelist ${HOME}/.wine include /etc/firejail/whitelist-common.inc include /etc/firejail/default.profile ``` then, run: `firejail wine explorer` but get errors: ``` No protocol specified No protocol specified 0009:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 0009:err:winediag:nodrv_CreateWindow Make sure that your X server is running and that $DISPLAY is set correctly. ``` I tried to add: ``` noblacklist /tmp/.X11-unix whitelist /tmp/.X11-unix ``` but not sucess. It works if remove the lines: ``` noblacklist ${HOME}/.wine whitelist ${HOME}/.wine include /etc/firejail/whitelist-common.inc ```
Author
Owner

@antsn commented on GitHub (Sep 29, 2018):

I found an answer, I don't know if this's the best solution, but it works:
https://unix.stackexchange.com/a/223952

<!-- gh-comment-id:425681414 --> @antsn commented on GitHub (Sep 29, 2018): I found an answer, I don't know if this's the best solution, but it works: https://unix.stackexchange.com/a/223952
Author
Owner

@Vincent43 commented on GitHub (Sep 30, 2018):

Yes, I think adding user with xhost is the right solution.

<!-- gh-comment-id:425749735 --> @Vincent43 commented on GitHub (Sep 30, 2018): Yes, I think adding user with xhost is the right solution.
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#1443
No description provided.