]> andersk Git - openssh.git/blame - ssh-agent.1
- (djm) Pick up LOGIN_PROGRAM from environment or PATH if not set by headers
[openssh.git] / ssh-agent.1
CommitLineData
2e73a022 1.\" $OpenBSD: ssh-agent.1,v 1.14 2000/08/19 21:34:43 markus Exp $
bf740959 2.\"
3.\" -*- nroff -*-
4.\"
5.\" ssh-agent.1
6.\"
7.\" Author: Tatu Ylonen <ylo@cs.hut.fi>
f095fcc7 8.\"
bf740959 9.\" Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
10.\" All rights reserved
11.\"
12.\" Created: Sat Apr 23 20:10:43 1995 ylo
13.\"
14.Dd September 25, 1999
15.Dt SSH-AGENT 1
16.Os
17.Sh NAME
18.Nm ssh-agent
19.Nd authentication agent
20.Sh SYNOPSIS
f54651ce 21.Nm ssh-agent
bf740959 22.Op Fl c Li | Fl s
23.Op Fl k
24.Oo
25.Ar command
26.Op Ar args ...
27.Oc
f54651ce 28.Sh DESCRIPTION
bf740959 29.Nm
2e73a022 30is a program to hold private keys used for public key authentication
31(RSA, DSA).
4fe2af09 32The idea is that
bf740959 33.Nm
34is started in the beginning of an X-session or a login session, and
35all other windows or programs are started as clients to the ssh-agent
4fe2af09 36program.
37Through use of environment variables the agent can be located
2e73a022 38and automatically used for authentication when logging in to other
bf740959 39machines using
40.Xr ssh 1 .
41.Pp
42The options are as follows:
43.Bl -tag -width Ds
44.It Fl c
45Generate C-shell commands on
46.Dv stdout .
47This is the default if
48.Ev SHELL
49looks like it's a csh style of shell.
50.It Fl s
51Generate Bourne shell commands on
52.Dv stdout .
53This is the default if
54.Ev SHELL
55does not look like it's a csh style of shell.
56.It Fl k
57Kill the current agent (given by the
58.Ev SSH_AGENT_PID
59environment variable).
60.El
61.Pp
62If a commandline is given, this is executed as a subprocess of the agent.
63When the command dies, so does the agent.
64.Pp
4fe2af09 65The agent initially does not have any private keys.
66Keys are added using
bf740959 67.Xr ssh-add 1 .
f54651ce 68When executed without arguments,
bf740959 69.Xr ssh-add 1
f54651ce 70adds the
bf740959 71.Pa $HOME/.ssh/identity
4fe2af09 72file.
f54651ce 73If the identity has a passphrase,
bf740959 74.Xr ssh-add 1
75asks for the passphrase (using a small X11 application if running
4fe2af09 76under X11, or from the terminal if running without X).
77It then sends the identity to the agent.
78Several identities can be stored in the
bf740959 79agent; the agent can automatically use any of these identities.
80.Ic ssh-add -l
81displays the identities currently held by the agent.
82.Pp
83The idea is that the agent is run in the user's local PC, laptop, or
4fe2af09 84terminal.
85Authentication data need not be stored on any other
bf740959 86machine, and authentication passphrases never go over the network.
87However, the connection to the agent is forwarded over SSH
88remote logins, and the user can thus use the privileges given by the
89identities anywhere in the network in a secure way.
90.Pp
4fe2af09 91There are two main ways to get an agent setup:
92Either you let the agent
bf740959 93start a new subcommand into which some environment variables are exported, or
94you let the agent print the needed shell commands (either
95.Xr sh 1
96or
97.Xr csh 1
98syntax can be generated) which can be evalled in the calling shell.
99Later
100.Xr ssh 1
101look at these variables and use them to establish a connection to the agent.
102.Pp
103A unix-domain socket is created
104.Pq Pa /tmp/ssh-XXXXXXXX/agent.<pid> ,
105and the name of this socket is stored in the
106.Ev SSH_AUTH_SOCK
107environment
4fe2af09 108variable.
109The socket is made accessible only to the current user.
bf740959 110This method is easily abused by root or another instance of the same
111user.
112.Pp
113The
114.Ev SSH_AGENT_PID
115environment variable holds the agent's PID.
116.Pp
117The agent exits automatically when the command given on the command
118line terminates.
119.Sh FILES
120.Bl -tag -width Ds
121.It Pa $HOME/.ssh/identity
4fe2af09 122Contains the RSA authentication identity of the user.
123This file should not be readable by anyone but the user.
124It is possible to
bf740959 125specify a passphrase when generating the key; that passphrase will be
4fe2af09 126used to encrypt the private part of this file.
127This file is not used by
bf740959 128.Nm
129but is normally added to the agent using
130.Xr ssh-add 1
131at login time.
2e73a022 132.It Pa $HOME/.ssh/id_dsa
133Contains the DSA authentication identity of the user.
134.Pq Pa /tmp/ssh-XXXXXXXX/agent.<pid> ,
bf740959 135Unix-domain sockets used to contain the connection to the
4fe2af09 136authentication agent.
137These sockets should only be readable by the owner.
138The sockets should get automatically removed when the agent exits.
089fbbd2 139.El
bf740959 140.Sh AUTHOR
141Tatu Ylonen <ylo@cs.hut.fi>
142.Pp
143OpenSSH
144is a derivative of the original (free) ssh 1.2.12 release, but with bugs
4fe2af09 145removed and newer features re-added.
146Rapidly after the 1.2.12 release,
147newer versions bore successively more restrictive licenses.
148This version of OpenSSH
bf740959 149.Bl -bullet
150.It
371ecff9 151has all components of a restrictive nature (i.e., patents)
bf740959 152directly removed from the source code; any licensed or patented components
153are chosen from
154external libraries.
155.It
156has been updated to support ssh protocol 1.5.
157.It
f54651ce 158contains added support for
bf740959 159.Xr kerberos 8
160authentication and ticket passing.
161.It
162supports one-time password authentication with
163.Xr skey 1 .
164.El
165.Pp
bf740959 166.Sh SEE ALSO
167.Xr ssh 1 ,
168.Xr ssh-add 1 ,
169.Xr ssh-keygen 1 ,
170.Xr sshd 8 ,
This page took 0.114177 seconds and 5 git commands to generate.