[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

allowing X display from su'd environment


Yogesh Sharma wrote:
> > I am using woody + testing + some unstable:
> > in xterm/gnome-terminal usually I do (as normal user) xhost +

Matt Zimmerman écrivait :
> This disables access control in the X server.  This is, almost always, a
> very bad idea.

A better way to allow it (when you switch from normal to root user) :

  test@localhost:~$ su -
  root@localhost:~# xauth merge ~test/.Xauthority
  root@localhost:~# export DISPLAY=:0.0
  root@localhost:~# xterm	# or whatever Xwindow program you want to run

I can remember there was some 'su' feature doing it automagically somewhere
(with RedHat, Mandrake or another one)...

Cheers, J.C.
Jean Christophe ANDRÉ <jean-christophe.andre@auf.org> http://www.vn.refer.org/
Coordonnateur technique régional / Associé principal technologie projet Reflets
Agence universitaire de la Francophonie (AuF) / Bureau Asie-Pacifique (BAP)
/ Note personnelle : merci d'évitez de m'envoyer des fichiers PowerPoint ou   \
\ Word ; voir ici : http://www.fsf.org/philosophy/no-word-attachments.fr.html /

Reply to: