| 1 | .\" $Source: /mit/kerberos/src/man/RCS/rsh.1,v $ |
| 2 | .\" $Author: jtkohl $ |
| 3 | .\" $Header: rsh.1,v 4.1 89/01/23 11:39:11 jtkohl Exp $ |
| 4 | .\" |
| 5 | .\" Copyright (c) 1983 The Regents of the University of California. |
| 6 | .\" All rights reserved. |
| 7 | .\" |
| 8 | .\" Redistribution and use in source and binary forms are permitted |
| 9 | .\" provided that the above copyright notice and this paragraph are |
| 10 | .\" duplicated in all such forms and that any documentation, |
| 11 | .\" advertising materials, and other materials related to such |
| 12 | .\" distribution and use acknowledge that the software was developed |
| 13 | .\" by the University of California, Berkeley. The name of the |
| 14 | .\" University may not be used to endorse or promote products derived |
| 15 | .\" from this software without specific prior written permission. |
| 16 | .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR |
| 17 | .\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED |
| 18 | .\" WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
| 19 | .\" |
| 20 | .\" @(#)rsh.1 6.2 (Berkeley) 9/20/88 |
| 21 | .\" |
| 22 | .TH RSH 1 "Kerberos Version 4.0" "MIT Project Athena" |
| 23 | .UC 5 |
| 24 | .SH NAME |
| 25 | rsh \- remote shell |
| 26 | .SH SYNOPSIS |
| 27 | .B rsh |
| 28 | host |
| 29 | [ |
| 30 | .B \-l |
| 31 | username |
| 32 | ] [ |
| 33 | .B \-n |
| 34 | ] [ |
| 35 | .B \-x |
| 36 | ] [ |
| 37 | .B \-d |
| 38 | ] [ |
| 39 | .B \-k |
| 40 | realm ] command |
| 41 | .br |
| 42 | host |
| 43 | [ |
| 44 | .B \-l |
| 45 | username |
| 46 | ] [ |
| 47 | .B \-n |
| 48 | ] [ |
| 49 | .B \-x |
| 50 | ] [ |
| 51 | .B \-d |
| 52 | ] [ |
| 53 | .B \-k |
| 54 | realm ] command |
| 55 | .SH DESCRIPTION |
| 56 | .I Rsh |
| 57 | connects to the specified |
| 58 | .I host, |
| 59 | and executes the specified \fIcommand\fR. |
| 60 | .I Rsh |
| 61 | copies its standard input to the remote command, the standard |
| 62 | output of the remote command to its standard output, and the |
| 63 | standard error of the remote command to its standard error. |
| 64 | Interrupt, quit and terminate signals are propagated to the remote |
| 65 | command; \fIrsh\fP normally terminates when the remote command does. |
| 66 | .PP |
| 67 | The remote username used is the same as your local username, |
| 68 | unless you specify a different remote name with the |
| 69 | .B \-l |
| 70 | option. |
| 71 | Kerberos authentication is used, and authorization is determined as in |
| 72 | rlogin(1). |
| 73 | .PP |
| 74 | The |
| 75 | .B \-k |
| 76 | \fIrealm\fP option causes |
| 77 | .I rsh |
| 78 | to obtain tickets for the remote host in |
| 79 | .I realm |
| 80 | instead of the remote host's realm as determined by |
| 81 | .IR krb_realmofhost (3). |
| 82 | .PP |
| 83 | The |
| 84 | .B \-x |
| 85 | option turns on DES encryption for all data exchange. |
| 86 | This may introduce a significant delay in response time. |
| 87 | .PP |
| 88 | The |
| 89 | .B \-d |
| 90 | option turns on socket debugging (via \fIsetsockopt(2)\fR) on the TCP |
| 91 | sockets used for communication with the remote host. |
| 92 | .PP |
| 93 | The |
| 94 | .B \-n |
| 95 | option redirects input from the special device |
| 96 | .I /dev/null |
| 97 | (see the BUGS section below). |
| 98 | .PP |
| 99 | If you omit |
| 100 | .I command, |
| 101 | then instead of executing a single command, you will be logged in |
| 102 | on the remote host using |
| 103 | .IR rlogin (1). |
| 104 | .PP |
| 105 | Shell metacharacters which are not quoted are interpreted |
| 106 | on local machine, while quoted metacharacters are interpreted on |
| 107 | the remote machine. |
| 108 | Thus the command |
| 109 | .PP |
| 110 | \ \ \ rsh otherhost cat remotefile >> localfile |
| 111 | .PP |
| 112 | appends the remote file |
| 113 | .I remotefile |
| 114 | to the local file |
| 115 | .I localfile, |
| 116 | while |
| 117 | .PP |
| 118 | \ \ \ rsh otherhost cat remotefile ">>" otherremotefile |
| 119 | .PP |
| 120 | appends |
| 121 | .I remotefile |
| 122 | to |
| 123 | .I otherremotefile. |
| 124 | .PP |
| 125 | The host names for local machines are also commands in the directory |
| 126 | /usr/hosts; if you put this directory in your search path |
| 127 | then the |
| 128 | .B rsh |
| 129 | on the command line can be omitted. |
| 130 | .SH FILES |
| 131 | .ta 2i |
| 132 | /etc/hosts |
| 133 | .br |
| 134 | /usr/hosts/* |
| 135 | .DT |
| 136 | .SH SEE ALSO |
| 137 | rlogin(1), kerberos(3), krb_sendauth(3), krb_realmofhost(3) |
| 138 | .SH BUGS |
| 139 | If you are using |
| 140 | .IR csh (1) |
| 141 | and put a |
| 142 | .IR rsh (1) |
| 143 | in the background without redirecting its input |
| 144 | away from the terminal, it will block even if no reads |
| 145 | are posted by the remote command. If no input is desired |
| 146 | you should redirect the input of |
| 147 | .I rsh |
| 148 | to /dev/null using the |
| 149 | .B \-n |
| 150 | option. |
| 151 | .PP |
| 152 | You cannot run an interactive command |
| 153 | (like |
| 154 | .IR rogue (6) |
| 155 | or |
| 156 | .IR vi (1)); |
| 157 | use |
| 158 | .IR rlogin (1). |
| 159 | .PP |
| 160 | Stop signals stop the local \fIrsh\fP process only; this is arguably |
| 161 | wrong, but currently hard to fix for reasons too complicated to |
| 162 | explain here. |