Skip to content

Commit

Permalink
publish v1.4f
Browse files Browse the repository at this point in the history
  • Loading branch information
hanrea committed Apr 2, 2021
1 parent f980c38 commit ede9538
Show file tree
Hide file tree
Showing 5 changed files with 223 additions and 73 deletions.
22 changes: 22 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,4 +1,26 @@

Version 1.4f
- Change behaviour when ssh child exits on signal. Previously
if SIGHUP, SIGTERM, or SIGKILL were used, autossh assumed that
it also was meant to exit. But it is possible that ssh was
killed because it had hung up or was unresponsive for some
reason. Restarting it is probably the better course.
- Fix order of arguments to kill(). Bug reported by Dapeng Gao.
- Ignore SIGPIPE. Issue noted and debugged by Rick van der Zwet.
- Note use of ExitOnForwardFailure and ClientAliveInterval in
README and man page (Till Maas).
- Should accept the default -1 with AUTOSSH_MAXSTART. Reported by
Daniel Hahler.
- Restart ssh when ssh exits with 2, which it can do if
setting up tunnel fails due to race with remote end
tearing down. (Daniel Sutcliffe).
- Daniel Hahler and Jindrich Makovich both reported that signals
will have no effect if before ssh started (sleeping in gatetime,
etc.) Signal handling is now set just just before monitoring the
child, and unset just after.
- Makefile should use LDFLAGS (Waldemar Brodkorb).
- memset() sigaction structure before use.

Version 1.4e
- By default, changing the poll time should change the first poll
time to match. Only have different times if AUTOSSH_FIRST_POLL
Expand Down
36 changes: 18 additions & 18 deletions Makefile.in
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# $Id: Makefile.in,v 1.7 2015/02/10 04:31:16 harding Exp $
# $Id: Makefile.in,v 1.8 2018/03/18 19:31:02 harding Exp $
#
# @configure_input@

VER= 1.4e
VER= 1.4f

SSH= @path_ssh@

Expand Down Expand Up @@ -31,7 +31,7 @@ all: $(TARGET)


$(TARGET): $(OFILES)
$(CC) $(CPPFLAGS) -o $(TARGET) $(OFILES) $(LIBS)
$(CC) $(CPPFLAGS) $(LDFLAGS) -o $(TARGET) $(OFILES) $(LIBS)

clean:
- /bin/rm -f *.o *.a *.core *~
Expand All @@ -45,18 +45,18 @@ distclean: allclean
- /bin/rm -f Makefile

install: $(TARGET)
mkdir -p -m 755 $(bindir)
mkdir -p -m 755 $(prefix)/share/doc/autossh
mkdir -p -m 755 $(datadir)/examples/autossh
mkdir -p -m 755 $(mandir)/man1
cp $(TARGET) $(bindir)
cp CHANGES README $(datadir)/doc/autossh
cp autossh.host $(datadir)/examples/autossh
cp rscreen $(datadir)/examples/autossh
cp autossh.1 $(mandir)/man1
chmod 755 $(bindir)/$(TARGET)
chmod 644 $(datadir)/doc/autossh/CHANGES
chmod 644 $(datadir)/doc/autossh/README
chmod 644 $(datadir)/examples/autossh/autossh.host
chmod 644 $(datadir)/examples/autossh/rscreen
chmod 644 $(mandir)/man1/autossh.1
mkdir -p -m 755 $(DESTDIR)$(bindir)
mkdir -p -m 755 $(DESTDIR)$(prefix)/share/doc/autossh
mkdir -p -m 755 $(DESTDIR)$(datadir)/examples/autossh
mkdir -p -m 755 $(DESTDIR)$(mandir)/man1
cp $(TARGET) $(DESTDIR)$(bindir)
cp CHANGES README $(DESTDIR)$(datadir)/doc/autossh
cp autossh.host $(DESTDIR)$(datadir)/examples/autossh
cp rscreen $(DESTDIR)$(datadir)/examples/autossh
cp autossh.1 $(DESTDIR)$(mandir)/man1
chmod 755 $(DESTDIR)$(bindir)/$(TARGET)
chmod 644 $(DESTDIR)$(datadir)/doc/autossh/CHANGES
chmod 644 $(DESTDIR)$(datadir)/doc/autossh/README
chmod 644 $(DESTDIR)$(datadir)/examples/autossh/autossh.host
chmod 644 $(DESTDIR)$(datadir)/examples/autossh/rscreen
chmod 644 $(DESTDIR)$(mandir)/man1/autossh.1
15 changes: 14 additions & 1 deletion README
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ autossh has only three arguments of its own:

-f Causes autossh to drop to the background before running ssh. The
-f flag is stripped from arguments passed to ssh. Note that there
is a crucial a difference between the -f with autossh, and -f
is a crucial difference between the -f with autossh, and -f
with ssh: when used with autossh, ssh will be *unable* to ask for
passwords or passphrases. When -f is used, the "starting gate"
time (see AUTOSSH_GATETIME) will be set to 0.
Expand Down Expand Up @@ -206,6 +206,19 @@ The following environment variables can be set:
of this possible use, AUTOSSH_PORT overrides
the -M flag.

SSH Options
------------------

There are two particular OpenSSH options that are useful when using
autossh:

1) ExitOnForwardFailure=yes on the client side to make sure forwardings
have succeeded when autossh assumes the connection is setup properly.

2) ClientAliveInterval on the server side to make sure the listening
socket is closed on the server side if the connection closes on the
client side.

Logging and Syslog
------------------

Expand Down
24 changes: 20 additions & 4 deletions autossh.1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.\" -*- nroff -*-
.\"
.\" Author: Carson Harding
.\" Copyright (c) 2002 Carson Harding. All rights reserved.
.\" Copyright (c) 2002-2018 Carson Harding. All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted.
Expand All @@ -17,9 +17,9 @@
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
.\" $Id: autossh.1,v 1.23 2015/02/10 04:31:16 harding Exp $
.\" $Id: autossh.1,v 1.24 2018/03/18 19:28:38 harding Exp $
.\"
.Dd Jul 20, 2004
.Dd Mar 18, 2018
.Dt AUTOSSH 1
.Os
.Sh NAME
Expand Down Expand Up @@ -192,7 +192,7 @@ the monitoring port.
causes autossh to drop to the background before running ssh. The
.Fl f
flag is stripped from arguments passed to ssh. Note that there is a crucial
a difference between
difference between
.Fl f
with autossh, and
.Fl f
Expand Down Expand Up @@ -265,11 +265,27 @@ Sets the connection monitoring port. Mostly in case ssh appropriates
-M at some time. But because of this possible use, AUTOSSH_PORT
overrides the -M flag. A value of 0 turns the monitoring function off.
.El
.Sh ENVIRONMENT
There are two particular OpenSSH options that are useful when using
.Nm
:
.Fp
.Cm ExitOnForwardFailure=yes
on the client side to make sure forwardings
have succeeded when autossh assumes the connection is setup properly.
.Fp
.Cm ClientAliveInterval
on the server side to make sure the listening
socket is closed on the server side if the connection closes on the
client side.
.El
.Sh AUTHOR
.Nm
was written by Carson Harding.
.Sh SEE ALSO
.Xr ssh 1 ,
.Xr ssh_config 5,
.Xr sshd_config 5,
.Xr ssh-add 1 ,
.Xr ssh-agent 1 ,
.Xr ssh-keygen 1 ,
Expand Down
Loading

0 comments on commit ede9538

Please # to comment.