resock man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

RESOCK(1)		  BSD General Commands Manual		     RESOCK(1)

NAME
     resock — connect to a usable SSH authentication agent

SYNOPSIS
     resock

DESCRIPTION
     The resock utility attempts to connect to an SSH authentication agent by
     looking for its Unix-domain socket in the /tmp/ssh-* directories.	It
     looks for agent sockets in a directory owned by the current user and out‐
     puts the name of the most recently created one in the hope that it would
     be actually active at the present time.

     The output of the resock utility is in the format suitable for direct use
     by the eval command of Bourne-like shells.	 Its main intended purpose is
     to be able to easily connect to the new SSH agent socket after reconnect‐
     ing to e.g. a screen(1) session on a remote host, since the environment
     of the processes running in the screen session will contain an incorrect
     outdated value for the SSH_AUTH_SOCK environment variable (as it was at
     the time of the creation of the screen session).

RETURN VALUES
     The resock utility exits 0 on success, and >0 if an error occurs.

ENVIRONMENT
     The resock utility's operation is currently not directly affected by its
     environment.

FILES
     The resock utility examines the /tmp/ssh-* directories and looks for
     Unix-domain sockets named agent.*.

EXAMPLES
     Set the appropriate environment variables for the currently active SSH
     agent:

	   eval `resock`

SEE ALSO
     ssh-add(1)

HISTORY
     The resock utility was written by Peter Pentchev in 2010.

AUTHORS
     Peter Penchev ⟨roam@ringlet.net⟩

BUGS
     *	always looks for the most recent agent socket, which might not really
	be alive (the agent process itself may have been killed before clean‐
	ing up); should attempt to actually connect to the agent.

     *	always uses the output of whoami(1) as the owner of the agent socket;
	maybe there should be more heuristics (check the validity, try the
	USER or LOGIN environment variables) or even an -u command-line
	option.

BSD			       October 10, 2013				   BSD
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net