From owner-freebsd-questions Sun Sep 1 10:14:46 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F07BF37B400 for ; Sun, 1 Sep 2002 10:14:43 -0700 (PDT) Received: from mta6.snfc21.pbi.net (mta6.snfc21.pbi.net [206.13.28.240]) by mx1.FreeBSD.org (Postfix) with ESMTP id ABE1643E4A for ; Sun, 1 Sep 2002 10:14:43 -0700 (PDT) (envelope-from mbsd@pacbell.net) Received: from atlas ([64.160.45.6]) by mta6.snfc21.pbi.net (iPlanet Messaging Server 5.1 (built May 7 2001)) with ESMTP id <0H1R00COERWJF9@mta6.snfc21.pbi.net> for freebsd-questions@FreeBSD.ORG; Sun, 01 Sep 2002 10:14:43 -0700 (PDT) Date: Sun, 01 Sep 2002 10:14:47 -0700 (PDT) From: "M.T." Subject: Re: how to autostart ssh-add? In-reply-to: <20020901182801.5593f2ef.freebsd@secspace.de> X-X-Sender: mikko@atlas.home To: Volker Kindermann Cc: freebsd-questions@FreeBSD.ORG Message-id: <20020901100848.A69871-100000@atlas.home> MIME-version: 1.0 Content-type: TEXT/PLAIN; charset=US-ASCII Content-transfer-encoding: 7BIT Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 1 Sep 2002, Volker Kindermann wrote: > Hi, > > I'm running FreeBSD stable on my notebook. I use the X-Environment and > log in graphically with xdm. I connect very often to remote machines > with ssh, so I decided to use publickey authentication > and ssh-agent/ssh-add (my private keys are protected with passphrases). > > My .xsession looks like: > > [vkinderm@argus vkinderm]$ cat .xsession > exec /usr/bin/ssh-agent /usr/X11R6/bin/fluxbox > > After logging in, I start a xterm and run ssh-add to add my keys to the > agent. > > Now I'm looking for a way to have ssh-add automatically started after > login. OpenBSD does it. I've already copied all of the OpenBSD > xdm-files to my FreeBSD box but no success. First install the openssh-askpass port. Then select a way to fire up ssh-add during login. If you can't convince your window manager to do it for you, you can for example change your .xsession to: #!/bin/sh eval `/usr/bin/ssh-agent` trap '/usr/bin/ssh-agent -k' 0 1 2 3 15 /usr/bin/ssh-add .ssh/id_rsa & /usr/X11R6/bin/fluxbox $.02, /Mikko To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message