Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] Firefox with gksudo
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
GOS
Tux's lil' helper
Tux's lil' helper


Joined: 09 Sep 2010
Posts: 93
Location: Germany

PostPosted: Fri Aug 21, 2015 9:38 am    Post subject: [solved] Firefox with gksudo Reply with quote

Hello everyone,

I hope that I am posting in the right subforum.

I want to start firefox by my regular user "abc" via another user "inet". This is because for security resasons "abc" has no access to the internet at all. Thereby firefox should use the home-directory of "inet" to store ".mozilla". "inet" has the home-direcorty "/home/inet" and is member of the groups "inet" "video" and "audio". (Are "video" and "audio" necessary?)

I installed "sudo" and "gksudo" and added the following lines to "/etc/sudoers" (in fact they are the only lines therein):

Code:
Defaults:%wheel   !env_reset
abc  mypc=(inet) NOPASSWD:/usr/bin/firefox


If i run now from "abc" the command "sudo -u inet firefox" i get

Code:
(process:9504): GLib-CRITICAL **: g_slice_set_config: assertion 'sys_page_size == 0' failed
No protocol specified
Error: cannot open display: :0.0


If i run now from "abc" the command "gksudo -u inet firefox" nothing happens at all

What I am doing wrong? Any ideas?

Best regards
GOS


Last edited by GOS on Fri Aug 21, 2015 12:29 pm; edited 1 time in total
Back to top
View user's profile Send private message
EmaRsk
Apprentice
Apprentice


Joined: 07 Sep 2004
Posts: 158
Location: Italy

PostPosted: Fri Aug 21, 2015 11:05 am    Post subject: Reply with quote

Try this command before starting firefox:
Code:
xhost +local:

It gives to the other local users the permission to connect to the current X session (or something like that, I'm not sure I'm using the correct terminology).

You can put it in .xinitrc or whatever you use to start X.
_________________
Please, avoid some common spelling errors:
http://theoatmeal.com/comics/misspelling
Back to top
View user's profile Send private message
GOS
Tux's lil' helper
Tux's lil' helper


Joined: 09 Sep 2010
Posts: 93
Location: Germany

PostPosted: Fri Aug 21, 2015 12:29 pm    Post subject: Reply with quote

Thanks a lot. That was what i needed.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum