From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Sep 19 06:40:24 2006 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 755C316A403 for ; Tue, 19 Sep 2006 06:40:24 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3F32743D55 for ; Tue, 19 Sep 2006 06:40:23 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id k8J6eNkN061270 for ; Tue, 19 Sep 2006 06:40:23 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id k8J6eNO8061269; Tue, 19 Sep 2006 06:40:23 GMT (envelope-from gnats) Resent-Date: Tue, 19 Sep 2006 06:40:23 GMT Resent-Message-Id: <200609190640.k8J6eNO8061269@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, "Vladimir Grebenschikov" Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 228A416A403 for ; Tue, 19 Sep 2006 06:36:31 +0000 (UTC) (envelope-from vova@fbsd.ru) Received: from vbook.fbsd.ru (swsoft-mipt-nat.sw.ru [195.214.233.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9CE6943D53 for ; Tue, 19 Sep 2006 06:36:27 +0000 (GMT) (envelope-from vova@fbsd.ru) Received: from localhost.fbsd.ru ([127.0.0.1] helo=vbook.fbsd.ru) by vbook.fbsd.ru with esmtp (Exim 4.63 (FreeBSD)) (envelope-from ) id 1GPZDU-0001Oe-Et for FreeBSD-gnats-submit@freebsd.org; Tue, 19 Sep 2006 10:36:24 +0400 Message-Id: <1158647784.5189@vbook.fbsd.ru> Date: Tue, 19 Sep 2006 10:36:24 +0400 From: "Vladimir Grebenschikov" To: "FreeBSD gnats submit" X-Send-Pr-Version: gtk-send-pr 0.4.7 Cc: Subject: ports/103395: gnome-ssh-askpass interferes with gnome-screensaver X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Sep 2006 06:40:24 -0000 >Number: 103395 >Category: ports >Synopsis: gnome-ssh-askpass interferes with gnome-screensaver >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Sep 19 06:40:22 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Vladimir Grebenschikov >Release: FreeBSD 7.0-CURRENT i386 >Organization: SWsoft >Environment: System: FreeBSD 7.0-CURRENT #8: Sat Sep 2 01:16:05 MSD 2006 root@vbook.fbsd.ru:/usr/obj/usr/src/sys/VBOOK >Description: If screen-saver activated while gnome-ssh-askpass is active, after unlock I have non-functional pointer in X. Actualy pointer moves but it is impossible to click anywhere. All clicks do not work (Left, Right, Middle, Wheel, with Shift/Alt/Meta) I am not completely sure it interfere with gnome-screensaver or with Xserver screen-saver - both active. I have fresn 7-CURRENT, with fresh prorts tree. I have sliding focus (if it does matter). >How-To-Repeat: Intslall security/gnome-ssh-askpass Setup to run ssh-add on startup with SSH_ASKPASS=gnome-ssh-askpass2 You should have generated key with passphrase in you .ssh directory. (I've added it into session startup programs) Enable gnome-screensaver. Enable Xserver screensaver (just for sure), part of xorg.conf: Section "ServerFlags" Option "blank time" "10" Option "standby time" "20" Option "suspend time" "30" Option "off time" "60" EndSection Login and wait until gnome screensaver locks screen. Unlock screen, enter passphrase. Then try to click somewhere by mouse - it does not work. Focus do not changed by mouse. Any usual keyboard clicks - works. >Fix: I have no good fix, but turning off grabbing keyboard from gnome-ssh-askpass looks like help me: /usr/ports/security/gnome-ssh-askpass# cvs diff files/patch-grab-keyboard Index: files/patch-grab-keyboard =================================================================== RCS file: files/patch-grab-keyboard diff -N files/patch-grab-keyboard --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/patch-grab-keyboard 19 Sep 2006 06:06:35 -0000 @@ -0,0 +1,58 @@ +--- contrib/gnome-ssh-askpass2.c.orig Tue Sep 19 09:58:45 2006 ++++ contrib/gnome-ssh-askpass2.c Tue Sep 19 10:03:27 2006 +@@ -88,12 +88,13 @@ + { + const char *failed; + char *passphrase, *local; +- int result, grab_tries, grab_server, grab_pointer; ++ int result, grab_tries, grab_server, grab_pointer, grab_keyboard; + GtkWidget *dialog, *entry; + GdkGrabStatus status; + + grab_server = (getenv("GNOME_SSH_ASKPASS_GRAB_SERVER") != NULL); + grab_pointer = (getenv("GNOME_SSH_ASKPASS_GRAB_POINTER") != NULL); ++ grab_keyboard = (getenv("GNOME_SSH_ASKPASS_GRAB_KEYBOARD") != NULL); + grab_tries = 0; + + dialog = gtk_message_dialog_new(NULL, 0, +@@ -135,17 +136,21 @@ + } + } + } +- for(;;) { +- status = gdk_keyboard_grab((GTK_WIDGET(dialog))->window, +- FALSE, GDK_CURRENT_TIME); +- if (status == GDK_GRAB_SUCCESS) +- break; +- usleep(GRAB_WAIT * 1000); +- if (++grab_tries > GRAB_TRIES) { +- failed = "keyboard"; +- goto nograbkb; ++ ++ if (grab_keyboard) { ++ for(;;) { ++ status = gdk_keyboard_grab((GTK_WIDGET(dialog))->window, ++ FALSE, GDK_CURRENT_TIME); ++ if (status == GDK_GRAB_SUCCESS) ++ break; ++ usleep(GRAB_WAIT * 1000); ++ if (++grab_tries > GRAB_TRIES) { ++ failed = "keyboard"; ++ goto nograbkb; ++ } + } + } ++ + if (grab_server) { + gdk_x11_grab_server(); + } +@@ -157,7 +162,8 @@ + XUngrabServer(GDK_DISPLAY()); + if (grab_pointer) + gdk_pointer_ungrab(GDK_CURRENT_TIME); +- gdk_keyboard_ungrab(GDK_CURRENT_TIME); ++ if (grab_keyboard) ++ gdk_keyboard_ungrab(GDK_CURRENT_TIME); + gdk_flush(); + + /* Report passphrase if user selected OK */ # >Release-Note: >Audit-Trail: >Unformatted: