Bug 125838 - 3.8.1p1 breaks 'mc' with X11Forwarding
Summary: 3.8.1p1 breaks 'mc' with X11Forwarding
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: mc
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jindrich Novy
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: FC3Blocker
TreeView+ depends on / blocked
 
Reported: 2004-06-12 02:41 UTC by Enrico Scholz
Modified: 2013-07-02 23:00 UTC (History)
7 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2004-09-29 13:51:16 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Enrico Scholz 2004-06-12 02:41:07 UTC
Description of problem:

 ,---- in an xterm ---
| $ ssh -X localhost
| $ mc
| [... press a key ...]
| X Error of failed request:  BadWindow (invalid Window parameter)
| Major opcode of failed request:  38 (X_QueryPointer)
| Resource id in failed request:  0x5a
| Serial number of failed request:  7
| Current serial number in output stream:  7
| $ $ $

With '-x' instead of '-X' things are ok, and it worked before the
upgrade to 3.8.1 also.


Version-Release number of selected component (if applicable):

openssh-3.8.1p1-1
mc-4.6.0-15
xorg-x11-6.7.0-2


How reproducible:

100%

Comment 1 Leonard den Ottolander 2004-07-20 15:04:34 UTC
*** Bug 125698 has been marked as a duplicate of this bug. ***

Comment 2 Leonard den Ottolander 2004-07-20 15:11:23 UTC
According to bug 125698 this bug also affects other programs like
kuickshow and redhat-config-users, which could be expected if this is
a general openssh issue.


Comment 3 Barry K. Nathan 2004-07-26 13:13:50 UTC
What happens if you try '-Y' instead of '-X'? (This is only applicable
to FC3t1 and FC-devel, NOT FC2.)

Comment 4 Enrico Scholz 2004-07-26 20:04:23 UTC
Things seem to be fine when using '-Y' (no crashes anymore).

Comment 5 Ivo Sarak 2004-07-26 20:49:22 UTC
I have never used -X nor -Y options of SSH and all has worked just
fine, until now.
What parameters is SSH using if to use plain "ssh host"?


Comment 6 dann 2004-07-26 21:49:14 UTC
If you connect to a remote system running openssh-3.8p1, run emacs in
X11 mode and try to select some text with the mouse => emacs will
crash, always. 


This can be fixed by adding to ~/.ssh/config (or /etc/ssh/ssh_config)

ForwardX11Trusted yes

See http://www.openssh.com/faq.html#3.13

Comment 7 Barry K. Nathan 2004-07-26 23:16:47 UTC
A few comments:

If bug 125698 happens with Fedora Core 2, then it is *not* a dupe of
this bug.

This bug is filed against openssh, but strictly speaking, it's
probably not an OpenSSH bug. IIRC there are changes planned for a
later FC 3 test release which will add an SELinux-like security
infrastructure to xorg-x11, thereby fixing this bug. (I'll find the
relevant mailing list post later -- hopefully later today -- and I'll
add a comment here with the URL for that message.)

Comment 8 Håkon Løvdal 2004-08-03 23:57:37 UTC
I can confirm that this behaviour is present on Fedora Core 2.

If I open up a ssh connecting from cygwin/windows on one pc towards
my linux machine using the "-X" option to ssh then mc craches when
pressing Ctrl-W and synaptic synaptics crashes when trying to select
a menu. If running ssh with "-Y" then the programs work without problems.

On linux:
    mc-4.6.0-15
    openssh-3.6.1p2-34
    xorg-x11-6.7.0-5
    synaptic-0.48.2-2.1.fc2.dag

On cygwin:
    OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004

Comment 9 Barry K. Nathan 2004-08-04 09:24:35 UTC
Oh, wait... if bug 125698 happens with FC2 as the *server*, and
OpenSSH 3.8.1p1 on some other machine as the *client*, then it may be
a dupe of this bug, maybe.

In any case, the last paragraph of (my) comment #7 to this bug still
stands (this is a longstanding problem with the X security extension,
and/or X widget libraries which blindly assume the extension does not
exist -- hopefully a future FC 3 test release will fix this).

Comment 10 Don Hardaway 2004-08-18 15:15:00 UTC
I am trying to make a remote connection to my racked server to install
Oracle. Oracle only uses a gui installer so i need X to work remotely
from my laptop at home running through a router and cable service. I
have done everything mentioned in the bug report and i am using the
latest devel packages for both the server and my laptop but when no
success. I am able to launch the installer on the server but when i
try to click the buttoned presented on the installer screen they do
not click. Any ideas?

Comment 11 Owen Taylor 2004-09-07 14:46:52 UTC
Most of the X applications in our distribution are not going to
work OK with X security restrictions on.

We could probably make things a lot better with a few small patches
to GTK+, but 

 - Many applications will still have random X error crashes.

 - Things that the user expects to work (e.g. cut-and-paste,
   drag-and-drop) are likely not going to work.

 - It will take quite a while for these fixes to propagate
   to machines being ssh-ed onto.

If we ship with X forwarding on by default, we should ship with
it with the effect of -Y not -X. Subjecting users to crashes with 
the default configuration doesn't make sense to me.


Comment 12 Nalin Dahyabhai 2004-09-15 16:10:04 UTC
As noted in comments 6 and 8, X11 forwarding in OpenSSH 3.8 and later
no longer defaults to using a trusted key for forwarded connections
(see http://www.openssh.com/faq.html#3.13 for details).  To forward
X11 using a trusted key, you must now use the -Y flag.

Packages of 3.8.1p1-1 and later no longer modify the upstream defaults
to request X11 forwarding by default (the server still permits it, but
the client must specifically request it), so "ssh" must be invoked
with either -X or -Y in order to forward X11 connections over the SSH
connection.

Comment 13 Warren Togami 2004-09-15 23:05:58 UTC
Perhaps mc could output a better error message in this failure case,
but otherwise this is not really a bug in openssh nor mc.  Will let
the mc maintainer decide if he wants to output a better error message,
or NOTABUG.

Comment 14 Nalin Dahyabhai 2004-09-15 23:55:06 UTC
Using either -x or -Y will work, just not -X.  The -x flag explicitly
disables X11 forwarding, causing the DISPLAY variable to be unset.  In
this case, mc doesn't attempt to be mouse-aware.  With the -Y flag, mc
attempts to be mouse-aware, as before, but it doesn't run into any of
the problems which an untrusted client would run into.

Comment 15 Jindrich Novy 2004-09-29 13:51:16 UTC
Enrico,

the message displayed is caused by _XDefaultError() func in
/lib/X11/XlibInt.c in xorg. The workaround could be adding a new error
handler in a similar way like Leonard did to make mc displaying
something nicer than is seen from the screenshot you attached to bug
125698. Even with installed packages you've noticed I had problems to
reproduce the problem. For now I'll close this as NOTABUG and will be
watching 125698.

Jindrich



Note You need to log in before you can comment on or make changes to this bug.