X-Spam-Check-By: sourceware.org
Date: Mon, 9 Jan 2006 20:17:24 -0500 (EST)
From: Igor Peshansky <pechtcha@cs.nyu.edu>
Reply-To: cygwin@cygwin.com
To: Brett Serkez <techie@serkez.net>
cc: cygwin@cygwin.com
Subject: Re: ZoneAlarm Suite popen hang
In-Reply-To: <1136853906.20233.251462872@webmail.messagingengine.com>
Message-ID: <Pine.GSO.4.63.0601092014460.29429@slinky.cs.nyu.edu>
References: <1136853906.20233.251462872@webmail.messagingengine.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On Mon, 9 Jan 2006, Brett Serkez wrote:

> [snip]
> Using -vvv I see the hang is occuring when ssh executes the
> following command:
>
> sh -c /usr/X11R6/bin/xauth -f /tmp/ssh-OrQEQQHWXE/xauthfile generate 7..0.1:0.0 MIT-MAGIC-COOKIE-1 untrusted timeout 1200 2 > /dev/null
>   /usr/X11R6/bin/xauth:  creating new authority file
>   /home/brett/.Xauthority
>
> Running this command by hand, it looks like it is hanging, but actually
> it is waiting for the command 'exit' on stdin.  Typing exit confirms
> this with a return to the parent shell prompt.
>
> This becomes more obvious when the stderr redirection is removed:
>
> sh -c /usr/X11R6/bin/xauth -f /tmp/ssh-OrQEQQHWXE/xauthfile generate 8..0.1:0.0 MIT-MAGIC-COOKIE-1 untrusted timeout 1200
>   /usr/X11R6/bin/xauth:  creating new authority file
>   /home/brett/.Xauthority Using authority file /home/bserkez/.Xauthority
> xauth>
>
> It looks to me on the surface as if ZoneAlarm is interfering with the
> communication between ssh and xauth via the popen().  This isn't
> completely dissimilar to pipe issues that have been discussed in other
> areas, such as with rsync.
>
> I'm not sure what the next step would be, looking for ideas.

It could also be that the script is assuming that ssh will close stdin.
Try adding a redirection of stdin from /dev/null as well (i.e., use

sh -c /usr/X11R6/bin/xauth -f /tmp/ssh-OrQEQQHWXE/xauthfile generate 7..0.1:0.0 MIT-MAGIC-COOKIE-1 untrusted timeout 1200 2 > /dev/null < /dev/null

) and see if it helps.  If it does, the script is actually buggy, and
needs to be fixed.
HTH,
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

