From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ian Eure Newsgroups: gmane.emacs.help Subject: Re: specifying identity file for scp within tramp Date: Sat, 20 Dec 2008 10:22:38 -0800 Message-ID: References: <97c43290-2786-4b18-aaa8-429005829796@s9g2000prm.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v930.3) Content-Type: text/plain; charset=UTF-8; format=flowed; delsp=yes Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1229797395 30818 80.91.229.12 (20 Dec 2008 18:23:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 20 Dec 2008 18:23:15 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: =?UTF-8?B?6ZSB5L2P5a2Q?= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Dec 20 19:24:21 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LE6Uv-0004jF-BQ for geh-help-gnu-emacs@m.gmane.org; Sat, 20 Dec 2008 19:24:21 +0100 Original-Received: from localhost ([127.0.0.1]:52132 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LE6Ti-0001KX-TZ for geh-help-gnu-emacs@m.gmane.org; Sat, 20 Dec 2008 13:23:06 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LE6TM-0001KH-5Q for help-gnu-emacs@gnu.org; Sat, 20 Dec 2008 13:22:44 -0500 Original-Received: from [199.232.76.173] (port=49125 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LE6TL-0001K6-TX for help-gnu-emacs@gnu.org; Sat, 20 Dec 2008 13:22:43 -0500 Original-Received: from mail.digg.com ([64.191.203.36]:34893) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LE6TK-00032K-Qf for help-gnu-emacs@gnu.org; Sat, 20 Dec 2008 13:22:43 -0500 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.digg.com (Postfix) with ESMTP id 32E87A8502A; Sat, 20 Dec 2008 10:22:41 -0800 (PST) X-Virus-Scanned: amavisd-new at X-Spam-Score: 0.747 Original-Received: from mail.digg.com ([127.0.0.1]) by localhost (mail.digg.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LmyxOQj2mg1f; Sat, 20 Dec 2008 10:22:40 -0800 (PST) Original-Received: from [192.168.1.199] (adsl-68-125-160-3.dsl.pltn13.pacbell.net [68.125.160.3]) by mail.digg.com (Postfix) with ESMTP id 06963A84FFD; Sat, 20 Dec 2008 10:22:38 -0800 (PST) In-Reply-To: X-Mailer: Apple Mail (2.930.3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:60878 Archived-At: On Dec 18, 2008, at 10:29 PM, =E9=94=81=E4=BD=8F=E5=AD=90 wrote: > On Dec 19, 1:38 pm, Barry Margolin wrote: >> In article >> <97c43290-2786-4b18-aaa8-429005829...@s9g2000prm.googlegroups.com>, >> >> =C3=80=C2=AF=C3=97=C2=B0=C3=97=C2=B2 wrote: >>> Can anyone tell me if it's possible to direct tramp to use a >>> particular set of ssh keys when connecting to a particular server? =20= >>> I'm >>> trying to use scp with the equivalent of the -i option, what I tried >>> below just seems to confuse tramp, is there some other way I =20 >>> should be >>> doing this? >> >>> (add-to-list 'tramp-default-method-alist >>> '("remote_server" "" "scp -i /Users/my_user/.ssh/ >>> my_key")) >> >> Why not use the IdentityFile directives in ~/.ssh/config? >> > > I'm already using a set of keys for regular ssh login, and there's a > passphrase on that set. I was trying to create a second set > specifically for tramp to use, with no passphrase and restricted > permissions on the server side. So far as I know, I can only provide a > single IdentityFile per host in ssh/config -- do you know of any other > ways to automatically distinguish the proper keys for tramp to use > with my server? > You can, like so: Host * IdentityFile =E2=80=A6 Host my.special.com IdentityFile ~/.ssh/id_dsa_special Any of the options can be put in host-specific blocks. See =20 ssh_config(5) for more. - Ian=