LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

Reply
 
Search this Thread
Old 10-24-2012, 03:53 PM   #1
wirawan0
Member
 
Registered: Aug 2003
Location: Virginia, USA
Distribution: Mandrake 9.1, SuSE 9.2, Ubuntu 7.04-10.04, Sabayon 5, Debian 6
Posts: 62

Rep: Reputation: 18
Angry X11 authentication issues


I've been puzzled lately with X11 way of authentication an incoming connection. I use several computers exclusively and want to be able to display stuff on the X server of one of them.

Here's my latest failure:

*) on computer A, I have a screen session running with DISPLAY set to ":0.0" (of course)

*) on computer B, I connect to computer A with ssh:

Code:
user@B:~ $ ssh -Y A
*) In this shell session (on A), I will get, e.g., DISPLAY=localhost:11.0 .

*) this gets me from B to A. Now I reconnect to the screen on A using: `screen -x' command.

*) What I want now is, under this `screen' session, to run a program on "A", but display its output on "B", like this:

Code:
user@A:~ $ DISPLAY=:0.0 xpdf stuff.pdf
Sadly I get this error:

Quote:
X11 connection rejected because of wrong authentication.
Cannot parse arguments: Cannot open display:
I thought, since the ssh connection is mine, and the user under which the screen is running on "A" is also mine, why then can't I connect to my own X session under SSH?

I tried to import all the environment variables under the ssh terminal session (before I invoked "screen -x") but it won't help either.

What's going on here? Can somebody point me in the right direction?

FYI: I run Debian 6 on "A" and Mint LMDE 2012.4 on "B".

Wirawan
 
Old 10-24-2012, 04:02 PM   #2
wirawan0
Member
 
Registered: Aug 2003
Location: Virginia, USA
Distribution: Mandrake 9.1, SuSE 9.2, Ubuntu 7.04-10.04, Sabayon 5, Debian 6
Posts: 62

Original Poster
Rep: Reputation: 18
Cool ARgh! I answered myself, again!

Here's the answer:

* copy the DISPLAY value from the ssh shell section, as before.
* in the screen session, unexport or unset XAUTHORITY (since we aren't connecting to A's X session) just before running the command (e.g. xpdf in the case above).

Then I successfully connect to B's X session.

Still, I want to get an explanation on how X connection authentication is made. Nowadays it is a complicated matter, with XAUTHORITY stuff and many more.
 
  


Reply

Tags
authentication, ssh, x11


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
X11 connection rejected because of wrong authentication. vino87 Linux - Desktop 3 06-08-2011 09:45 AM
[SOLVED] X11 issues: fonts, x11-common mike11 Linux - Newbie 2 12-28-2010 09:34 PM
X11 connection rejected because of wrong authentication???????? Taylrl Linux - Newbie 4 12-07-2010 09:51 AM
X11 connection rejected because of wrong authentication wmasry Linux - Newbie 1 10-19-2010 06:43 AM
X11 TTF Issues; OOo Font Issues Kenji Miyamoto Slackware 2 05-27-2005 06:30 PM


All times are GMT -5. The time now is 09:25 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration