summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--session.c8
-rw-r--r--ssh.110
3 files changed, 16 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index c1c240a82..43c701af3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,9 @@
3 - stevesk@cvs.openbsd.org 2002/09/12 19:11:52 3 - stevesk@cvs.openbsd.org 2002/09/12 19:11:52
4 [ssh-agent.c] 4 [ssh-agent.c]
5 %u for uid print; ok markus@ 5 %u for uid print; ok markus@
6 - stevesk@cvs.openbsd.org 2002/09/12 19:50:36
7 [session.c ssh.1]
8 add SSH_CONNECTION and deprecate SSH_CLIENT; bug #384. ok markus@
6 9
720020912 1020020912
8 - (djm) Made GNOME askpass programs return non-zero if cancel button is 11 - (djm) Made GNOME askpass programs return non-zero if cancel button is
@@ -653,4 +656,4 @@
653 save auth method before monitor_reset_key_state(); bugzilla bug #284; 656 save auth method before monitor_reset_key_state(); bugzilla bug #284;
654 ok provos@ 657 ok provos@
655 658
656$Id: ChangeLog,v 1.2464 2002/09/19 01:46:58 djm Exp $ 659$Id: ChangeLog,v 1.2465 2002/09/19 01:47:55 djm Exp $
diff --git a/session.c b/session.c
index d017b17f9..5da295289 100644
--- a/session.c
+++ b/session.c
@@ -33,7 +33,7 @@
33 */ 33 */
34 34
35#include "includes.h" 35#include "includes.h"
36RCSID("$OpenBSD: session.c,v 1.148 2002/08/29 15:57:25 stevesk Exp $"); 36RCSID("$OpenBSD: session.c,v 1.149 2002/09/12 19:50:36 stevesk Exp $");
37 37
38#include "ssh.h" 38#include "ssh.h"
39#include "ssh1.h" 39#include "ssh1.h"
@@ -1011,10 +1011,16 @@ do_setup_env(Session *s, const char *shell)
1011 } 1011 }
1012 } 1012 }
1013 1013
1014 /* SSH_CLIENT deprecated */
1014 snprintf(buf, sizeof buf, "%.50s %d %d", 1015 snprintf(buf, sizeof buf, "%.50s %d %d",
1015 get_remote_ipaddr(), get_remote_port(), get_local_port()); 1016 get_remote_ipaddr(), get_remote_port(), get_local_port());
1016 child_set_env(&env, &envsize, "SSH_CLIENT", buf); 1017 child_set_env(&env, &envsize, "SSH_CLIENT", buf);
1017 1018
1019 snprintf(buf, sizeof buf, "%.50s %d %.50s %d",
1020 get_remote_ipaddr(), get_remote_port(),
1021 get_local_ipaddr(packet_get_connection_in()), get_local_port());
1022 child_set_env(&env, &envsize, "SSH_CONNECTION", buf);
1023
1018 if (s->ttyfd != -1) 1024 if (s->ttyfd != -1)
1019 child_set_env(&env, &envsize, "SSH_TTY", s->tty); 1025 child_set_env(&env, &envsize, "SSH_TTY", s->tty);
1020 if (s->term) 1026 if (s->term)
diff --git a/ssh.1 b/ssh.1
index ce0dd291d..a65da5611 100644
--- a/ssh.1
+++ b/ssh.1
@@ -34,7 +34,7 @@
34.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 34.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
35.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 35.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36.\" 36.\"
37.\" $OpenBSD: ssh.1,v 1.165 2002/09/11 17:55:03 stevesk Exp $ 37.\" $OpenBSD: ssh.1,v 1.166 2002/09/12 19:50:36 stevesk Exp $
38.Dd September 25, 1999 38.Dd September 25, 1999
39.Dt SSH 1 39.Dt SSH 1
40.Os 40.Os
@@ -726,11 +726,11 @@ to make this work.)
726.It Ev SSH_AUTH_SOCK 726.It Ev SSH_AUTH_SOCK
727Identifies the path of a unix-domain socket used to communicate with the 727Identifies the path of a unix-domain socket used to communicate with the
728agent. 728agent.
729.It Ev SSH_CLIENT 729.It Ev SSH_CONNECTION
730Identifies the client end of the connection. 730Identifies the client and server ends of the connection.
731The variable contains 731The variable contains
732three space-separated values: client ip-address, client port number, 732four space-separated values: client ip-address, client port number,
733and server port number. 733server ip-address and server port number.
734.It Ev SSH_ORIGINAL_COMMAND 734.It Ev SSH_ORIGINAL_COMMAND
735The variable contains the original command line if a forced command 735The variable contains the original command line if a forced command
736is executed. 736is executed.