| 1 |
This is inetutils.info, produced by .texi2any-real version 7.1.1 from |
| 2 |
inetutils.texi. |
| 3 |
|
| 4 |
This manual documents version 2.8 of the GNU networking utilities. |
| 5 |
|
| 6 |
Copyright © 2000-2026 Free Software Foundation, Inc. |
| 7 |
|
| 8 |
Permission is granted to copy, distribute and/or modify this |
| 9 |
document under the terms of the GNU Free Documentation License, |
| 10 |
Version 1.3 or any later version published by the Free Software |
| 11 |
Foundation; with no Invariant Sections, no Front-Cover Texts, and |
| 12 |
no Back-Cover Texts. A copy of the license is included in the |
| 13 |
section entitled "GNU Free Documentation License". |
| 14 |
INFO-DIR-SECTION Basics |
| 15 |
START-INFO-DIR-ENTRY |
| 16 |
* Inetutils: (inetutils). GNU networking utilities. |
| 17 |
* Common options: (inetutils)Common options. Common options. |
| 18 |
END-INFO-DIR-ENTRY |
| 19 |
|
| 20 |
INFO-DIR-SECTION Individual utilities |
| 21 |
START-INFO-DIR-ENTRY |
| 22 |
* dnsdomainname: (inetutils)dnsdomainname invocation. Show DNS domain name. |
| 23 |
* ftp: (inetutils)ftp invocation. FTP client. |
| 24 |
* ftpd: (inetutils)ftpd invocation. FTP Daemon. |
| 25 |
* hostname: (inetutils)hostname invocation. Show or set system host name. |
| 26 |
* ifconfig: (inetutils)ifconfig invocation. Configure network interfaces. |
| 27 |
* inetd: (inetutils)inetd invocation. Internet super-server. |
| 28 |
* logger: (inetutils)logger invocation. Send messages to the system log. |
| 29 |
* ping6: (inetutils)ping6 invocation. Packets to IPv6 network hosts. |
| 30 |
* ping: (inetutils)ping invocation. Packets to network hosts. |
| 31 |
* rcp: (inetutils)rcp invocation. Remote copy |
| 32 |
* rexec: (inetutils)rexec invocation. Remote execution client. |
| 33 |
* rexecd: (inetutils)rexecd invocation. Remote execution server. |
| 34 |
* rlogin: (inetutils)rlogin invocation. Remote login. |
| 35 |
* rlogind: (inetutils)rlogind invocation. Remote login server. |
| 36 |
* rsh: (inetutils)rsh invocation. Remote shell. |
| 37 |
* rshd: (inetutils)rshd invocation. Remote shell server. |
| 38 |
* syslogd: (inetutils)syslogd invocation. Syslog server. |
| 39 |
* talk: (inetutils)talk invocation. Talk client. |
| 40 |
* talkd: (inetutils)talkd invocation. Talk server. |
| 41 |
* telnet: (inetutils)telnet invocation. User interface to TELNET. |
| 42 |
* telnetd: (inetutils)telnetd invocation. Telnet server. |
| 43 |
* tftp: (inetutils)tftp invocation. TFTP client. |
| 44 |
* tftpd: (inetutils)tftpd invocation. TFTP server. |
| 45 |
* traceroute: (inetutils)traceroute invocation. Trace the route to a host. |
| 46 |
* uucpd: (inetutils)uucpd invocation. Unix to Unix Copy. |
| 47 |
* whois: (inetutils)whois invocation. Whois user interface. |
| 48 |
END-INFO-DIR-ENTRY |
| 49 |
|
| 50 |
|
| 51 |
File: inetutils.info, Node: Top, Next: Introduction, Up: (dir) |
| 52 |
|
| 53 |
GNU Inetutils |
| 54 |
************* |
| 55 |
|
| 56 |
This manual documents version 2.8 of the GNU networking utilities. |
| 57 |
|
| 58 |
Copyright © 2000-2026 Free Software Foundation, Inc. |
| 59 |
|
| 60 |
Permission is granted to copy, distribute and/or modify this |
| 61 |
document under the terms of the GNU Free Documentation License, |
| 62 |
Version 1.3 or any later version published by the Free Software |
| 63 |
Foundation; with no Invariant Sections, no Front-Cover Texts, and |
| 64 |
no Back-Cover Texts. A copy of the license is included in the |
| 65 |
section entitled "GNU Free Documentation License". |
| 66 |
|
| 67 |
* Menu: |
| 68 |
|
| 69 |
* Introduction:: Caveats, overview, and authors. |
| 70 |
* Common options:: Common options. |
| 71 |
|
| 72 |
Diagnostic programs |
| 73 |
|
| 74 |
* dnsdomainname invocation:: Show DNS domain name. |
| 75 |
* hostname invocation:: Show or set system host name. |
| 76 |
* ifconfig invocation:: Configure network interfaces. |
| 77 |
* logger invocation:: Send messages to system log. |
| 78 |
* ping invocation:: Packets to network hosts. |
| 79 |
* ping6 invocation:: Packets to IPv6 network hosts. |
| 80 |
* traceroute invocation:: Trace the route to a host. |
| 81 |
* whois invocation:: Whois user interface. |
| 82 |
|
| 83 |
Clients |
| 84 |
|
| 85 |
* ftp invocation:: FTP client. |
| 86 |
* rcp invocation:: Remote copy |
| 87 |
* rexec invocation:: Remote execution client. |
| 88 |
* rlogin invocation:: Remote login. |
| 89 |
* rsh invocation:: Remote shell. |
| 90 |
* talk invocation:: Talk client. |
| 91 |
* telnet invocation:: User interface to TELNET. |
| 92 |
* tftp invocation:: TFTP client. |
| 93 |
|
| 94 |
Daemons |
| 95 |
|
| 96 |
* inetd invocation:: Internet super-server. |
| 97 |
* syslogd invocation:: Syslog server. |
| 98 |
* ftpd invocation:: FTP Daemon. |
| 99 |
* rexecd invocation:: Remote execution server. |
| 100 |
* rlogind invocation:: Remote login server. |
| 101 |
* rshd invocation:: Remote shell server. |
| 102 |
* talkd invocation:: Talk server. |
| 103 |
* telnetd invocation:: Telnet server. |
| 104 |
* tftpd invocation:: TFTP server. |
| 105 |
* uucpd invocation:: Unix to Unix Copy. |
| 106 |
|
| 107 |
Appendix |
| 108 |
|
| 109 |
* GNU Free Documentation License:: The license for this manual. |
| 110 |
* Index:: Index of manual. |
| 111 |
|
| 112 |
|
| 113 |
File: inetutils.info, Node: Introduction, Next: Common options, Prev: Top, Up: Top |
| 114 |
|
| 115 |
1 Introduction |
| 116 |
************** |
| 117 |
|
| 118 |
The GNU Networking Utilities is a distribution of common networking |
| 119 |
utilities and servers, including for example ping, traceroute and ftp. |
| 120 |
|
| 121 |
This manual is a work in progress: many sections make no attempt to |
| 122 |
explain basic concepts in a way suitable for novices. Thus, if you are |
| 123 |
interested, please get involved in improving this manual. The entire |
| 124 |
GNU community will benefit. |
| 125 |
|
| 126 |
Please report bugs to <[email protected]>. Remember to include |
| 127 |
the version number, machine architecture, input files, and any other |
| 128 |
information needed to reproduce the bug: your input, what you expected, |
| 129 |
what you got, and why it is wrong. Diffs are welcome, but please |
| 130 |
include a description of the problem as well, since this is sometimes |
| 131 |
difficult to infer. |
| 132 |
|
| 133 |
The individual utilities were originally derived from the 4.4BSDLite2 |
| 134 |
distribution, although some of them have more or less been rewritten. |
| 135 |
What you are reading now is the authoritative and complete documentation |
| 136 |
for these utilities; the man pages are now automatically generated. |
| 137 |
|
| 138 |
Many features were integrated from NetBSD, OpenBSD, FreeBSD and |
| 139 |
GNU/Linux, the merges were done by a group of dedicated hackers (in no |
| 140 |
particular order): Jeff Bailey, Marcus Brinkmann, Michael Vogt, Bernhard |
| 141 |
Rosenkraenzer, Kaveh R. Ghazi, NIIBE Yutaka, Nathan Neulinger, Jeff |
| 142 |
Smith, Dan Stromberg, David O'Shea, Frederic Goudal, Gerald Combs, |
| 143 |
Joachim Gabler, Marco D'Itri, Sergey Poznyakoff, and many more. |
| 144 |
|
| 145 |
|
| 146 |
File: inetutils.info, Node: Common options, Next: dnsdomainname invocation, Prev: Introduction, Up: Top |
| 147 |
|
| 148 |
2 Common options |
| 149 |
**************** |
| 150 |
|
| 151 |
Certain options are available in all these programs. Rather than |
| 152 |
writing identical descriptions for each of the programs, they are |
| 153 |
described here. (In fact, every GNU program accepts, or should accept, |
| 154 |
these options.) |
| 155 |
|
| 156 |
Many of these programs take arbitrary strings as arguments. In those |
| 157 |
cases, ‘--help’ and ‘--version’ are taken as these options only if there |
| 158 |
is one and exactly one command line argument. |
| 159 |
|
| 160 |
‘--help’ |
| 161 |
Print a usage message, listing all available options, then exit |
| 162 |
successfully. |
| 163 |
|
| 164 |
‘--usage’ |
| 165 |
Print a condensed usage message, displaying all available options |
| 166 |
formatted like a command line call, then exit successfully. |
| 167 |
|
| 168 |
‘--version’ |
| 169 |
Print the version number, then exit successfully. |
| 170 |
|
| 171 |
‘--’ |
| 172 |
Delimit the option list. Later arguments, if any, are treated as |
| 173 |
operands even if they begin with ‘-’. |
| 174 |
|
| 175 |
* Menu: |
| 176 |
|
| 177 |
* Exit status:: Indicating program success or failure. |
| 178 |
|
| 179 |
|
| 180 |
File: inetutils.info, Node: Exit status, Up: Common options |
| 181 |
|
| 182 |
2.1 Exit status |
| 183 |
=============== |
| 184 |
|
| 185 |
Nearly every command invocation yields an integral “exit status” that |
| 186 |
can be used to change how other commands work. For the vast majority of |
| 187 |
commands, an exit status of zero indicates success. Failure is |
| 188 |
indicated by a nonzero value -- typically ‘1’, though it may differ on |
| 189 |
unusual platforms, as POSIX requires only that it be nonzero. |
| 190 |
|
| 191 |
|
| 192 |
File: inetutils.info, Node: dnsdomainname invocation, Next: hostname invocation, Prev: Common options, Up: Top |
| 193 |
|
| 194 |
3 ‘dnsdomainname’: Show DNS domain name |
| 195 |
*************************************** |
| 196 |
|
| 197 |
‘dnsdomainname’ is a program to show the domain part of the system's |
| 198 |
fully qualified domain name. For example, if the FQDN of the system is |
| 199 |
‘name.example.org’ the command will show ‘example.org’. The output is |
| 200 |
not necessarily related to the NIS/YP domain name. |
| 201 |
|
| 202 |
The tool uses gethostname to get the host name of the system and then |
| 203 |
getaddrinfo to resolve it into a canonical name. The domain part of the |
| 204 |
canonical name is shown, i.e., the part after the first period (‘.’) of |
| 205 |
the official name. |
| 206 |
|
| 207 |
Synopsis: |
| 208 |
|
| 209 |
dnsdomainname [OPTION...] |
| 210 |
|
| 211 |
There is no command specific option. |
| 212 |
|
| 213 |
|
| 214 |
File: inetutils.info, Node: hostname invocation, Next: ifconfig invocation, Prev: dnsdomainname invocation, Up: Top |
| 215 |
|
| 216 |
4 ‘hostname’: Show or set system host name. |
| 217 |
******************************************* |
| 218 |
|
| 219 |
‘hostname’ is a program to show or to set the name of a host system. |
| 220 |
|
| 221 |
Synopsis: |
| 222 |
|
| 223 |
hostname [OPTION...] |
| 224 |
hostname NAME |
| 225 |
|
| 226 |
where NAME is the name to be used by the running host. |
| 227 |
|
| 228 |
4.1 Command line options |
| 229 |
======================== |
| 230 |
|
| 231 |
‘-a’ |
| 232 |
‘--aliases’ |
| 233 |
Get alias names. |
| 234 |
|
| 235 |
‘-d’ |
| 236 |
‘--domain’ |
| 237 |
Get DNS domain name. |
| 238 |
|
| 239 |
‘-f’ |
| 240 |
‘--fqdn’ |
| 241 |
‘--long’ |
| 242 |
Get DNS host name or Fully Qualified Domain Name. |
| 243 |
|
| 244 |
‘-F FILE’ |
| 245 |
‘--file=FILE’ |
| 246 |
Set host name or NIS domain name from FILE. |
| 247 |
|
| 248 |
‘-i’ |
| 249 |
‘--ip-addresses’ |
| 250 |
Get addresses for the host name. |
| 251 |
|
| 252 |
‘-s’ |
| 253 |
‘--short’ |
| 254 |
Get short host name. |
| 255 |
|
| 256 |
‘-y’ |
| 257 |
‘--yp’ |
| 258 |
‘--nis’ |
| 259 |
Get NIS/YP domain name. |
| 260 |
|
| 261 |
|
| 262 |
File: inetutils.info, Node: ifconfig invocation, Next: logger invocation, Prev: hostname invocation, Up: Top |
| 263 |
|
| 264 |
5 ‘ifconfig’: Configure network interfaces |
| 265 |
****************************************** |
| 266 |
|
| 267 |
‘ifconfig’ is a program to retrieve and to set selected properties of |
| 268 |
network interfaces. It is best viewed as a tool to get information, |
| 269 |
rather than for changing the behaviour of adapters, since it is hard to |
| 270 |
support property setting in a portable manner. |
| 271 |
|
| 272 |
Synopsis: |
| 273 |
|
| 274 |
ifconfig IFACE [ARG...] |
| 275 |
ifconfig -i IFACE [OPTION...] [-i IFACE2 [OPTION...]] |
| 276 |
|
| 277 |
5.1 Command line options |
| 278 |
======================== |
| 279 |
|
| 280 |
‘-a’ |
| 281 |
‘--all’ |
| 282 |
Display all available interfaces, including those that not are |
| 283 |
marked as 'up', i.e., also the inactive interfaces. |
| 284 |
|
| 285 |
‘-A ADDR’ |
| 286 |
‘--address=ADDR’ |
| 287 |
Set address of selected interface to ADDR. |
| 288 |
|
| 289 |
‘-b ADDR’ |
| 290 |
‘-B ADDR’ |
| 291 |
‘--brdaddr=ADDR’ |
| 292 |
‘--broadcast=ADDR’ |
| 293 |
Set broadcast address of selected interface to ADDR. |
| 294 |
|
| 295 |
‘-d ADDR’ |
| 296 |
‘-p ADDR’ |
| 297 |
‘--dstaddr=ADDR’ |
| 298 |
‘--peer=ADDR’ |
| 299 |
Set destination (peer) address of selected interface. |
| 300 |
|
| 301 |
‘--down’ |
| 302 |
Deactivate the selected interface. |
| 303 |
|
| 304 |
‘-F LIST’ |
| 305 |
‘--flags=LIST’ |
| 306 |
Change those interface flags mentioned in LIST. The argument is a |
| 307 |
comma separated list of one or more flag names to be set, or in |
| 308 |
case the name is prepended with ‘no’, the corresponding flag is |
| 309 |
cleared. The output of ‘ifconfig’ with the option ‘--help’ |
| 310 |
contains a list of available flag names. |
| 311 |
|
| 312 |
‘--format=FORMAT’ |
| 313 |
Select output format; the value ‘help’ prints a list of all |
| 314 |
available formats. |
| 315 |
|
| 316 |
‘-i NAME’ |
| 317 |
‘--interface=NAME’ |
| 318 |
Select the named interface for any following action. |
| 319 |
|
| 320 |
‘-l’ |
| 321 |
‘--list’ |
| 322 |
List, with name only, all available interfaces, or only those |
| 323 |
selected should at least one option ‘-i’ have specified. |
| 324 |
|
| 325 |
‘-m MASK’ |
| 326 |
‘--netmask=MASK’ |
| 327 |
Set netmask of selected interface to MASK. |
| 328 |
|
| 329 |
‘--metric=N’ |
| 330 |
Set the metric of selected interface to the number N. |
| 331 |
|
| 332 |
‘-M N’ |
| 333 |
‘--mtu=N’ |
| 334 |
Set MTU of selected interface to the number N. |
| 335 |
|
| 336 |
‘-s’ |
| 337 |
‘--short’ |
| 338 |
Use short output format. This is identical to specifying |
| 339 |
‘--format=netstat’. |
| 340 |
|
| 341 |
‘--up’ |
| 342 |
Activate the selected interface. |
| 343 |
|
| 344 |
‘-v’ |
| 345 |
‘--verbose’ |
| 346 |
Print informational messages when configuring an interface. |
| 347 |
|
| 348 |
Observe that the use of program options is the only manner in which |
| 349 |
‘ifconfig’ is able to handle multiple interfaces in one invocation. |
| 350 |
Once a particular interface has been selected using ‘-i’, it is affected |
| 351 |
by any following option until replaced by another interface selector. |
| 352 |
This is also the main cause, that ‘ifconfig’ is unable to treat options |
| 353 |
independently of their order, as is mostly the case in other GNU |
| 354 |
software. |
| 355 |
|
| 356 |
5.2 Formatted status output |
| 357 |
=========================== |
| 358 |
|
| 359 |
The status of one or more interfaces can be presented in a number of |
| 360 |
different formats. A list of them is printed by the option |
| 361 |
‘--format=help’. In the following table the valid formats are given, |
| 362 |
each is used in the form ‘--format=NAME’. |
| 363 |
|
| 364 |
check |
| 365 |
check-existence |
| 366 |
? |
| 367 |
Place holders for the ability to check whether the interfaces |
| 368 |
selected by one or more options ‘-i’ are determining existing |
| 369 |
interfaces in the running system. No output in case of success, an |
| 370 |
error message in case of a failure. |
| 371 |
|
| 372 |
gnu |
| 373 |
default |
| 374 |
Standard GNU output format. |
| 375 |
|
| 376 |
gnu-one-entry |
| 377 |
Like the previous format, but with intermediary newlines removed. |
| 378 |
|
| 379 |
help |
| 380 |
Display a list of valid formats, together with a short description |
| 381 |
for each choice. |
| 382 |
|
| 383 |
net-tools |
| 384 |
Imitation of presentation used by the implementation in |
| 385 |
‘net-tools’. Default format for GNU/Linux. |
| 386 |
|
| 387 |
netstat |
| 388 |
Terse output with statistics, similar to that of ‘netstat -i’. |
| 389 |
|
| 390 |
osf |
| 391 |
Format variant of ‘unix’ preferred by OSF's implementation. |
| 392 |
|
| 393 |
unix |
| 394 |
Traditional UNIX type format. Default for BSD, HPUX and Solaris. |
| 395 |
|
| 396 |
5.3 Legacy syntax |
| 397 |
================= |
| 398 |
|
| 399 |
The traditional mode of invoking ‘ifconfig’ is via a parsed command |
| 400 |
line, without all use of program switches and options, relying fully on |
| 401 |
argument parsing. This mode of use is supported also in the present |
| 402 |
implementation, but keep in mind that only one interface can be |
| 403 |
manipulated using this legacy syntax. |
| 404 |
|
| 405 |
ifconfig NAME [ADDR [DSTADDR]] [broadcast BRDADDR] [netmask MASK] |
| 406 |
[metric N] [mtu N] [up|down] |
| 407 |
|
| 408 |
As is conventional, only the primary address and possibly the peer |
| 409 |
destination address are stated as bare arguments, without a specifying |
| 410 |
keyword. Some slight variation on this syntax will depend on the target |
| 411 |
system for which the program is being built, as not all platforms |
| 412 |
support identical abilities. The best information is found via the |
| 413 |
usage massage ‘ifconfig --usage’. |
| 414 |
|
| 415 |
|
| 416 |
File: inetutils.info, Node: logger invocation, Next: ping invocation, Prev: ifconfig invocation, Up: Top |
| 417 |
|
| 418 |
6 ‘logger’: Send messages to system log |
| 419 |
*************************************** |
| 420 |
|
| 421 |
‘logger’ is a program to send entries to system log. It provides a |
| 422 |
shell command interface similar to the system log module. For |
| 423 |
background information, *note Syslog: (libc)Syslog. |
| 424 |
|
| 425 |
Synopsis: |
| 426 |
|
| 427 |
logger [OPTION...] [MESSAGE] |
| 428 |
|
| 429 |
6.1 Command line options |
| 430 |
======================== |
| 431 |
|
| 432 |
‘-4’ |
| 433 |
‘--ipv4’ |
| 434 |
Use IPv4 as transport when logging to a host. The default |
| 435 |
behaviour is to use whatever IP version that matches the host. |
| 436 |
|
| 437 |
‘-6’ |
| 438 |
‘--ipv6’ |
| 439 |
Use IPv6 as transport when logging to a host. The option is |
| 440 |
present also on systems without support for IPv6, but will then |
| 441 |
issue a warning and then fall back to IPv4 when delivering the |
| 442 |
message. |
| 443 |
|
| 444 |
Both options are most influential when the target host is named |
| 445 |
using a symbolic name, but numerical addresses for host or source |
| 446 |
must also match if either of ‘--ipv4’ or ‘--ipv6’ is stated. |
| 447 |
|
| 448 |
‘-f FILE’ |
| 449 |
‘--file=FILE’ |
| 450 |
Log the content of the specified file. If FILE is ‘-’ then |
| 451 |
standard input is assumed. |
| 452 |
|
| 453 |
‘-h HOST’ |
| 454 |
‘--host=HOST’ |
| 455 |
Send messages to the given host or socket. The HOST argument can |
| 456 |
be either a local UNIX socket name (containing a slash ‘/’), or be |
| 457 |
of the form |
| 458 |
|
| 459 |
HOST[:PORT] |
| 460 |
|
| 461 |
where HOST is the remote host name or IP address, and the optional |
| 462 |
PORT is a decimal port number or symbolic service name from |
| 463 |
‘/etc/services’. If PORT is not specified, the port number |
| 464 |
corresponding to the ‘syslog’ service is used. If a numerical IPv6 |
| 465 |
address is given without a port specification, then the address |
| 466 |
must be enclosed within brackets (like [::1]). |
| 467 |
|
| 468 |
‘-i[PID]’ |
| 469 |
‘--id=[PID]’ |
| 470 |
Add process ID to each message. If PID is not supplied, use the |
| 471 |
process ID of the logger process with each line. Notice, that PID |
| 472 |
is an optional argument. When supplied to the ‘-i’ option, it must |
| 473 |
follow the ‘i’ letter immediately, without any separating |
| 474 |
whitespace. When supplied to the ‘--id’ form, it must be separated |
| 475 |
from it by exactly one equals sign. |
| 476 |
|
| 477 |
‘-p PRIORITY’ |
| 478 |
‘--priority=PRIORITY’ |
| 479 |
Enter the message with the specified priority. The priority may be |
| 480 |
specified numerically or as a ‘facility.level’ pair. For example, |
| 481 |
‘-p local3.info’ logs the message at the informational level in the |
| 482 |
‘local3’ facility. The default is ‘user.notice’. |
| 483 |
|
| 484 |
The actual list of supported facilities and levels is system |
| 485 |
specific. |
| 486 |
|
| 487 |
‘-s’ |
| 488 |
‘--stderr’ |
| 489 |
Log the message to standard error, as well as to the system log. |
| 490 |
|
| 491 |
‘-S ADDR’ |
| 492 |
‘--source=ADDR’ |
| 493 |
Supply the source IP address for INET connections. This option is |
| 494 |
useful in conjunction with ‘--host’ (see above). The kind of |
| 495 |
address specified here (IPv4 or IPv6) will propagate to influence |
| 496 |
the resolution of the host address, if it is a symbolic name. |
| 497 |
|
| 498 |
‘-t TAG’ |
| 499 |
‘--tag=TAG’ |
| 500 |
Mark every line in the log with the specified tag. |
| 501 |
|
| 502 |
‘-u SOCKET’ |
| 503 |
‘--unix=SOCKET’ |
| 504 |
Send messages to the given local UNIX socket. The SOCKET argument |
| 505 |
can be either an absolute path (starting with a slash ‘/’), or a |
| 506 |
relative path understood relative to the current working directory. |
| 507 |
|
| 508 |
The options are followed by the message which should be written to |
| 509 |
the log. If not specified, and the ‘-f’ flag is not provided, standard |
| 510 |
input is logged. |
| 511 |
|
| 512 |
6.2 Examples |
| 513 |
============ |
| 514 |
|
| 515 |
The following examples illustrate the usage of the ‘logger’ command: |
| 516 |
|
| 517 |
1. Log the message ‘System rebooted’ to the local syslog. Use default |
| 518 |
facility and priority: |
| 519 |
|
| 520 |
logger System rebooted |
| 521 |
|
| 522 |
2. Run command and send its error output to the channel ‘local0.err’. |
| 523 |
Mark each message with tag ‘cmd’: |
| 524 |
|
| 525 |
command 2>&1 | logger -p local0.err -t cmd |
| 526 |
|
| 527 |
3. Log each line from file ‘warnings’ to channel ‘daemon.warn’ on host |
| 528 |
‘logger.runasimi.org’, using the source IP ‘10.10.10.1’: |
| 529 |
|
| 530 |
logger -p daemon.warn -h logger.runasimi.org -S 10.10.10.1 \ |
| 531 |
--file warnings |
| 532 |
|
| 533 |
|
| 534 |
File: inetutils.info, Node: ping invocation, Next: ping6 invocation, Prev: logger invocation, Up: Top |
| 535 |
|
| 536 |
7 ‘ping’: Packets to network hosts |
| 537 |
********************************** |
| 538 |
|
| 539 |
‘ping’ uses ICMP datagrams to provoke a response from the chosen |
| 540 |
destination host, mainly intending to probe whether it is alive. |
| 541 |
|
| 542 |
The used datagram, of type ‘ECHO_REQUEST’, contains some header |
| 543 |
information and some additional payload, usually a time stamp. By a |
| 544 |
suitable choice of payload, different host or router properties are |
| 545 |
detectable, as the emitted datagram travels to its destination. |
| 546 |
|
| 547 |
Synopsis: |
| 548 |
|
| 549 |
ping [OPTION...] HOST |
| 550 |
|
| 551 |
Sending echo requests is the standard use of ‘ping’, but by far not the |
| 552 |
only use case. |
| 553 |
|
| 554 |
* Menu: |
| 555 |
|
| 556 |
* Ping options:: |
| 557 |
* Fault isolation:: |
| 558 |
* Duplicate and damaged packets:: |
| 559 |
* Data patterns:: |
| 560 |
* TTL details:: |
| 561 |
* Further remarks:: |
| 562 |
|
| 563 |
|
| 564 |
File: inetutils.info, Node: Ping options, Next: Fault isolation, Up: ping invocation |
| 565 |
|
| 566 |
7.1 Command line options |
| 567 |
======================== |
| 568 |
|
| 569 |
Selection of packet type is handled by these first options: |
| 570 |
|
| 571 |
‘--address’ |
| 572 |
Send ICMP_ADDRESS packets, thus requesting the address netmask in |
| 573 |
use by the targeted host. |
| 574 |
|
| 575 |
‘--echo’ |
| 576 |
Send ICMP_ECHO requests. This is the default action. |
| 577 |
|
| 578 |
‘--mask’ |
| 579 |
Identical to ‘--address’. |
| 580 |
|
| 581 |
‘--timestamp’ |
| 582 |
Send ICMP_TIMESTAMP packets, thereby requesting a timed response |
| 583 |
from the targeted host. |
| 584 |
|
| 585 |
In successful cases three time values are returned. All are |
| 586 |
expected to state the number of milliseconds since midnight UTC. |
| 587 |
The first of these, ‘icmp_otime’, contains the original time of |
| 588 |
sending the request. Then comes ‘icmp_rtime’, the time of |
| 589 |
reception by the target, and finally, ‘icmp_ttime’, the time of |
| 590 |
transmitting an answer back to the originator. |
| 591 |
|
| 592 |
‘-t TYPE’ |
| 593 |
‘--type=TYPE’ |
| 594 |
Send TYPE packets. Accepted values are ‘address’, ‘echo’, ‘mask’, |
| 595 |
and ‘timestamp’. |
| 596 |
|
| 597 |
The following options are available for all packet types: |
| 598 |
|
| 599 |
‘-c N’ |
| 600 |
‘--count=N’ |
| 601 |
Stop after sending and receiving answers to a total of N packets. |
| 602 |
|
| 603 |
‘-d’ |
| 604 |
‘--debug’ |
| 605 |
Set the SO_DEBUG option on the socket being used. |
| 606 |
|
| 607 |
‘-i N’ |
| 608 |
‘--interval=N’ |
| 609 |
Wait N seconds until sending next packet. The default is to wait |
| 610 |
for one second between packets. This option is incompatible with |
| 611 |
the option ‘-f’. |
| 612 |
|
| 613 |
‘-n’ |
| 614 |
‘--numeric’ |
| 615 |
Numeric output only. No attempt will be made to resolve symbolic |
| 616 |
names for host addresses. |
| 617 |
|
| 618 |
‘-r’ |
| 619 |
‘--ignore-routing’ |
| 620 |
Bypass the normal routing tables and send directly to a host on an |
| 621 |
attached network. If the host is not on a directly attached |
| 622 |
network, an error is returned. This option can be used to ping a |
| 623 |
local host through an interface that has no route through it (e.g., |
| 624 |
after the interface was dropped by ‘routed’). |
| 625 |
|
| 626 |
‘-T NUM’ |
| 627 |
‘--tos=NUM’ |
| 628 |
Set type-of-service, TOS field, to NUM on transmitted packets. |
| 629 |
|
| 630 |
‘--ttl=N’ |
| 631 |
Set the specified number N as value of time-to-live when |
| 632 |
transmitting packets. Acceptable values are 1 to 255, inclusive. |
| 633 |
|
| 634 |
‘-v’ |
| 635 |
‘--verbose’ |
| 636 |
Produce more verbose output, giving more statistics. |
| 637 |
|
| 638 |
‘-w N’ |
| 639 |
‘--timeout=N’ |
| 640 |
Stop after N seconds. |
| 641 |
|
| 642 |
‘-W N’ |
| 643 |
‘--linger=N’ |
| 644 |
Maximum number of seconds N to wait for a response. |
| 645 |
|
| 646 |
Finally, these last options are relevant only for sending echo |
| 647 |
requests, allowing many variations in order to detect various |
| 648 |
peculiarities of the targeted host, or the intermediary routers for that |
| 649 |
matter. |
| 650 |
|
| 651 |
‘-f’ |
| 652 |
‘--flood’ |
| 653 |
Flood ping. Outputs packets as fast as they come back or one |
| 654 |
hundred times per second, whichever is more. For every |
| 655 |
ECHO_REQUEST packet sent, a period ‘.’ is printed, while for every |
| 656 |
ECHO_REPLY received in reply, a backspace is printed. This |
| 657 |
provides a rapid display of how many packets are being dropped. |
| 658 |
Only the super-user may use this option. This can be very hard on |
| 659 |
a network and should be used with caution. |
| 660 |
|
| 661 |
‘--ip-timestamp=FLAG’ |
| 662 |
Include IP option Timestamp in transmitted packets. The value FLAG |
| 663 |
is either ‘tsonly’, which only records up to nine time stamps, or |
| 664 |
‘tsaddr’, which records IP addresses as well as time stamps, but |
| 665 |
for at most four hosts. |
| 666 |
|
| 667 |
‘-l N’ |
| 668 |
‘--preload=N’ |
| 669 |
If N is specified, ping sends that many packets as fast as possible |
| 670 |
before falling into its normal mode of operation. |
| 671 |
|
| 672 |
‘-p PAT’ |
| 673 |
‘--pattern=PAT’ |
| 674 |
You may specify up to 16 pad bytes to fill out the packet you send. |
| 675 |
This is useful for diagnosing data-dependent problems in a network. |
| 676 |
For example, ‘-p ff’ will cause the sent packet to be filled with |
| 677 |
all ones. |
| 678 |
|
| 679 |
‘-q’ |
| 680 |
‘--quiet’ |
| 681 |
Do not print timing for each transmitted packet. |
| 682 |
‘-R’ |
| 683 |
‘--route’ |
| 684 |
Record route. Includes the ‘RECORD_ROUTE’ field in the |
| 685 |
ECHO_REQUEST packet and displays the route buffer on returned |
| 686 |
packets. Note that the IP header is only large enough for nine |
| 687 |
such routes. Many hosts ignore or discard this option. |
| 688 |
|
| 689 |
‘-s N’ |
| 690 |
‘--size=N’ |
| 691 |
Specifies the number of data bytes to be sent. The default is 56, |
| 692 |
which translates into 64 ICMP data bytes, taking the 8 bytes of |
| 693 |
ICMP header data into account. |
| 694 |
|
| 695 |
|
| 696 |
File: inetutils.info, Node: Fault isolation, Next: Duplicate and damaged packets, Prev: Ping options, Up: ping invocation |
| 697 |
|
| 698 |
7.2 Using ping for network fault isolation |
| 699 |
========================================== |
| 700 |
|
| 701 |
When using ‘ping’ for fault isolation, it should first be run on the |
| 702 |
local host, to verify that the local network interface is up and |
| 703 |
running. Then, hosts and gateways further and further away should be |
| 704 |
pinged. Round-trip times and packet loss statistics are computed. If |
| 705 |
duplicate packets are received, they are not included in the packet loss |
| 706 |
calculation, although the round trip time of these packets is used in |
| 707 |
calculating the minimum/average/maximum round-trip time numbers. When |
| 708 |
the specified number of packets have been sent (and received) or if the |
| 709 |
program is terminated with a ‘SIGINT’, a brief summary is displayed. |
| 710 |
|
| 711 |
This program is intended for use in network testing, measurement and |
| 712 |
management. Because of the load it can impose on the network, it is |
| 713 |
unwise to use ping during normal operations or from automated scripts. |
| 714 |
|
| 715 |
|
| 716 |
File: inetutils.info, Node: Duplicate and damaged packets, Next: Data patterns, Prev: Fault isolation, Up: ping invocation |
| 717 |
|
| 718 |
7.3 Duplicate and damaged packets |
| 719 |
================================= |
| 720 |
|
| 721 |
Ping will report duplicate and damaged packets. Duplicate packets |
| 722 |
should never occur, and seem to be caused by inappropriate link-level |
| 723 |
retransmissions. Duplicates may occur in many situations and are rarely |
| 724 |
(if ever) a good sign, although the presence of low levels of duplicates |
| 725 |
may not always be cause for alarm. |
| 726 |
|
| 727 |
Damaged packets are obviously serious cause for alarm and often |
| 728 |
indicate broken hardware somewhere in the ping packet's path (in the |
| 729 |
network or in the hosts). |
| 730 |
|
| 731 |
|
| 732 |
File: inetutils.info, Node: Data patterns, Next: TTL details, Prev: Duplicate and damaged packets, Up: ping invocation |
| 733 |
|
| 734 |
7.4 Trying different data patterns |
| 735 |
================================== |
| 736 |
|
| 737 |
The (inter)network layer should never treat packets differently |
| 738 |
depending on the data contained in the data portion. Unfortunately, |
| 739 |
data-dependent problems have been known to sneak into networks and |
| 740 |
remain undetected for long periods of time. In many cases the |
| 741 |
particular pattern that will have problems is something that doesn't |
| 742 |
have sufficient "transitions", such as all ones or all zeros, or a |
| 743 |
pattern right at the edge, such as almost all zeros. It isn't |
| 744 |
necessarily enough to specify a data pattern of all zeros (for example) |
| 745 |
on the command line because the pattern that is of interest is at the |
| 746 |
data link level, and the relationship between what you type and what the |
| 747 |
controllers transmit can be complicated. |
| 748 |
|
| 749 |
This means that if you have a data-dependent problem you will |
| 750 |
probably have to do a lot of testing to find it. If you are lucky, you |
| 751 |
may manage to find a file that either can't be sent across your network |
| 752 |
or that takes much longer to transfer than other similar length files. |
| 753 |
You can then examine this file for repeated patterns that you can test |
| 754 |
using the ‘-p’ option of ping. |
| 755 |
|
| 756 |
|
| 757 |
File: inetutils.info, Node: TTL details, Next: Further remarks, Prev: Data patterns, Up: ping invocation |
| 758 |
|
| 759 |
7.5 TTL details |
| 760 |
=============== |
| 761 |
|
| 762 |
The TTL field, “Time To Live”, of an IP packet represents the maximum |
| 763 |
number of IP routers that the packet can go through before being |
| 764 |
discarded. In current practice you can expect each router on the |
| 765 |
Internet to decrement the TTL field by exactly one. |
| 766 |
|
| 767 |
The TCP/IP specification states that the TTL field of a new TCP |
| 768 |
packet should be set to 60, but many systems use smaller values (4.3BSD |
| 769 |
used 30 and 4.2BSD used 15). |
| 770 |
|
| 771 |
The maximum possible value of this field is 255, and most UNIX |
| 772 |
systems set the TTL field of ICMP (type ‘ECHO_REQUEST’) packets to 255. |
| 773 |
This is why you will find you can ping some hosts, but not reach them |
| 774 |
with ‘telnet’ or ‘ftp’. |
| 775 |
|
| 776 |
During normal operation, ‘ping’ prints the TTL value for every packet |
| 777 |
it receives. When a remote system receives an ICMP packet, it can do |
| 778 |
one of three things to the TTL field in its response packet: |
| 779 |
|
| 780 |
• Not to change it. This is what Berkeley UNIX systems did before |
| 781 |
the 4.3BSD-Tahoe release. In this case the TTL value in the |
| 782 |
received packet will be 255 minus the number of routers in the |
| 783 |
round-trip path. |
| 784 |
|
| 785 |
• Set it to 255. This is what current Berkeley UNIX systems do. In |
| 786 |
this case the TTL value in the received packet will be 255 minus |
| 787 |
the number of routers in the path from the remote system to the |
| 788 |
pinging host. |
| 789 |
|
| 790 |
• Set it to some other value. Some machines use the same value for |
| 791 |
ICMP packets that they use for TCP packets, for example either 30 |
| 792 |
or 60. Others may use completely arbitrary values. |
| 793 |
|
| 794 |
|
| 795 |
File: inetutils.info, Node: Further remarks, Prev: TTL details, Up: ping invocation |
| 796 |
|
| 797 |
7.6 Further observations |
| 798 |
======================== |
| 799 |
|
| 800 |
Many hosts and gateways ignore the ‘RECORD_ROUTE’ field, since the |
| 801 |
maximum IP header length is far to small to hold all the routes. There |
| 802 |
is not much that can be done about this. |
| 803 |
|
| 804 |
Flood pinging is not recommended in general, and flood pinging the |
| 805 |
broadcast address should only be done under very controlled conditions. |
| 806 |
|
| 807 |
Some BSD variants offer a kernel setting to inhibit all replies to |
| 808 |
ICMP_MASKREQ packets, but in general, Unices are designed either to |
| 809 |
answer the request with a valid netmask, or to drop the request, causing |
| 810 |
‘ping’ to wait for a timeout condition. |
| 811 |
|
| 812 |
|
| 813 |
File: inetutils.info, Node: ping6 invocation, Next: traceroute invocation, Prev: ping invocation, Up: Top |
| 814 |
|
| 815 |
8 ‘ping6’: Packets to IPv6 network hosts |
| 816 |
**************************************** |
| 817 |
|
| 818 |
‘ping6’ uses ICMPv6 datagrams to get a response from the chosen |
| 819 |
destination host. The most common use is to probe whether the remote |
| 820 |
system is responsive. Observe that this program only uses IPv6 |
| 821 |
datagrams. |
| 822 |
|
| 823 |
Each datagram, of type ‘ECHO_REQUEST’, carries some header |
| 824 |
information and some additional payload, usually a time stamp. Making a |
| 825 |
suitable choice of payload, it is possible to probe different host or |
| 826 |
router properties on the way as the emitted datagram travels to its |
| 827 |
destination. |
| 828 |
|
| 829 |
Synopsis: |
| 830 |
|
| 831 |
ping6 [OPTION...] HOST |
| 832 |
|
| 833 |
Sending simple, timed echo requests is the standard use of ‘ping6’, but |
| 834 |
is by far not the only use case. |
| 835 |
|
| 836 |
This command is a close parallel to ‘ping’, except that it handles |
| 837 |
IPv6 and is thus not able to handle peculiarities of IPv4. |
| 838 |
|
| 839 |
8.1 Command line options |
| 840 |
======================== |
| 841 |
|
| 842 |
‘-c N’ |
| 843 |
‘--count=N’ |
| 844 |
Stop after sending and receiving answers to a total of N packets. |
| 845 |
|
| 846 |
‘-d’ |
| 847 |
‘--debug’ |
| 848 |
Set the SO_DEBUG option on the socket being used. |
| 849 |
|
| 850 |
‘-f’ |
| 851 |
‘--flood’ |
| 852 |
Flood ping. Outputs packets as fast as they come back, or one |
| 853 |
hundred times per second, whichever is more. For every |
| 854 |
ECHO_REQUEST packet sent, a period ‘.’ is printed, while for every |
| 855 |
ECHO_REPLY received in reply, a backspace is printed. |
| 856 |
|
| 857 |
This provides a rapid display of how many packets are being |
| 858 |
dropped. Only the super-user may use this option. This mode can |
| 859 |
be very hard on a network. It should be used with caution! |
| 860 |
|
| 861 |
‘--hoplimit=N’ |
| 862 |
Limit maximal distance to N. Acceptable values are 1 to 255, |
| 863 |
inclusive. |
| 864 |
|
| 865 |
‘-i N’ |
| 866 |
‘--interval=N’ |
| 867 |
Wait N seconds until sending next packet. The default is to wait |
| 868 |
for one second between packets. This option is incompatible with |
| 869 |
the option ‘-f’. |
| 870 |
|
| 871 |
‘-l N’ |
| 872 |
‘--preload=N’ |
| 873 |
Sends N packets as fast as possible before falling back to the |
| 874 |
normal mode of operation. |
| 875 |
|
| 876 |
‘-n’ |
| 877 |
‘--numeric’ |
| 878 |
Numeric output only. No attempt will be made to resolve symbolic |
| 879 |
names for host addresses. |
| 880 |
|
| 881 |
‘-p PATTERN’ |
| 882 |
‘--pattern=PATTERN’ |
| 883 |
Up to 16 hexadecimal pad bytes are given as PATTERN. These are use |
| 884 |
for filling out the packets you send. This option is useful for |
| 885 |
diagnosing data-dependent problems within a network. As an |
| 886 |
example, ‘-p ff’ will cause the sent packets to have payloads with |
| 887 |
every bit set to one. |
| 888 |
|
| 889 |
‘-q’ |
| 890 |
‘--quiet’ |
| 891 |
Do not print timing result of each transmitted packet. |
| 892 |
|
| 893 |
‘-r’ |
| 894 |
‘--ignore-routing’ |
| 895 |
Bypass the normal routing tables and send directly to a host on an |
| 896 |
attached network. If the host is not on a directly attached |
| 897 |
network, an error is returned. This option can be used to ping a |
| 898 |
local host through an interface, for which there is no assigned |
| 899 |
route, such as when the interface was dropped by ‘routed’. |
| 900 |
|
| 901 |
‘-s N’ |
| 902 |
‘--size=N’ |
| 903 |
Specifies the number of data bytes to be sent. The default is 56, |
| 904 |
which translates into 64 ICMP data bytes, taking the 8 bytes of |
| 905 |
ICMP header data into account. |
| 906 |
|
| 907 |
‘-T NUM’ |
| 908 |
‘--tos=NUM’ |
| 909 |
Set the traffic class to NUM on transmitted packets. |
| 910 |
|
| 911 |
‘--ttl=N’ |
| 912 |
Synonym for ‘--hoplimit’. |
| 913 |
|
| 914 |
‘-v’ |
| 915 |
‘--verbose’ |
| 916 |
Produce more verbose output, giving more statistics. |
| 917 |
|
| 918 |
‘-w N’ |
| 919 |
‘--timeout=N’ |
| 920 |
Stop after N seconds. |
| 921 |
|
| 922 |
The documentation of ‘ping’ provides several pieces of information, |
| 923 |
and discussions, relevant to the use of ‘ping6’. Keep in mind, though, |
| 924 |
that the differing address family causes some discrepancy. *Note ping |
| 925 |
invocation::. |
| 926 |
|
| 927 |
|
| 928 |
File: inetutils.info, Node: traceroute invocation, Next: whois invocation, Prev: ping6 invocation, Up: Top |
| 929 |
|
| 930 |
9 ‘traceroute’: Trace the route to a host |
| 931 |
***************************************** |
| 932 |
|
| 933 |
‘traceroute’ prints a trace of the route IP packets are travelling to a |
| 934 |
remote host. |
| 935 |
|
| 936 |
Synopsis: |
| 937 |
|
| 938 |
traceroute [OPTION...] HOST |
| 939 |
|
| 940 |
9.1 Command line options |
| 941 |
======================== |
| 942 |
|
| 943 |
‘-f NUM’ |
| 944 |
‘--first-hop=NUM’ |
| 945 |
Set the initial hop distance to NUM, instead of the default 1. |
| 946 |
This immediately allows probing packets to sense routing properties |
| 947 |
closer to the target host, skipping routers close to the local |
| 948 |
host. Quicker analysis of problems known to lie at some routing |
| 949 |
distance is the outcome. |
| 950 |
|
| 951 |
‘-g GATES’ |
| 952 |
‘--gateways=GATES’ |
| 953 |
Set intermediary hosts used in loose source routing. The argument |
| 954 |
GATES is a list of gateways, using space, comma, or semicolon as |
| 955 |
separators. These hosts must be traversed in the given order |
| 956 |
before the intended host receives any datagram. At most eight host |
| 957 |
names or addresses may be specified. Multiple uses of ‘-g’ produce |
| 958 |
a concatenated list. |
| 959 |
|
| 960 |
‘-I’ |
| 961 |
‘--icmp’ |
| 962 |
Use ICMP ECHO datagrams for probing the remote host. |
| 963 |
|
| 964 |
‘-m NUM’ |
| 965 |
‘--max-hop=NUM’ |
| 966 |
Set the maximum time-to-live allowed for probing. In other words, |
| 967 |
stop probing when the hop distance is in excess of NUM. The |
| 968 |
default limit is 64. |
| 969 |
|
| 970 |
‘-M METHOD’ |
| 971 |
‘--type=METHOD’ |
| 972 |
Use METHOD as carrier packets for traceroute operations. Supported |
| 973 |
choices are ‘icmp’ and ‘udp’, where ‘udp’ is the default type. |
| 974 |
|
| 975 |
‘-p PORT’ |
| 976 |
‘--port=PORT’ |
| 977 |
Set destination port of target to PORT. The default value is |
| 978 |
33434. |
| 979 |
|
| 980 |
‘-q NUM’ |
| 981 |
‘--tries=NUM’ |
| 982 |
Send a total of NUM probe packets per hop, defaulting to 3. |
| 983 |
|
| 984 |
‘--resolve-hostnames’ |
| 985 |
Attempt to resolve all addresses as hostnames. |
| 986 |
|
| 987 |
‘-t NUM’ |
| 988 |
‘--tos=NUM’ |
| 989 |
Set type-of-service, TOS field, to NUM on transmitted packets. |
| 990 |
|
| 991 |
‘-w NUM’ |
| 992 |
‘--wait=NUM’ |
| 993 |
Set timeout in seconds, within which a returning response packet is |
| 994 |
accepted as such. Default waiting time is three seconds. |
| 995 |
|
| 996 |
9.2 Diagnostic tokens |
| 997 |
===================== |
| 998 |
|
| 999 |
During execution, ‘traceroute’ sends three datagrams for each value for |
| 1000 |
the TTL field, printing a diagnostic line of output for these. The TTL |
| 1001 |
field is then steadily increased until the intended host responds, or |
| 1002 |
some intermediary gateway returns a datagram to the effect that the |
| 1003 |
target cannot be reached due to one reason or another. |
| 1004 |
|
| 1005 |
Each line of output displays a sequence number, followed by |
| 1006 |
diagnostic annotation. Any responding host has its address printed |
| 1007 |
without repetition, together with a measured timing. In case there is |
| 1008 |
no response within a time period of three seconds, an asterisque ‘*’ is |
| 1009 |
printed. |
| 1010 |
|
| 1011 |
When an intermediate router responds with an exceptional state, the |
| 1012 |
time elapsed since emitting the original datagram is printed, followed |
| 1013 |
by an additional short hand hint of the reason: |
| 1014 |
|
| 1015 |
‘!F’ |
| 1016 |
Fragmentation needed by gateway. |
| 1017 |
|
| 1018 |
‘!H’ |
| 1019 |
Host not reachable from gateway. |
| 1020 |
|
| 1021 |
‘!N’ |
| 1022 |
Network not reachable from gateway. |
| 1023 |
|
| 1024 |
‘!P’ |
| 1025 |
Protocol not usable at host, or within network. |
| 1026 |
|
| 1027 |
‘!S’ |
| 1028 |
Source routing failed at gateway. |
| 1029 |
|
| 1030 |
‘!T’ |
| 1031 |
Host or network not reachable for stated type of service, TOS. |
| 1032 |
|
| 1033 |
‘!U’ |
| 1034 |
Isolated host, not reachable. |
| 1035 |
|
| 1036 |
‘!X’ |
| 1037 |
Forbidden by remote administration. |
| 1038 |
|
| 1039 |
|
| 1040 |
File: inetutils.info, Node: whois invocation, Next: ftp invocation, Prev: traceroute invocation, Up: Top |
| 1041 |
|
| 1042 |
10 ‘whois’: User interface to WHOIS data bases. |
| 1043 |
*********************************************** |
| 1044 |
|
| 1045 |
The functionality of a world wide Internet is dependent on stored node |
| 1046 |
information of different kinds. Registrars keep much relevant material |
| 1047 |
in WHOIS data bases. This utility ‘whois’ is able to query those |
| 1048 |
sources for general and for particular properties of most domains. |
| 1049 |
|
| 1050 |
For many domains there are names of suitable data base servers hard |
| 1051 |
coded into ‘whois’, ready to query for domain relevant information. |
| 1052 |
Since servers' names do change from time to time, this utility might |
| 1053 |
occasionally need some guidance using a suitable command line option. |
| 1054 |
|
| 1055 |
Synopsis: |
| 1056 |
|
| 1057 |
whois [OPTION...] OBJECT... |
| 1058 |
|
| 1059 |
10.1 Command line options |
| 1060 |
========================= |
| 1061 |
|
| 1062 |
‘-a’ |
| 1063 |
Search all data bases. |
| 1064 |
|
| 1065 |
‘-F’ |
| 1066 |
Fast and raw output. Implies ‘-r’. |
| 1067 |
|
| 1068 |
‘-g SOURCE:FIRST-LAST’ |
| 1069 |
Find updates for an object from provider SOURCE, starting from the |
| 1070 |
version with serial key FIRST, and ending with serial key LAST. |
| 1071 |
|
| 1072 |
‘-h HOST’ |
| 1073 |
‘--server=HOST’ |
| 1074 |
Connect to server HOST. |
| 1075 |
|
| 1076 |
‘-H’ |
| 1077 |
Hide legal disclaimers. |
| 1078 |
|
| 1079 |
‘-i ATTR[,ATTR2...]’ |
| 1080 |
Do an inverse lookup for specified attributes. Use a comma |
| 1081 |
separated list for multiple attributes. |
| 1082 |
|
| 1083 |
‘-l’ |
| 1084 |
One level less specific lookup. Applies to RPSL only. |
| 1085 |
|
| 1086 |
‘-L’ |
| 1087 |
Find all less specific matches. |
| 1088 |
|
| 1089 |
‘-m’ |
| 1090 |
Find more specific matches, one level deeper. |
| 1091 |
|
| 1092 |
‘-M’ |
| 1093 |
Find all more specific matches. |
| 1094 |
|
| 1095 |
‘-p PORT’ |
| 1096 |
Connect to server port PORT. |
| 1097 |
|
| 1098 |
‘-q {version|sources}’ |
| 1099 |
Query specified server info. Applies to RPSL only. |
| 1100 |
|
| 1101 |
‘-r’ |
| 1102 |
Turn off recursive lookups. |
| 1103 |
|
| 1104 |
‘-R’ |
| 1105 |
Force output to show local copy of the domain object, even if it |
| 1106 |
contains a referral. |
| 1107 |
|
| 1108 |
‘-s SOURCE[,SOURCE2...]’ |
| 1109 |
Search the data base at SOURCE. A comma separated list queries |
| 1110 |
multiple providers. |
| 1111 |
|
| 1112 |
‘-S’ |
| 1113 |
Tell server to refrain from syntactic sugar. |
| 1114 |
|
| 1115 |
‘-t TYPE’ |
| 1116 |
Request a template for objects of type TYPE. Use the value ‘all’ |
| 1117 |
for a list of possible types. |
| 1118 |
|
| 1119 |
‘-T TYPE[,TYPE2...]’ |
| 1120 |
Search only for objects of type TYPE. A comma separated list |
| 1121 |
allows for multiple types. |
| 1122 |
|
| 1123 |
‘-V’ |
| 1124 |
‘--verbose’ |
| 1125 |
Verbosely explain all actions taken. |
| 1126 |
|
| 1127 |
‘-x’ |
| 1128 |
Search only for exact matches. Applicable only to RPSL. |
| 1129 |
|
| 1130 |
10.2 Environment variables |
| 1131 |
========================== |
| 1132 |
|
| 1133 |
‘whois’ holds an internal list of information servers and their assigned |
| 1134 |
data bases. Queries are examined against this list to select the most |
| 1135 |
plausible server, but the hint can always be overruled on the command |
| 1136 |
line by use of the option ‘-h’. If neither of these have a say, then |
| 1137 |
the default server to ask is ‘whois.internic.net’, but this name is in |
| 1138 |
turn overruled by a server name in the environment variable |
| 1139 |
‘WHOIS_SERVER’. |
| 1140 |
|
| 1141 |
‘LANG’ |
| 1142 |
When the server ‘whois.nic.ad.jp’ is queried, and only then, any |
| 1143 |
non-Japanese locale in ‘LANG’ will ask the server to reply with |
| 1144 |
English text, not Japanese. |
| 1145 |
|
| 1146 |
‘WHOIS_HIDE’ |
| 1147 |
When set, the effect on ‘whois’ is as if the option ‘-H’ had been |
| 1148 |
given. |
| 1149 |
|
| 1150 |
‘WHOIS_SERVER’ |
| 1151 |
Data base server to query when internal hinting is inconclusive. |
| 1152 |
When unset, ‘whois.internic.net’ is used as default server. |
| 1153 |
|
| 1154 |
|
| 1155 |
File: inetutils.info, Node: ftp invocation, Next: rcp invocation, Prev: whois invocation, Up: Top |
| 1156 |
|
| 1157 |
11 ‘ftp’: FTP client |
| 1158 |
******************** |
| 1159 |
|
| 1160 |
‘ftp’ is the user interface to FTP, the File Transfer Protocol. The |
| 1161 |
program allows a user to transfer files to and from a remote network |
| 1162 |
site. |
| 1163 |
|
| 1164 |
Synopsis: |
| 1165 |
|
| 1166 |
ftp [OPTION...] [HOST [PORT]] |
| 1167 |
pftp [OPTION...] [HOST [PORT]] |
| 1168 |
|
| 1169 |
ftp [OPTION...] USER@HOST [PORT] |
| 1170 |
pftp [OPTION...] USER@HOST [PORT] |
| 1171 |
|
| 1172 |
The alternate name ‘pftp’ is starting in passive mode, but is otherwise |
| 1173 |
identical to ‘ftp’. |
| 1174 |
|
| 1175 |
The client host with which ‘ftp’ is to communicate may be specified |
| 1176 |
on the command line. If this is done, ‘ftp’ will immediately attempt to |
| 1177 |
establish a connection to the FTP server running on that host. |
| 1178 |
Optionally, a remote user name can be specified at will. Otherwise, the |
| 1179 |
program will start a command interpreter and will await further |
| 1180 |
instructions from the user. Commands can either be entered |
| 1181 |
interactively, or piped as a batched job read from standard input. |
| 1182 |
‘ftp’ is able to distinguish between these two modes of operation. |
| 1183 |
|
| 1184 |
* Menu: |
| 1185 |
|
| 1186 |
* Ftp options:: |
| 1187 |
* Ftp commands:: |
| 1188 |
* Ftp environment:: |
| 1189 |
* Aborting a file transfer:: |
| 1190 |
* File naming conventions:: |
| 1191 |
* File transfer parameters:: |
| 1192 |
* The .netrc file:: |
| 1193 |
|
| 1194 |
|
| 1195 |
File: inetutils.info, Node: Ftp options, Next: Ftp commands, Up: ftp invocation |
| 1196 |
|
| 1197 |
11.1 Command line options |
| 1198 |
========================= |
| 1199 |
|
| 1200 |
Many command line options have counterparts among the commands handled |
| 1201 |
by the internal interpreter. |
| 1202 |
|
| 1203 |
‘-4’ |
| 1204 |
‘--ipv4’ |
| 1205 |
Initially set addressing to IPv4 only. |
| 1206 |
|
| 1207 |
‘-6’ |
| 1208 |
‘--ipv6’ |
| 1209 |
Initially set addressing to IPv6 only. |
| 1210 |
|
| 1211 |
‘-A’ |
| 1212 |
‘--active’ |
| 1213 |
Enable active mode transfer. Default mode for ‘ftp’. |
| 1214 |
|
| 1215 |
‘-d’ |
| 1216 |
‘--debug’ |
| 1217 |
Enable debugging output and possibly also socket debugging. |
| 1218 |
|
| 1219 |
‘-e’ |
| 1220 |
‘--no-edit’ |
| 1221 |
Disables the editing of commands. This is default setting for |
| 1222 |
batch mode, without a TTY, or when the environment variable ‘TERM’ |
| 1223 |
is not set or its value is ‘dumb’. |
| 1224 |
|
| 1225 |
‘-g’ |
| 1226 |
‘--no-glob’ |
| 1227 |
Disables file name globbing. |
| 1228 |
|
| 1229 |
‘-i’ |
| 1230 |
‘--no-prompt’ |
| 1231 |
Turns off interactive prompting during multiple file transfers. |
| 1232 |
|
| 1233 |
‘-N NETRC’ |
| 1234 |
‘--netrc=NETRC’ |
| 1235 |
Set a preferred location of the ‘.netrc’ file, thus overriding any |
| 1236 |
environment setting in ‘NETRC’, as well as the default location |
| 1237 |
‘$HOME/.netrc’, *note The .netrc file::. |
| 1238 |
|
| 1239 |
‘-n’ |
| 1240 |
‘--no-login’ |
| 1241 |
Restrains ‘ftp’ from attempting “auto-login” upon initial |
| 1242 |
connection. If auto-login is enabled, ‘ftp’ will check the |
| 1243 |
‘.netrc’ (*note The .netrc file::) file in the user's home |
| 1244 |
directory for an entry describing an account on the remote machine. |
| 1245 |
If no entry exists, ‘ftp’ will prompt for the remote machine login |
| 1246 |
name (default is the user identity on the local machine), and, if |
| 1247 |
necessary, prompt for a password and an account with which to |
| 1248 |
login. |
| 1249 |
|
| 1250 |
‘-p’ |
| 1251 |
‘--passive’ |
| 1252 |
Enable passive mode transfer. Default mode when invoked as ‘pftp’. |
| 1253 |
|
| 1254 |
‘--prompt[=PROMPT]’ |
| 1255 |
Print a command-line prompt, even if not on a tty. If PROMPT is |
| 1256 |
supplied, its value is used instead of the default ‘ftp> ’. |
| 1257 |
Notice, that the argument is optional. |
| 1258 |
|
| 1259 |
‘-t’ |
| 1260 |
‘--trace’ |
| 1261 |
Enable packet tracing (not implemented). |
| 1262 |
|
| 1263 |
‘-v’ |
| 1264 |
‘--verbose’ |
| 1265 |
Start in verbose mode, printing informational messages. This is |
| 1266 |
default for interactive mode. |
| 1267 |
|
| 1268 |
|
| 1269 |
File: inetutils.info, Node: Ftp commands, Next: Ftp environment, Prev: Ftp options, Up: ftp invocation |
| 1270 |
|
| 1271 |
11.2 Commands interpreted by ‘ftp’ |
| 1272 |
================================== |
| 1273 |
|
| 1274 |
When ‘ftp’ is awaiting commands from the user, a prompt is displayed. |
| 1275 |
The default string is ‘ftp>’, but it can been changed with a command |
| 1276 |
line option, perhaps to enhance uniqueness while recording a session. |
| 1277 |
|
| 1278 |
Be aware that correct execution of many commands depends upon a |
| 1279 |
proper behavior of the remote server. The following commands are |
| 1280 |
recognized by ‘ftp’ itself. Command names can be abbreviated to the |
| 1281 |
shortest unique string with identical beginning. |
| 1282 |
|
| 1283 |
‘! [COMMAND [ARGS]]’ |
| 1284 |
Invoke an interactive shell on the local machine. If there are |
| 1285 |
arguments, the first is taken to be a command to execute directly, |
| 1286 |
with the rest of the arguments as its arguments. |
| 1287 |
|
| 1288 |
‘$ MACRO-NAME [ARGS]’ |
| 1289 |
Execute the macro MACRO-NAME that was defined with the macdef |
| 1290 |
command. Arguments are passed to the macro unglobbed. |
| 1291 |
|
| 1292 |
‘account [PASSWD]’ |
| 1293 |
Supply a supplemental password required by a remote system for |
| 1294 |
access to resources, once a login has been successfully completed. |
| 1295 |
If no argument is included, the user will be prompted for an |
| 1296 |
account password in non-echoing input mode. |
| 1297 |
|
| 1298 |
‘append LOCAL-FILE [REMOTE-FILE]’ |
| 1299 |
Append a local file to a file on the remote machine. If |
| 1300 |
REMOTE-FILE is left unspecified, the local file name is used in |
| 1301 |
naming the remote file after being altered by any ‘ntrans’ or |
| 1302 |
‘nmap’ setting. File transfer uses the current settings for type, |
| 1303 |
format, mode, and structure. |
| 1304 |
|
| 1305 |
‘ascii’ |
| 1306 |
Set the file transfer type to network ASCII. This is the default |
| 1307 |
type, except when two unices are communicating. |
| 1308 |
|
| 1309 |
‘bell’ |
| 1310 |
Arrange that a bell be sounded after each file transfer command is |
| 1311 |
completed. |
| 1312 |
|
| 1313 |
‘binary’ |
| 1314 |
Set the file transfer type to support binary image transfer. This |
| 1315 |
transfer type is selected during initial handshake, should the |
| 1316 |
client on a Unix system recognize that the server is also running |
| 1317 |
on a Unix system. |
| 1318 |
|
| 1319 |
‘bye’ |
| 1320 |
‘quit’ |
| 1321 |
Terminate the FTP session with the remote server and exit ‘ftp’. |
| 1322 |
An end of file will also terminate the session and exit. |
| 1323 |
|
| 1324 |
‘case’ |
| 1325 |
Toggle the remote computer's use of letter case mapping during |
| 1326 |
‘mget’ commands. When ‘case’ is ‘on’, a file name at the remote |
| 1327 |
site whose every letter appear in upper case, will be renamed in |
| 1328 |
such a way that all letters are changed to lower case for a local |
| 1329 |
copy of the same file. The default setting is ‘off’, |
| 1330 |
|
| 1331 |
‘cd REMOTE-DIRECTORY’ |
| 1332 |
Change the working directory on the remote machine to |
| 1333 |
REMOTE-DIRECTORY. |
| 1334 |
|
| 1335 |
‘cdup’ |
| 1336 |
Change the remote machine's working directory to the parent of the |
| 1337 |
current working directory. |
| 1338 |
|
| 1339 |
‘chmod MODE FILE-NAME’ |
| 1340 |
Change the access permission of the file FILE-NAME on the remote |
| 1341 |
system to MODE. |
| 1342 |
|
| 1343 |
‘close’ |
| 1344 |
‘disconnect’ |
| 1345 |
Terminate the FTP session with the present remote server, and |
| 1346 |
return to the command interpreter. Any defined macros are erased. |
| 1347 |
|
| 1348 |
‘cr’ |
| 1349 |
Toggle carriage return stripping during ASCII type file retrieval. |
| 1350 |
Records are denoted by a carriage return/linefeed sequence during |
| 1351 |
ASCII type file transfer. When ‘cr’ is ‘on’ (the default), |
| 1352 |
carriage returns are stripped from this sequence to conform with |
| 1353 |
the UNIX single linefeed record delimiter. Records on non-UNIX |
| 1354 |
remote systems may contain single linefeeds; when an ASCII type |
| 1355 |
transfer is made, these linefeeds may be distinguished from a |
| 1356 |
record delimiter only when ‘cr’ is ‘off’. |
| 1357 |
|
| 1358 |
‘delete REMOTE-FILE’ |
| 1359 |
Delete the file REMOTE-FILE on the remote machine. |
| 1360 |
|
| 1361 |
‘debug [DEBUG-VALUE]’ |
| 1362 |
Toggle debugging mode. If an optional DEBUG-VALUE is specified it |
| 1363 |
is used to set the debugging level. When debugging is on, ‘ftp’ |
| 1364 |
prints each command sent to the remote machine, preceded by the |
| 1365 |
string ‘-->’. |
| 1366 |
|
| 1367 |
‘dir [REMOTE-DIRECTORY] [LOCAL-FILE]’ |
| 1368 |
Print a listing of the contents in the directory REMOTE-DIRECTORY, |
| 1369 |
and, optionally, place the output in LOCAL-FILE. If interactive |
| 1370 |
prompting is set, ‘ftp’ will prompt the user to verify that the |
| 1371 |
last argument is the intended local file to receive output. If no |
| 1372 |
directory is specified, the current working directory on the remote |
| 1373 |
machine is used. If no local file is specified, or if LOCAL-FILE |
| 1374 |
is a dash ‘-’, then output is displayed on the terminal. |
| 1375 |
|
| 1376 |
‘epsv4’ |
| 1377 |
Toggle the use of EPSV/EPRT for IPv4 addressing. Default is off. |
| 1378 |
|
| 1379 |
‘form FORMAT’ |
| 1380 |
Set the file transfer form to FORMAT. The only supported format is |
| 1381 |
‘non-print’. |
| 1382 |
|
| 1383 |
‘get REMOTE-FILE [LOCAL-FILE]’ |
| 1384 |
‘recv REMOTE-FILE [LOCAL-FILE]’ |
| 1385 |
Retrieve the REMOTE-FILE and store it on the local machine. If a |
| 1386 |
local file name is not specified, the local copy is given the same |
| 1387 |
name as is stated for the remote original, subject to alteration by |
| 1388 |
the current ‘case’, ‘ntrans’, and ‘nmap’ settings. The current |
| 1389 |
settings for ‘type’, ‘form’, ‘mode’, and ‘structure’ are effective |
| 1390 |
during file transfer. |
| 1391 |
|
| 1392 |
‘glob’ |
| 1393 |
Toggle file name expansion for ‘mdelete’, ‘mget’, and ‘mput’. If |
| 1394 |
globbing is turned off with ‘glob’, the file name arguments are |
| 1395 |
taken literally and are not expanded. Globbing for ‘mput’ is done |
| 1396 |
as in ‘csh’ syntax. For ‘mdelete’ and ‘mget’, each remote file |
| 1397 |
name is expanded separately on the remote machine and the lists are |
| 1398 |
not merged. Expansion of a directory name is likely to be |
| 1399 |
different from expansion of the name of an ordinary file: the exact |
| 1400 |
result depends on the remote operating system and on the FTP |
| 1401 |
server, and can be previewed by issuing ‘mls remote-files -’. |
| 1402 |
|
| 1403 |
Note: ‘mget’ and ‘mput’ are not meant to transfer entire directory |
| 1404 |
subtrees of files. That can be achieved by transferring an already |
| 1405 |
created ‘tar’ or ‘cpio’ archive of the subtree, then making certain |
| 1406 |
that ‘ftp’ uses binary mode. |
| 1407 |
|
| 1408 |
‘hash [SIZE]’ |
| 1409 |
In the absence of an argument, toggle the state of hash-sign (‘#’) |
| 1410 |
printing after each transferred data block. The optional argument |
| 1411 |
selects the size of data blocks, and unconditionally activates |
| 1412 |
printing. The default size is 1024 bytes. For convenience, the |
| 1413 |
size can be written with postfix multipliers 'k', 'K', 'm', 'M', |
| 1414 |
and 'g', 'G', to specify kilobytes, Megabytes, and Gigabytes, |
| 1415 |
respectively. |
| 1416 |
|
| 1417 |
‘help [COMMAND]’ |
| 1418 |
‘? [COMMAND]’ |
| 1419 |
Print an informative message about the meaning of command. If no |
| 1420 |
argument is given, ‘ftp’ prints a list of the known commands. |
| 1421 |
|
| 1422 |
‘idle [SECONDS]’ |
| 1423 |
Set the inactivity timer on the remote server to SECONDS seconds. |
| 1424 |
If seconds is omitted, the current inactivity timer is printed. |
| 1425 |
|
| 1426 |
‘ipv4’ |
| 1427 |
Select IPv4 as the only addressing scheme. |
| 1428 |
|
| 1429 |
‘ipv6’ |
| 1430 |
Select IPv6 as the only addressing scheme. |
| 1431 |
|
| 1432 |
‘ipany’ |
| 1433 |
Allow IPv4 as well as IPv6 addressing. |
| 1434 |
|
| 1435 |
‘lcd [DIRECTORY]’ |
| 1436 |
Change the working directory on the local machine. If no directory |
| 1437 |
is specified, the user's home directory is used. |
| 1438 |
|
| 1439 |
‘lpwd’ |
| 1440 |
Print the name of the current working directory on the local |
| 1441 |
machine. |
| 1442 |
|
| 1443 |
‘ls [REMOTE-DIRECTORY] [LOCAL-FILE]’ |
| 1444 |
Print a listing of the contents of a directory on the remote |
| 1445 |
machine. The listing includes any system-dependent information |
| 1446 |
that the server chooses to include; for example, most UNIX systems |
| 1447 |
will produce output like the command ‘ls -l’ does. Use ‘nlist’ for |
| 1448 |
a simple file listing. |
| 1449 |
|
| 1450 |
If REMOTE-DIRECTORY is left unspecified, the current working |
| 1451 |
directory is used. With interactive prompting set, ‘ftp’ will |
| 1452 |
prompt the user to verify that the last argument is indeed the |
| 1453 |
intended local file for storing output. Should no local file be |
| 1454 |
specified, or if LOCAL-FILE is a dash ‘-’, then output is sent to |
| 1455 |
the terminal. |
| 1456 |
|
| 1457 |
‘macdef MACRO-NAME’ |
| 1458 |
Define a macro called MACRO-NAME, with subsequent lines as the |
| 1459 |
macro definition. A null line (consecutive newline characters in a |
| 1460 |
file, or carriage returns at a terminal) terminates macro input |
| 1461 |
mode. There is a limit of 16 macros and a total of 4096 characters |
| 1462 |
shared by all defined macros. Only the first eight characters in |
| 1463 |
MACRO-NAME are significant when determining which macro to execute. |
| 1464 |
Macros remain defined until a close command is executed. |
| 1465 |
|
| 1466 |
The macro processor interprets ‘$’ and ‘\’ as special characters. |
| 1467 |
A ‘$’ followed by a number (one or more digits) is replaced by the |
| 1468 |
corresponding argument on the macro's invocation command line. A |
| 1469 |
‘$’ followed by the letter ‘i’ tells the macro processor that the |
| 1470 |
macro is to perform a loop. On the first pass, ‘$i’ is replaced by |
| 1471 |
the first argument on the macro's invocation command line, while on |
| 1472 |
the second pass it is replaced by the second argument, and so |
| 1473 |
forth. Iteration proceeds until all arguments have been consumed. |
| 1474 |
|
| 1475 |
A backslash ‘\’ followed by any character is replaced by that |
| 1476 |
character. Use the backslash ‘\’ to prevent special treatment of |
| 1477 |
the dollar sign ‘$’, as was just explained. |
| 1478 |
|
| 1479 |
A macro can execute a macro, allowing recursion. In order to avoid |
| 1480 |
exhausting the stack and thus crashing ‘ftp’, the nesting depth of |
| 1481 |
macro execution is limited to a compile time constant. |
| 1482 |
|
| 1483 |
‘mdelete [REMOTE-FILES]’ |
| 1484 |
Delete all REMOTE-FILES on the remote machine. |
| 1485 |
|
| 1486 |
‘mdir REMOTE-FILES LOCAL-FILE’ |
| 1487 |
Like ‘dir’, except multiple remote files may be specified. If |
| 1488 |
interactive prompting is on, ‘ftp’ will prompt the user to verify |
| 1489 |
that the last argument is indeed the intended local file for |
| 1490 |
storing any output from ‘mdir’. |
| 1491 |
|
| 1492 |
‘mget REMOTE-FILES’ |
| 1493 |
Expand the REMOTE-FILES on the remote machine and execute a ‘get’ |
| 1494 |
for each file name thus produced. Resulting file names will then |
| 1495 |
be processed according to ‘case’, ‘ntrans’, and ‘nmap’ settings. |
| 1496 |
Files are transferred to the local working directory, which can be |
| 1497 |
changed with ‘lcd directory’; new local directories can be created |
| 1498 |
with ‘! mkdir directory’. |
| 1499 |
|
| 1500 |
‘mkdir DIRECTORY-NAME’ |
| 1501 |
Make a directory on the remote machine. |
| 1502 |
|
| 1503 |
‘mls REMOTE-FILES LOCAL-FILE’ |
| 1504 |
Like ‘nlist’, except multiple remote files may be specified, and |
| 1505 |
the LOCAL-FILE must be specified. If interactive prompting is on, |
| 1506 |
‘ftp’ will prompt the user to verify that the last argument is the |
| 1507 |
intended local file for storing output. A dash ‘-’ is accepted as |
| 1508 |
last argument without check! |
| 1509 |
|
| 1510 |
‘mode [MODE-NAME]’ |
| 1511 |
Set the file transfer mode to MODE-NAME. The default mode is |
| 1512 |
‘stream’, and it is also the only implemented mode. |
| 1513 |
|
| 1514 |
‘modtime FILE-NAME’ |
| 1515 |
Show the last modification time of the file on the remote machine. |
| 1516 |
|
| 1517 |
‘mput LOCAL-FILES’ |
| 1518 |
Consider the arguments to be local names and expand any wild card. |
| 1519 |
Execute a ‘put’ for each file in the resulting list. The remote |
| 1520 |
file names are then computed by use of ‘ntrans’ and ‘nmap’ |
| 1521 |
settings. |
| 1522 |
|
| 1523 |
‘newer FILE-NAME’ |
| 1524 |
Get the file only if the modification time of the remote file is |
| 1525 |
more recent than the file on the current system. If the file does |
| 1526 |
not exist on the current system, the remote file is considered |
| 1527 |
newer. In other respects, this command is identical to ‘get’. |
| 1528 |
|
| 1529 |
‘nlist [REMOTE-DIRECTORY] [LOCAL-FILE]’ |
| 1530 |
Print a list of the files in a directory on the remote machine. If |
| 1531 |
REMOTE-DIRECTORY is left unspecified, the current working directory |
| 1532 |
is used. If interactive prompting is on, ‘ftp’ will prompt the |
| 1533 |
user to verify that the last argument is the intended local file |
| 1534 |
for storing output. If no local file is specified, or if |
| 1535 |
LOCAL-FILE is ‘-’, the output is sent to the terminal. |
| 1536 |
|
| 1537 |
‘nmap [INPATTERN OUTPATTERN]’ |
| 1538 |
Set or unset the file name mapping mechanism. If no arguments are |
| 1539 |
specified, the file name mapping mechanism is unset. Name mapping |
| 1540 |
is applied during ‘mput’ and ‘put’ commands issued without a |
| 1541 |
specified remote target filename. It as also applied to local file |
| 1542 |
names during ‘mget’ and ‘get’ commands issued without local target |
| 1543 |
file name. This command is useful when connecting to a non-UNIX |
| 1544 |
remote computer with different file naming conventions or |
| 1545 |
practices. |
| 1546 |
|
| 1547 |
The mapping follows the pattern set by INPATTERN and OUTPATTERN. |
| 1548 |
The template INPATTERN is used on incoming filenames (which may |
| 1549 |
have already been processed according to the ‘ntrans’ and ‘case’ |
| 1550 |
settings). Variable templating is accomplished by including the |
| 1551 |
sequences ‘$1’, ‘$2’, ..., ‘$9’ in INPATTERN. Use ‘\’ to prevent |
| 1552 |
this special treatment of the character ‘$’. All other characters |
| 1553 |
are treated literally, and must be matched in a file name for |
| 1554 |
INPATTERN to bind substrings to variables. |
| 1555 |
|
| 1556 |
For example, take a pattern ‘$1.$2’ and a file name ‘mydata.data’. |
| 1557 |
Then ‘$1’ would have the value ‘mydata’, and ‘$2’ would be ‘data’. |
| 1558 |
|
| 1559 |
OUTPATTERN determines the final file name. The sequences ‘$1’ to |
| 1560 |
‘$9’ are replaced by any values bound to them by INPATTERN. A |
| 1561 |
special sequence ‘$0’ always contains the original filename. In |
| 1562 |
addition, a bracketted sequence ‘[SEQ1,SEQ2]’ expands to SEQ1 if |
| 1563 |
SEQ1 contains a non-empty string, and expands to SEQ2 otherwise. |
| 1564 |
For example, the command |
| 1565 |
|
| 1566 |
nmap $1.$2.$3 [$1,$2].[$2,file] |
| 1567 |
|
| 1568 |
would yield the output file name ‘myfile.data’ for input names |
| 1569 |
‘myfile.data’ and ‘myfile.data.old’, but produces ‘myfile.file’ |
| 1570 |
from the input ‘myfile’, and ‘myfile.myfile’ from ‘.myfile’. |
| 1571 |
|
| 1572 |
Spaces may be included in OUTPATTERN, but are easily removed: |
| 1573 |
|
| 1574 |
nmap $1 |sed "s/ *$//" > $1 |
| 1575 |
|
| 1576 |
Use a backslash ‘\’ to escape the characters ‘$’, ‘[’, ‘]’, and |
| 1577 |
‘,’. |
| 1578 |
|
| 1579 |
‘ntrans [INCHARS [OUTCHARS]]’ |
| 1580 |
Set or unset the filename character translation mechanism. If no |
| 1581 |
arguments are specified, the filename character translation |
| 1582 |
mechanism is unset. If arguments are specified, characters in |
| 1583 |
remote filenames are translated during ‘mput’ commands and ‘put’ |
| 1584 |
commands issued without a specified remote target filename. If |
| 1585 |
arguments are specified, characters in local filenames are |
| 1586 |
translated during ‘mget’ commands and ‘get’ commands issued without |
| 1587 |
a specified local target filename. This command is useful when |
| 1588 |
connecting to a non-UNIX remote computer with different file naming |
| 1589 |
conventions or practices. |
| 1590 |
|
| 1591 |
Characters in a filename matching a character in INCHARS are |
| 1592 |
replaced with the corresponding character in OUTCHARS. If the |
| 1593 |
character's position in INCHARS is longer than the length of |
| 1594 |
OUTCHARS, the character is deleted from the file name. |
| 1595 |
|
| 1596 |
‘open HOST [PORT]’ |
| 1597 |
‘open USER@HOST [PORT]’ |
| 1598 |
Establish a connection to the specified FTP server at HOST. An |
| 1599 |
optional port number may be supplied, in which case, ‘ftp’ will |
| 1600 |
attempt to contact the server at that specific TCP port. If the |
| 1601 |
‘autologin’ option is on (is so by default), ‘ftp’ will also |
| 1602 |
attempt to automatically log the user in to the FTP server. |
| 1603 |
|
| 1604 |
The second form of invocation sets the remote user name to USER, |
| 1605 |
which otherwise is taken as identical to the user identity owning |
| 1606 |
the local session. |
| 1607 |
|
| 1608 |
‘passive’ |
| 1609 |
Toggle passive mode. If passive mode is turned on (default is |
| 1610 |
off), the ‘ftp’ client will send a ‘PASV’ command for all data |
| 1611 |
connections instead of the usual ‘PORT’ command. The ‘PASV’ |
| 1612 |
command requests that the remote server open a port for the data |
| 1613 |
connection and return the address of that port. The remote server |
| 1614 |
listens on that port and the client connects to it. When using the |
| 1615 |
more traditional ‘PORT’ command, the client listens on a port and |
| 1616 |
sends that address to the remote server, who connects back to it. |
| 1617 |
Passive mode is useful when using ‘ftp’ through a gateway router or |
| 1618 |
host that controls the directionality of traffic. (Note that |
| 1619 |
though ‘ftp’ servers are required to support the ‘PASV’ command by |
| 1620 |
RFC 1123, some do not.) If ‘epsv4’ has been set to on, the client |
| 1621 |
will attempt ‘EPSV’ before ‘PASV’ for IPv4. As a last resort |
| 1622 |
‘LPSV’ is attempted. With IPv6 only ‘EPSV’ and ‘LPSV’ are |
| 1623 |
possible. |
| 1624 |
|
| 1625 |
‘prompt’ |
| 1626 |
Toggle interactive prompting. Interactive prompting occurs during |
| 1627 |
multiple file transfers to allow the user to selectively retrieve |
| 1628 |
or store files. If prompting is turned off (default is on), any |
| 1629 |
‘mget’ or ‘mput’ will transfer all files, and any ‘mdelete’ will |
| 1630 |
delete all files. |
| 1631 |
|
| 1632 |
‘proxy FTP-COMMAND’ |
| 1633 |
Execute an ‘ftp’ command on a secondary control connection. This |
| 1634 |
command allows simultaneous connection to two remote FTP servers |
| 1635 |
for transferring files between the two servers. The first proxy |
| 1636 |
command should be ‘open’, to establish the secondary control |
| 1637 |
connection. Enter the command ‘proxy ?’ to see other commands |
| 1638 |
usable for the secondary connection. The following commands behave |
| 1639 |
differently when prefaced by ‘proxy’: ‘open’ will not define new |
| 1640 |
macros during the auto-login process, ‘close’ will not erase |
| 1641 |
existing macro definitions, ‘get’ and ‘mget’ transfer files from |
| 1642 |
the host on the primary control connection to the host on the |
| 1643 |
secondary control connection, and ‘put’, ‘mput’, and ‘append’ |
| 1644 |
transfer files from the host on the secondary control connection to |
| 1645 |
the host on the primary control connection. |
| 1646 |
|
| 1647 |
Note that the protocol command ‘PASV’ must be understood by the |
| 1648 |
server on the secondary control connection for this kind of file |
| 1649 |
transfer to succeed. |
| 1650 |
|
| 1651 |
‘put LOCAL-FILE [REMOTE-FILE]’ |
| 1652 |
‘send LOCAL-FILE [REMOTE-FILE]’ |
| 1653 |
Store a local file on the remote machine. If REMOTE-FILE is left |
| 1654 |
unspecified, the local file name is used after processing according |
| 1655 |
to any ‘ntrans’ or ‘nmap’ settings in naming the remote file. File |
| 1656 |
transfer uses the current settings for type, format, mode, and |
| 1657 |
structure. |
| 1658 |
|
| 1659 |
‘pwd’ |
| 1660 |
Print the name of the current working directory on the remote |
| 1661 |
machine. |
| 1662 |
|
| 1663 |
‘quote ARG...’ |
| 1664 |
The arguments specified are sent, verbatim, to the remote FTP |
| 1665 |
server. |
| 1666 |
|
| 1667 |
‘reget REMOTE-FILE [LOCAL-FILE]’ |
| 1668 |
‘reget’ acts like ‘get’, except that if LOCAL-FILE exists and is |
| 1669 |
smaller than REMOTE-FILE, then LOCAL-FILE is presumed to be a |
| 1670 |
partially transferred copy of REMOTE-FILE and the transfer is |
| 1671 |
continued from the apparent point of failure. This command is |
| 1672 |
useful when transferring very large files over networks that are |
| 1673 |
prone to dropping connections. |
| 1674 |
|
| 1675 |
‘rhelp [COMMAND-NAME]’ |
| 1676 |
Request help from the remote FTP server. If COMMAND-NAME is |
| 1677 |
specified it is passed to the server as well. |
| 1678 |
|
| 1679 |
‘rstatus [FILE-NAME]’ |
| 1680 |
With no arguments, show status of remote machine. If filename is |
| 1681 |
specified, show status of FILE-NAME on remote machine. |
| 1682 |
|
| 1683 |
‘rename [FROM] [TO]’ |
| 1684 |
Rename the file FROM on the remote machine as TO. Name mapping |
| 1685 |
takes effect without TO. |
| 1686 |
|
| 1687 |
‘reset’ |
| 1688 |
Clear reply queue. This command re-synchronizes command/reply |
| 1689 |
sequencing with the remote FTP server. Resynchronization may be |
| 1690 |
necessary following a violation of the FTP protocol by the remote |
| 1691 |
server. |
| 1692 |
|
| 1693 |
‘restart MARKER’ |
| 1694 |
Restart the immediately following ‘get’ or ‘put’ at the indicated |
| 1695 |
marker. On UNIX systems, ‘marker’ is usually a byte offset into |
| 1696 |
the file. |
| 1697 |
|
| 1698 |
‘rmdir DIRECTORY-NAME’ |
| 1699 |
Delete a directory on the remote machine. |
| 1700 |
|
| 1701 |
‘runique’ |
| 1702 |
Toggle the storing of files on the local system with unique |
| 1703 |
filenames. If a file already exists with a name equal to the |
| 1704 |
intended local file name for a ‘get’ or ‘mget’ command, then a |
| 1705 |
string ‘.1’ is appended to the name. If the resulting name matches |
| 1706 |
another existing file, ‘.2’ is appended to the original name. If |
| 1707 |
this process continues up to ‘.99’, an error message is printed, |
| 1708 |
and the transfer does not take place. The generated unique |
| 1709 |
filename will be reported. Note that ‘runique’ will not affect |
| 1710 |
local files generated from a shell command. The default value is |
| 1711 |
off. |
| 1712 |
|
| 1713 |
‘sendport’ |
| 1714 |
Toggle the use of ‘PORT’ commands. By default, ‘ftp’ will attempt |
| 1715 |
to use a ‘PORT’ command when establishing a connection for each |
| 1716 |
data transfer. The use of ‘PORT’ commands can prevent delays when |
| 1717 |
performing multiple file transfers. If the ‘PORT’ command fails, |
| 1718 |
‘ftp’ will use the default data port. When the use of ‘PORT’ |
| 1719 |
commands is disabled, no attempt will be made to use ‘PORT’ |
| 1720 |
commands for each data transfer. This is useful for certain FTP |
| 1721 |
implementations which do ignore ‘PORT’ commands but, incorrectly, |
| 1722 |
indicate they've been accepted. |
| 1723 |
|
| 1724 |
‘site ARG...’ |
| 1725 |
The arguments specified are sent, verbatim, to the remote FTP |
| 1726 |
server as a ‘SITE’ command. |
| 1727 |
|
| 1728 |
‘size FILE-NAME’ |
| 1729 |
Return size of FILE-NAME on remote machine. |
| 1730 |
|
| 1731 |
‘status’ |
| 1732 |
Show the current status of ‘ftp’. |
| 1733 |
|
| 1734 |
‘struct [STRUCT-NAME]’ |
| 1735 |
Set the file transfer structure to STRUCT-NAME. By default ‘file’ |
| 1736 |
structure is used, which also is the only supported value. |
| 1737 |
|
| 1738 |
‘sunique’ |
| 1739 |
Toggle storing of files on remote machine under unique file names. |
| 1740 |
Remote FTP server must support FTP protocol ‘STOU’ command for |
| 1741 |
successful completion. The remote server will report unique name. |
| 1742 |
Default value is off. |
| 1743 |
|
| 1744 |
‘system’ |
| 1745 |
Show the type of operating system running on the remote machine. |
| 1746 |
|
| 1747 |
‘tenex’ |
| 1748 |
Set the file transfer type to that needed to talk to TENEX |
| 1749 |
machines. |
| 1750 |
|
| 1751 |
‘trace’ |
| 1752 |
Toggle packet tracing (feature is not implemented). |
| 1753 |
|
| 1754 |
‘type [TYPE-NAME]’ |
| 1755 |
Set the file transfer type to TYPE-NAME. If no type is specified, |
| 1756 |
the current type is printed. The recognized type names are |
| 1757 |
‘ascii’, ‘binary’, ‘ebcdic’, ‘image’, and ‘tenex’. The default |
| 1758 |
type is network ASCII. |
| 1759 |
|
| 1760 |
‘umask [NEWMASK]’ |
| 1761 |
Set the default umask on the remote server to NEWMASK. If NEWMASK |
| 1762 |
is omitted, the current umask is printed. |
| 1763 |
|
| 1764 |
‘user USER-NAME [PASSWORD] [ACCOUNT]’ |
| 1765 |
Identify yourself to the remote FTP server. If the password is not |
| 1766 |
specified and the server requires it, ‘ftp’ will prompt the user |
| 1767 |
for it (after disabling local echo). If an account field is not |
| 1768 |
specified, and the FTP server requires it, the user will be |
| 1769 |
prompted for it. If an account field is specified, an account |
| 1770 |
command will be relayed to the remote server after the login |
| 1771 |
sequence is completed if the remote server did not require it for |
| 1772 |
logging in. Unless ‘ftp’ is invoked with ‘auto-login’ disabled, |
| 1773 |
this process is done automatically on initial connection to the FTP |
| 1774 |
server. |
| 1775 |
|
| 1776 |
‘verbose’ |
| 1777 |
Toggle verbose mode. In verbose mode, all responses from the FTP |
| 1778 |
server are displayed to the user. In addition, if verbose is on, |
| 1779 |
when a file transfer completes, statistics regarding the efficiency |
| 1780 |
of the transfer are reported. By default, verbose is on. |
| 1781 |
|
| 1782 |
Command arguments which have embedded spaces may be inclosed within |
| 1783 |
citation characters ‘"’. |
| 1784 |
|
| 1785 |
|
| 1786 |
File: inetutils.info, Node: Ftp environment, Next: Aborting a file transfer, Prev: Ftp commands, Up: ftp invocation |
| 1787 |
|
| 1788 |
11.3 Environment variables in use |
| 1789 |
================================= |
| 1790 |
|
| 1791 |
‘ftp’ accesses the following environment variables. |
| 1792 |
|
| 1793 |
‘HOME’ |
| 1794 |
Used for locating a ‘.netrc’ file, if one exists. |
| 1795 |
|
| 1796 |
‘NETRC’ |
| 1797 |
Alternate location of the ‘.netrc’ file, taking precedence over the |
| 1798 |
standard location. |
| 1799 |
|
| 1800 |
‘SHELL’ |
| 1801 |
For determining the default shell interpreter. |
| 1802 |
|
| 1803 |
|
| 1804 |
File: inetutils.info, Node: Aborting a file transfer, Next: File naming conventions, Prev: Ftp environment, Up: ftp invocation |
| 1805 |
|
| 1806 |
11.4 Aborting a file transfer |
| 1807 |
============================= |
| 1808 |
|
| 1809 |
To abort a file transfer, use the terminal interrupt key (usually |
| 1810 |
‘C-c’). Sending transfers will be immediately halted. Receiving |
| 1811 |
transfers will be halted by sending a FTP protocol command ‘ABOR’ to the |
| 1812 |
remote server, discarding any further data received. The speed at which |
| 1813 |
this is accomplished depends upon the remote server's support for ‘ABOR’ |
| 1814 |
processing. If the remote server does not support the ‘ABOR’ command, |
| 1815 |
an ‘ftp>’ prompt will not appear until the remote server has completed |
| 1816 |
sending the requested file. |
| 1817 |
|
| 1818 |
The terminal interrupt key sequence will be ignored when ‘ftp’ has |
| 1819 |
completed any local processing and is awaiting a reply from the remote |
| 1820 |
server. A long delay in this mode may result from the ‘ABOR’ processing |
| 1821 |
described above, or from unexpected behavior by the remote server, |
| 1822 |
including violations of the FTP protocol. If the delay results from |
| 1823 |
unexpected remote server behavior, the local ‘ftp’ program must be |
| 1824 |
killed by hand. |
| 1825 |
|
| 1826 |
|
| 1827 |
File: inetutils.info, Node: File naming conventions, Next: File transfer parameters, Prev: Aborting a file transfer, Up: ftp invocation |
| 1828 |
|
| 1829 |
11.5 File naming conventions |
| 1830 |
============================ |
| 1831 |
|
| 1832 |
Files specified as arguments to ‘ftp’ commands are processed according |
| 1833 |
to the following rules. |
| 1834 |
|
| 1835 |
1. If the file name ‘-’ is specified, standard input (for reading) or |
| 1836 |
standard output (for writing) is used. |
| 1837 |
|
| 1838 |
2. If the first character of the file name is ‘|’, the remainder of |
| 1839 |
the argument is interpreted as a shell command. ‘ftp’ then forks a |
| 1840 |
shell, using ‘popen’ with the argument supplied, and reads/writes |
| 1841 |
from standard input/output. If the shell command includes spaces, |
| 1842 |
the argument must be quoted; e.g. ‘"ls -lt"’. |
| 1843 |
|
| 1844 |
A particularly useful example of this mechanism in action, is |
| 1845 |
|
| 1846 |
ftp> dir . |less |
| 1847 |
|
| 1848 |
which allows the user to scroll through a long directory listing. |
| 1849 |
|
| 1850 |
3. Failing the above checks, if “globbing” is enabled, local file |
| 1851 |
names are expanded according to the rules used by ‘csh’; c.f. the |
| 1852 |
‘glob’ command. If the ‘ftp’ command expects a single local file |
| 1853 |
(e.g. ‘put’), only the first filename generated by the globbing |
| 1854 |
operation is used. |
| 1855 |
|
| 1856 |
4. For the commands ‘mget’ and ‘get’ with unspecified local file name, |
| 1857 |
the local file name is set to the remote file name, which may be |
| 1858 |
altered by a ‘case’, ‘ntrans’, or ‘nmap’ settings. The resulting |
| 1859 |
file name may then be modified if ‘runique’ is set. |
| 1860 |
|
| 1861 |
5. For the commands ‘mput’ and ‘put’ with unspecified remote file |
| 1862 |
name, the remote file name is copied from the local file name, |
| 1863 |
which may be altered by a ‘ntrans’ or ‘nmap’ settings. The |
| 1864 |
resulting file name may also be modified by the remote server if |
| 1865 |
‘sunique’ is set. |
| 1866 |
|
| 1867 |
|
| 1868 |
File: inetutils.info, Node: File transfer parameters, Next: The .netrc file, Prev: File naming conventions, Up: ftp invocation |
| 1869 |
|
| 1870 |
11.6 File transfer parameters |
| 1871 |
============================= |
| 1872 |
|
| 1873 |
The FTP specification includes many parameters which may affect a file |
| 1874 |
transfer. The type may be one of ‘ascii’, ‘image’ (binary), ‘ebcdic’, |
| 1875 |
and ‘local’ byte size (for PDP-10's and PDP-20's mostly). ‘ftp’ |
| 1876 |
supports the ‘ascii’ and ‘image’ types of file transfer, plus local byte |
| 1877 |
size 8 for tenex mode transfers. |
| 1878 |
|
| 1879 |
‘ftp’ supports only the default values for the remaining file |
| 1880 |
transfer parameters: ‘mode’, ‘form’, and ‘struct’. |
| 1881 |
|
| 1882 |
An error in the treatment of carriage returns in the 4.2BSD |
| 1883 |
ascii-mode transfer code has been corrected by the present |
| 1884 |
implementation. This correction may result in corrupt transfers of |
| 1885 |
binary files to and from 4.2BSD servers, when done using the ascii type. |
| 1886 |
Avoid this problem by using the binary image type. |
| 1887 |
|
| 1888 |
|
| 1889 |
File: inetutils.info, Node: The .netrc file, Prev: File transfer parameters, Up: ftp invocation |
| 1890 |
|
| 1891 |
11.7 The ‘.netrc’ file |
| 1892 |
====================== |
| 1893 |
|
| 1894 |
The ‘.netrc’ file contains login and initialization information used by |
| 1895 |
the auto-login process. It generally resides in the user's home |
| 1896 |
directory, but a location outside of the home directory can be set using |
| 1897 |
the environment variable ‘NETRC’. Both locations are overridden by the |
| 1898 |
command line option ‘-N’. The selected file must be a regular file, or |
| 1899 |
access will be denied. |
| 1900 |
|
| 1901 |
The following tokens are recognized; they may be separated by spaces, |
| 1902 |
tabs, or new-lines: |
| 1903 |
|
| 1904 |
‘machine name’ |
| 1905 |
Identify a remote machine name. The auto-login process searches |
| 1906 |
the ‘.netrc’ file for a machine token that matches the remote |
| 1907 |
machine specified on the ‘ftp’ command line or as an open command |
| 1908 |
argument. Once a match is made, the subsequent ‘.netrc’ tokens are |
| 1909 |
processed, stopping when the end of file is reached or another |
| 1910 |
machine or a default token is encountered. |
| 1911 |
|
| 1912 |
‘default’ |
| 1913 |
This is the same as machine name except that default matches any |
| 1914 |
name. There can be only one default token, and it must be after |
| 1915 |
all machine tokens. This is normally used as: |
| 1916 |
|
| 1917 |
default login anonymous password user@site |
| 1918 |
|
| 1919 |
thereby giving the user automatic anonymous ftp login to machines |
| 1920 |
not specified in ‘.netrc’. This can be overridden by using the |
| 1921 |
‘-n’ flag to disable auto-login. |
| 1922 |
|
| 1923 |
‘login name’ |
| 1924 |
Identify a user on the remote machine. If this token is present, |
| 1925 |
the auto-login process will initiate a login using the specified |
| 1926 |
name. |
| 1927 |
|
| 1928 |
‘password string’ |
| 1929 |
Supply a password. If this token is present, the auto-login |
| 1930 |
process will supply the specified string if the remote server |
| 1931 |
requires a password as part of the login process. Note that if |
| 1932 |
this token is present in the ‘.netrc’ file for any user other than |
| 1933 |
anonymous, ‘ftp’ will abort the auto-login process if the ‘.netrc’ |
| 1934 |
is readable by anyone besides the user. |
| 1935 |
|
| 1936 |
‘account string’ |
| 1937 |
Supply an additional account password. If this token is present, |
| 1938 |
the auto-login process will supply the specified string if the |
| 1939 |
remote server requires an additional account password, or the |
| 1940 |
auto-login process will initiate an ‘ACCT’ command if it does not. |
| 1941 |
|
| 1942 |
‘macdef name’ |
| 1943 |
Define a macro. This token functions like the ‘ftp’ ‘macdef’ |
| 1944 |
command functions. A macro is defined with the specified name; its |
| 1945 |
contents begin with the next ‘.netrc’ line and continue until a |
| 1946 |
null line (consecutive new-line characters) is encountered. If a |
| 1947 |
macro named init is defined, it is automatically executed as the |
| 1948 |
last step in the auto-login process. |
| 1949 |
|
| 1950 |
|
| 1951 |
File: inetutils.info, Node: rcp invocation, Next: rexec invocation, Prev: ftp invocation, Up: Top |
| 1952 |
|
| 1953 |
12 ‘rcp’: Copy files between machines |
| 1954 |
************************************* |
| 1955 |
|
| 1956 |
‘rcp’ copies files between machines. Each file or directory argument is |
| 1957 |
either a remote file name of the form ‘rname@rhost:path’, or a local |
| 1958 |
file name (containing no ‘:’ characters, or a ‘/’ before any ‘:’s). |
| 1959 |
|
| 1960 |
Synopsis: |
| 1961 |
|
| 1962 |
rcp [OPTION]... OLD-FILE NEW-FILE |
| 1963 |
rcp [OPTION]... FILES... DIRECTORY |
| 1964 |
|
| 1965 |
12.1 Command line options |
| 1966 |
========================= |
| 1967 |
|
| 1968 |
‘-4’ |
| 1969 |
‘--ipv4’ |
| 1970 |
Use only IPv4. |
| 1971 |
|
| 1972 |
‘-6’ |
| 1973 |
‘--ipv6’ |
| 1974 |
Use only IPv6. |
| 1975 |
|
| 1976 |
‘-d DIRECTORY’ |
| 1977 |
‘--target-directory=DIRECTORY’ |
| 1978 |
Copy all source arguments into DIRECTORY. |
| 1979 |
|
| 1980 |
‘-f’ |
| 1981 |
‘--from’ |
| 1982 |
(Server mode only.) Copying from remote host. |
| 1983 |
|
| 1984 |
‘-k REALM’ |
| 1985 |
‘--realm=REALM’ |
| 1986 |
The option requests rcp to obtain tickets for the remote host in |
| 1987 |
realm REALM instead of the remote host's realm. |
| 1988 |
|
| 1989 |
‘-K’ |
| 1990 |
‘--kerberos’ |
| 1991 |
Turns off all Kerberos authentication. |
| 1992 |
|
| 1993 |
‘-p’ |
| 1994 |
‘--preserve’ |
| 1995 |
Causes ‘rcp’ to attempt to preserve (duplicate) in its copies the |
| 1996 |
modification times and modes of the source files, ignoring the |
| 1997 |
umask. By default, the mode and owner of the target file are |
| 1998 |
preserved if the target itself already exists; otherwise the mode |
| 1999 |
of the source file is modified by the ‘umask’ setting on the |
| 2000 |
destination host. |
| 2001 |
|
| 2002 |
‘-r’ |
| 2003 |
‘--recursive’ |
| 2004 |
If any of the source files are directories, ‘rcp’ copies each |
| 2005 |
subtree rooted at that name; in this case the destination must be a |
| 2006 |
directory. |
| 2007 |
|
| 2008 |
‘-t’ |
| 2009 |
‘--to’ |
| 2010 |
(Server mode only.) Copying to remote host. |
| 2011 |
|
| 2012 |
‘-x’ |
| 2013 |
‘--encrypt’ |
| 2014 |
Turns on encryption for all data passed via the ‘rcp’ session. |
| 2015 |
This may impact response time and CPU utilization, but provides |
| 2016 |
increased security. |
| 2017 |
|
| 2018 |
‘rcp’ doesn't detect all cases where the target of a copy might be a |
| 2019 |
file in cases where only a directory should be legal. |
| 2020 |
|
| 2021 |
‘rcp’ can be confused by any output generated by commands in a |
| 2022 |
‘.login’, ‘.profile’, or ‘.cshrc’ file on the remote host. |
| 2023 |
|
| 2024 |
The destination user and hostname may have to be specified as |
| 2025 |
‘rhost.rname’ when the destination machine is running the 4.2BSD version |
| 2026 |
of ‘rcp’. |
| 2027 |
|
| 2028 |
|
| 2029 |
File: inetutils.info, Node: rexec invocation, Next: rlogin invocation, Prev: rcp invocation, Up: Top |
| 2030 |
|
| 2031 |
13 ‘rexec’: a remote execution program |
| 2032 |
************************************** |
| 2033 |
|
| 2034 |
‘rexec’ is a program that executes a program on another host. |
| 2035 |
|
| 2036 |
Synopsis: |
| 2037 |
|
| 2038 |
rexec --user=LOGIN --password=PASS --host=HOST \ |
| 2039 |
[OPTION] COMMAND |
| 2040 |
|
| 2041 |
13.1 Command line options |
| 2042 |
========================= |
| 2043 |
|
| 2044 |
‘-4’ |
| 2045 |
‘--ipv4’ |
| 2046 |
Use only IPv4 connections as all times. |
| 2047 |
|
| 2048 |
‘-6’ |
| 2049 |
‘--ipv6’ |
| 2050 |
Use only IPv6 connections. |
| 2051 |
|
| 2052 |
‘-a’ |
| 2053 |
‘--ipany’ |
| 2054 |
Allow any address family for connections. This is the default. |
| 2055 |
|
| 2056 |
‘-e’ |
| 2057 |
‘--error=PORT’ |
| 2058 |
Specify the TCP port to use for stderr redirection, in case it is |
| 2059 |
not specified a random port will be used. |
| 2060 |
|
| 2061 |
‘-h’ |
| 2062 |
‘--host=NAME’ |
| 2063 |
Specify the host with whom to connect: symbolic name or address. |
| 2064 |
|
| 2065 |
‘-n’ |
| 2066 |
‘--noerr’ |
| 2067 |
If specified, an error stream will not be created. |
| 2068 |
|
| 2069 |
‘-p’ |
| 2070 |
‘--password=PASSWD’ |
| 2071 |
Specify the password for logging-in. The special value consisting |
| 2072 |
of a single dash ‘-’ will make ‘rexec’ read a single line from |
| 2073 |
stdin. This input is then used as password and is passed as such |
| 2074 |
to the remote server. Thus it is possible to hide vital access |
| 2075 |
information slightly better than the full disclosure implicit in |
| 2076 |
the text of a command line option. |
| 2077 |
|
| 2078 |
‘-P’ |
| 2079 |
‘--port=NUM’ |
| 2080 |
Specify to which numerical port a connection shall be sought. If |
| 2081 |
it is not specified, then use port 512/tcp by default. |
| 2082 |
|
| 2083 |
‘-u’ |
| 2084 |
‘--user=NAME’ |
| 2085 |
Specify the user with whom to log into the server. |
| 2086 |
|
| 2087 |
|
| 2088 |
File: inetutils.info, Node: rlogin invocation, Next: rsh invocation, Prev: rexec invocation, Up: Top |
| 2089 |
|
| 2090 |
14 ‘rlogin’: Remote login |
| 2091 |
************************* |
| 2092 |
|
| 2093 |
The ‘rlogin’ command starts a terminal session on the specified remote |
| 2094 |
host, provided the required authentication is successful. The remote |
| 2095 |
terminal type is the same as that given in the ‘TERM’ local environment |
| 2096 |
variable. The terminal and the window size stay the same, if the remote |
| 2097 |
host supports them, and any changes in size are transferred as need may |
| 2098 |
be. |
| 2099 |
|
| 2100 |
When using the ‘rlogin’ command, you can create a link in your path, |
| 2101 |
using a host name as the link name. For example: |
| 2102 |
|
| 2103 |
# ln -s /usr/bin/rlogin HOSTNAME |
| 2104 |
# HOSTNAME -8 |
| 2105 |
|
| 2106 |
Afterwards, the use of HOSTNAME will automatically invoke ‘rlogin’ to |
| 2107 |
direct a log in request to the remote host named HOSTNAME. |
| 2108 |
|
| 2109 |
‘rlogin’ allows access to the remote host without the use of a |
| 2110 |
password. The prerequisite is a suitable specification in ‘~/.rhosts’. |
| 2111 |
For details, *Note rcmd: (libc)rcmd. |
| 2112 |
|
| 2113 |
14.1 Command line options |
| 2114 |
========================= |
| 2115 |
|
| 2116 |
The options are as follows : |
| 2117 |
|
| 2118 |
‘-4’ |
| 2119 |
‘--ipv4’ |
| 2120 |
Use only IPv4. |
| 2121 |
|
| 2122 |
‘-6’ |
| 2123 |
‘--ipv6’ |
| 2124 |
Use only IPv6. |
| 2125 |
|
| 2126 |
‘-8’ |
| 2127 |
‘--8-bit’ |
| 2128 |
Allows an eight-bit input data path at all times; otherwise parity |
| 2129 |
bits are stripped except when the remote side's stop and start |
| 2130 |
characters are other than ‘C-S’/‘C-Q’. |
| 2131 |
|
| 2132 |
‘-d’ |
| 2133 |
‘--debug’ |
| 2134 |
Turns on socket debugging on the TCP sockets used for communication |
| 2135 |
with the remote host. |
| 2136 |
|
| 2137 |
‘-e CHAR’ |
| 2138 |
‘--escape=CHAR’ |
| 2139 |
Allows user specification of the escape character, which is ‘~’ by |
| 2140 |
default. This specification may be as a literal character, or as |
| 2141 |
an octal value in the form ‘\nnn’. |
| 2142 |
|
| 2143 |
‘-E’ |
| 2144 |
‘--no-escape’ |
| 2145 |
Stops any character from being recognized as an escape character. |
| 2146 |
When used with the ‘-8’ option, this provides a completely |
| 2147 |
transparent connection. |
| 2148 |
|
| 2149 |
‘-l USER’ |
| 2150 |
‘--user=USER’ |
| 2151 |
By default, the remote username is the same as the local username. |
| 2152 |
This option, and the ‘user@host’ format, allow the remote user name |
| 2153 |
to be made explicit, or changed. |
| 2154 |
|
| 2155 |
The next three options are available only if the program has been |
| 2156 |
compiled with support for Kerberos authentication. |
| 2157 |
|
| 2158 |
‘-k REALM’ |
| 2159 |
‘--realm=REALM’ |
| 2160 |
The option requests rlogin to obtain tickets for the remote host in |
| 2161 |
realm REALM instead of the remote host's realm. |
| 2162 |
|
| 2163 |
‘-K’ |
| 2164 |
‘--kerberos’ |
| 2165 |
Turns off all Kerberos authentication. |
| 2166 |
|
| 2167 |
‘-x’ |
| 2168 |
‘--encrypt’ |
| 2169 |
Turns on encryption for all data passed via the rlogin session. |
| 2170 |
This may impact response time and CPU utilization, but provides |
| 2171 |
increased security. |
| 2172 |
|
| 2173 |
14.2 Escape characters and flow control |
| 2174 |
======================================= |
| 2175 |
|
| 2176 |
As long as the connection stands, the client program ‘rsh’ is observing |
| 2177 |
the input stream in order to detect so called escape sequences, allowing |
| 2178 |
the user to execute some local actions without having to tear down the |
| 2179 |
remote connection. |
| 2180 |
|
| 2181 |
The sequences consist of two characters, the first of which always is |
| 2182 |
the distinguished character ESCAPE-CHAR. The following sequences are |
| 2183 |
supported: |
| 2184 |
|
| 2185 |
• ‘ESCAPE-CHAR .’ disconnects from the remote host. |
| 2186 |
|
| 2187 |
• ‘ESCAPE-CHAR C-d’ does the same. (Termios character ‘VEOF’.) |
| 2188 |
|
| 2189 |
• ‘ESCAPE-CHAR C-z’ suspends the session, halting the remote process, |
| 2190 |
but keeping it ready for resumed processing. The user is given |
| 2191 |
access to a local shell. (Termios character ‘VSUSP’.) |
| 2192 |
|
| 2193 |
• ‘ESCAPE-CHAR DELAYED-SUSPEND-CHAR’ implements a half-way suspend, |
| 2194 |
in the sense of stopping local input from reaching the remote side, |
| 2195 |
but still displaying all output from the remote host on the local |
| 2196 |
terminal. The remote process is still running, but the local user |
| 2197 |
is given a local shell until the resuming the original command. |
| 2198 |
Normally, only BSD systems offer this mode. (Termios character |
| 2199 |
‘VDSUSP’.) |
| 2200 |
|
| 2201 |
By default, the character tilde ‘~’ is assigned to ESCAPE-CHAR, but it |
| 2202 |
can be changed using the option ‘--escape’. The processing of escape |
| 2203 |
sequences can even be disable using the option ‘--no-escape’. On BSD |
| 2204 |
systems, DELAYED-SUSPEND-CHAR is usually set to ‘C-Y’. It displays as |
| 2205 |
‘dsusp’ using ‘stty’. |
| 2206 |
|
| 2207 |
All echoing takes place at the remote site, so that the ‘rlogin’ is |
| 2208 |
transparent except possibly for transmission delays. Flow control via |
| 2209 |
‘C-S’ and ‘C-Q’, if at all supported, will stop and start the flow of |
| 2210 |
data on the local terminal. Flushing of input and output on interrupts |
| 2211 |
is also handled properly. |
| 2212 |
|
| 2213 |
On the server side the ‘iruserok’ and ‘ruserok’ functions are used to |
| 2214 |
authenticate the connection request, unless Kerberised mode is in |
| 2215 |
effect. See the appropriate man pages for more information. |
| 2216 |
|
| 2217 |
14.3 Kerberos Authentication |
| 2218 |
============================ |
| 2219 |
|
| 2220 |
If ‘rlogin’ was compiled with kerberos support, options ‘-x’, ‘-k’, ‘-K’ |
| 2221 |
are available. Each user may have a private authorization list in the |
| 2222 |
file ‘.k5login’ in their home directory. Each line in this file should |
| 2223 |
contain a Kerberos principal name of the form |
| 2224 |
‘principal/instance@realm’. If the originating user is authenticated to |
| 2225 |
one of the principals named in ‘.k5login’, access is granted to the |
| 2226 |
account. The principal ‘accountname@localrealm’ is granted access if |
| 2227 |
there is no ‘.k5login’ file. Otherwise a login and password will be |
| 2228 |
prompted for on the remote machine as in ‘login’. To avoid certain |
| 2229 |
security problems, the ‘.k5login’ file must be owned by the remote user. |
| 2230 |
If Kerberos authentication fails, a warning message is printed and the |
| 2231 |
standard Berkeley rlogin is used instead. |
| 2232 |
|
| 2233 |
|
| 2234 |
File: inetutils.info, Node: rsh invocation, Next: talk invocation, Prev: rlogin invocation, Up: Top |
| 2235 |
|
| 2236 |
15 ‘rsh’: Remote shell |
| 2237 |
********************** |
| 2238 |
|
| 2239 |
‘rsh’ executes commands on a remote host and copies its local standard |
| 2240 |
input to that of the remote command, as well as the remote standard |
| 2241 |
output to the local standard output, and the remote standard error to |
| 2242 |
the local standard error. Locally raised interrupt, quit and terminate |
| 2243 |
signals are all propagated to the remote command. Normally ‘rsh’ |
| 2244 |
terminates when the remote command does so. |
| 2245 |
|
| 2246 |
When using the ‘rsh’ command, you can for convenience create a link |
| 2247 |
in your path, using a host name as name of the link. For example: |
| 2248 |
|
| 2249 |
# ln -s /usr/bin/rsh HOSTNAME |
| 2250 |
# HOSTNAME ls |
| 2251 |
|
| 2252 |
Afterwards, HOSTNAME will be passed to ‘rsh’ as host name whenever the |
| 2253 |
command HOSTNAME is issued. |
| 2254 |
|
| 2255 |
‘rsh’ allows access to the remote host without the use of a password. |
| 2256 |
The prerequisite is a suitable specification in ‘~/.rhosts’. For |
| 2257 |
details, *Note rcmd: (libc)rcmd. |
| 2258 |
|
| 2259 |
If no command is specified for ‘rsh’ ar argument following the host |
| 2260 |
name, then you will be logged in on the remote host using ‘rlogin’. |
| 2261 |
|
| 2262 |
15.1 Command line options |
| 2263 |
========================= |
| 2264 |
|
| 2265 |
The options are as follows : |
| 2266 |
|
| 2267 |
‘-4’ |
| 2268 |
‘--ipv4’ |
| 2269 |
Use only IPv4. |
| 2270 |
|
| 2271 |
‘-6’ |
| 2272 |
‘--ipv6’ |
| 2273 |
Use only IPv6. |
| 2274 |
|
| 2275 |
‘-d’ |
| 2276 |
‘--debug’ |
| 2277 |
Turns on socket debugging used for communication with the remote |
| 2278 |
host. |
| 2279 |
|
| 2280 |
‘-l USER’ |
| 2281 |
‘--user=USER’ |
| 2282 |
By default, the remote username is the same as the local username. |
| 2283 |
The ‘-l’ option and the ‘username@host’ format allow the remote |
| 2284 |
user name to be specified. Kerberos authentication is used, |
| 2285 |
whenever available, and authorization is determined as in ‘rlogin’ |
| 2286 |
(*note rlogin invocation::). |
| 2287 |
|
| 2288 |
‘-n’ |
| 2289 |
‘--no-input’ |
| 2290 |
Use ‘/dev/null’ for all input, telling the server side that we send |
| 2291 |
no material. This can prevent the remote process from blocking, |
| 2292 |
should it optionally accept more input. The option is void |
| 2293 |
together with encryption. |
| 2294 |
|
| 2295 |
The next three options are available only if the program has been |
| 2296 |
compiled with support for Kerberos authentication. |
| 2297 |
|
| 2298 |
‘-k REALM’ |
| 2299 |
‘--realm=REALM’ |
| 2300 |
The option requests rsh to obtain tickets for the remote host in |
| 2301 |
realm REALM instead of the remote host's realm. |
| 2302 |
|
| 2303 |
‘-K’ |
| 2304 |
‘--kerberos’ |
| 2305 |
Turns off all Kerberos authentication. |
| 2306 |
|
| 2307 |
‘-x’ |
| 2308 |
‘--encrypt’ |
| 2309 |
Turns on encryption for all data passed via the rsh session. This |
| 2310 |
may impact response time and CPU utilization, but provides |
| 2311 |
increased security. |
| 2312 |
|
| 2313 |
Finally, some compatibility options are present: |
| 2314 |
|
| 2315 |
‘-8’ |
| 2316 |
‘--8-bit’ |
| 2317 |
‘-e CHAR’ |
| 2318 |
‘--escape=CHAR’ |
| 2319 |
‘-E’ |
| 2320 |
‘--no-escape’ |
| 2321 |
Ignored during normal operation, but passed on to ‘rlogin’ when |
| 2322 |
‘rsh’ is invoked without a command argument. |
| 2323 |
|
| 2324 |
15.2 Note on stream redirections |
| 2325 |
================================ |
| 2326 |
|
| 2327 |
Beware that non-quoted shell metacharacters are interpreted on the local |
| 2328 |
machine, while quoted metacharacters are interpreted on the remote |
| 2329 |
machine. For example: |
| 2330 |
|
| 2331 |
rsh otherhost cat remotefile >> localfile |
| 2332 |
rsh otherhost cat remotefile ">>" otherfile |
| 2333 |
|
| 2334 |
The first command appends the contents of ‘remotefile’, as found on the |
| 2335 |
remote host, to the file ‘localfile’ on the local host, since the local |
| 2336 |
shell will intercept the redirection and will thus receive whatever the |
| 2337 |
remote process directs to stdout. |
| 2338 |
|
| 2339 |
In contrast, the second command will append the contents of the same |
| 2340 |
file ‘remotefile’ to a file named ‘otherfile’ again, but this time the |
| 2341 |
file is located on the remote host. The effect of quoting the |
| 2342 |
redirection operator is to execute the command |
| 2343 |
|
| 2344 |
cat remotefile >> localfile |
| 2345 |
|
| 2346 |
entirely on the remote most, whence stdout at the remote host will have |
| 2347 |
nothing to transmit to the listening local host!. |
| 2348 |
|
| 2349 |
|
| 2350 |
File: inetutils.info, Node: talk invocation, Next: telnet invocation, Prev: rsh invocation, Up: Top |
| 2351 |
|
| 2352 |
16 ‘talk’: a communication program |
| 2353 |
********************************** |
| 2354 |
|
| 2355 |
‘talk’ is a visual communication program which copies lines from your |
| 2356 |
terminal to that of another user. |
| 2357 |
|
| 2358 |
Synopsis: |
| 2359 |
|
| 2360 |
talk PERSON [TTYNAME] |
| 2361 |
|
| 2362 |
16.1 Invoking |
| 2363 |
============= |
| 2364 |
|
| 2365 |
The command line arguments are as follows: |
| 2366 |
|
| 2367 |
PERSON |
| 2368 |
If you wish to talk to someone on your own machine, then PERSON is |
| 2369 |
just the other person's login name. If you wish to talk to a user |
| 2370 |
on another host, then PERSON is of the form ‘user@host’. |
| 2371 |
|
| 2372 |
TTYNAME |
| 2373 |
If you wish to talk to a local user who is logged in more than |
| 2374 |
once, the argument TTYNAME may be used to indicate the appropriate |
| 2375 |
terminal name, where TTYNAME typically is of the form ‘ttyXX’, or |
| 2376 |
‘pts/X’. |
| 2377 |
|
| 2378 |
When first called, ‘talk’ sends a message to the addressed user: |
| 2379 |
|
| 2380 |
Message from TalkDaemon@his_machine... |
| 2381 |
talk: connection requested by your_name@your_machine. |
| 2382 |
talk: respond with: talk your_name@your_machine |
| 2383 |
|
| 2384 |
At this point, the recipient of the message could elect to accept the |
| 2385 |
call and to establish a connection by typing: |
| 2386 |
|
| 2387 |
talk YOUR_NAME@YOUR_MACHINE |
| 2388 |
|
| 2389 |
It doesn't matter from which machine the recipient replies, as long |
| 2390 |
as his login-name is the same. Once communication is established, the |
| 2391 |
two parties may type text simultaneously, with their output appearing in |
| 2392 |
separate windows. Typing ‘C-L’ will cause the screen to be reprinted, |
| 2393 |
while erase, kill, and word kill characters will behave normally. In |
| 2394 |
addition, ‘C-D’ will cause both windows to be locally cleared of all |
| 2395 |
text. This keystroke will appear as a simple ‘^D’ on the remote |
| 2396 |
terminal, though. It signals to the other party that you yourself have |
| 2397 |
just cleared your terminal of all text. |
| 2398 |
|
| 2399 |
To exit, just type an interrupt character ‘C-C’; ‘talk’ then moves |
| 2400 |
the cursor to the bottom of the screen and restores the terminal to its |
| 2401 |
previous state. |
| 2402 |
|
| 2403 |
The ability to talk may be enabled or disabled by use of the ‘mesg’ |
| 2404 |
command. It is system dependent whether this message passing is enabled |
| 2405 |
at the outset of a terminal session. Certain commands, in particular |
| 2406 |
‘nroff’ and ‘pr’, disable messages in order to prevent messy output. |
| 2407 |
|
| 2408 |
|
| 2409 |
File: inetutils.info, Node: telnet invocation, Next: tftp invocation, Prev: talk invocation, Up: Top |
| 2410 |
|
| 2411 |
17 ‘telnet’: User interface to TELNET |
| 2412 |
************************************* |
| 2413 |
|
| 2414 |
Login to a remote system HOST, optionally using a (non-standard) service |
| 2415 |
port PORT. |
| 2416 |
|
| 2417 |
Synopsis: |
| 2418 |
|
| 2419 |
telnet [OPTION...] [HOST [PORT]] |
| 2420 |
|
| 2421 |
17.1 Command line options |
| 2422 |
========================= |
| 2423 |
|
| 2424 |
‘-4’ |
| 2425 |
‘--ipv4’ |
| 2426 |
Use only IPv4. |
| 2427 |
|
| 2428 |
‘-6’ |
| 2429 |
‘--ipv6’ |
| 2430 |
Use only IPv6. |
| 2431 |
|
| 2432 |
‘-8’ |
| 2433 |
‘--binary’ |
| 2434 |
Use an 8-bit data path. |
| 2435 |
|
| 2436 |
‘-a’ |
| 2437 |
‘--login’ |
| 2438 |
Attempt automatic login. |
| 2439 |
|
| 2440 |
‘-b ADDRESS’ |
| 2441 |
‘--bind=ADDRESS’ |
| 2442 |
Bind to specific local ADDRESS. |
| 2443 |
|
| 2444 |
‘-c’ |
| 2445 |
‘--no-rc’ |
| 2446 |
Do not read the user's file ‘$HOME/.telnetrc’. |
| 2447 |
|
| 2448 |
‘-d’ |
| 2449 |
‘--debug’ |
| 2450 |
Turn on socket level debugging. |
| 2451 |
|
| 2452 |
‘-e CHAR’ |
| 2453 |
‘--escape=CHAR’ |
| 2454 |
Use CHAR as escape character. |
| 2455 |
|
| 2456 |
‘-E’ |
| 2457 |
‘--no-escape’ |
| 2458 |
Do not use an escape character. |
| 2459 |
|
| 2460 |
‘-k REALM’ |
| 2461 |
‘--realm=REALM’ |
| 2462 |
Request Kerberos realm REALM instead of whatever is declared as |
| 2463 |
default realm in the system's or user's settings. |
| 2464 |
|
| 2465 |
‘-K’ |
| 2466 |
‘--no-login’ |
| 2467 |
Do not automatically login to the remote system. |
| 2468 |
|
| 2469 |
‘-l USER’ |
| 2470 |
‘--user=USER’ |
| 2471 |
Attempt automatic login as USER. |
| 2472 |
|
| 2473 |
‘-L’ |
| 2474 |
‘--binary-output’ |
| 2475 |
Use an 8-bit data path for output only. |
| 2476 |
|
| 2477 |
‘-n FILE’ |
| 2478 |
‘--trace=FILE’ |
| 2479 |
Record trace information into FILE. |
| 2480 |
|
| 2481 |
‘-r’ |
| 2482 |
‘--rlogin’ |
| 2483 |
Display a user-interface similar to that of ‘rlogin’. |
| 2484 |
|
| 2485 |
‘-x’ |
| 2486 |
‘--encrypt’ |
| 2487 |
If possible, encrypt the data stream. |
| 2488 |
|
| 2489 |
‘-X ATYPE’ |
| 2490 |
‘--disable-auth=ATYPE’ |
| 2491 |
Disable authentication of type ATYPE. Use this option multiple |
| 2492 |
times if more than one type is to be disabled. Standard choices |
| 2493 |
are ‘null’, ‘kerberos_v4’, and ‘kerberos_v5’. |
| 2494 |
|
| 2495 |
|
| 2496 |
File: inetutils.info, Node: tftp invocation, Next: inetd invocation, Prev: telnet invocation, Up: Top |
| 2497 |
|
| 2498 |
18 ‘tftp’: TFTP client |
| 2499 |
********************** |
| 2500 |
|
| 2501 |
‘tftp’ is the user interface to the Internet TFTP, Trivial File Transfer |
| 2502 |
Protocol, which allows users to transfer files to and from a remote |
| 2503 |
machine. The remote host may be specified on the command line, in which |
| 2504 |
case ‘tftp’ uses host as the default host for future transfers. |
| 2505 |
|
| 2506 |
Synopsis: |
| 2507 |
|
| 2508 |
tftp [OPTION]... HOST |
| 2509 |
|
| 2510 |
18.1 Commands |
| 2511 |
============= |
| 2512 |
|
| 2513 |
Once ‘tftp’ is running, it issues the prompt and recognizes the |
| 2514 |
following commands: |
| 2515 |
|
| 2516 |
‘? COMMAND-NAME’ |
| 2517 |
Print help information. |
| 2518 |
|
| 2519 |
‘ascii’ |
| 2520 |
Shorthand for ‘mode ascii’ |
| 2521 |
|
| 2522 |
‘binary’ |
| 2523 |
Shorthand for ‘mode binary’ |
| 2524 |
|
| 2525 |
‘connect HOST-NAME [PORT]’ |
| 2526 |
Set the host (and optionally port) for transfers. Note that the |
| 2527 |
TFTP protocol, unlike the FTP protocol, does not maintain |
| 2528 |
connections between transfers; thus, the connect command does not |
| 2529 |
actually create a connection, but merely remembers what host is to |
| 2530 |
be used for transfers. You do not have to use the connect command; |
| 2531 |
the remote host can be specified as part of the get or put |
| 2532 |
commands. |
| 2533 |
|
| 2534 |
‘get FILE-NAME’ |
| 2535 |
‘get REMOTENAME LOCALNAME’ |
| 2536 |
‘get FILE...’ |
| 2537 |
Get a file, or a set of files, from the specified sources. The |
| 2538 |
source can be in one of two forms: a file name on the remote host, |
| 2539 |
if the host has already been specified, or a string of the form |
| 2540 |
‘host:filename’ to specify both a host and file name at the same |
| 2541 |
time. If the latter form is used, the last hostname specified |
| 2542 |
becomes the default for future transfers. When specifying a |
| 2543 |
numeric IPv6 address as host part, then this address must be |
| 2544 |
enclosed between square brackets, since it contains colons and |
| 2545 |
would interfere with the delimiter before the file name. Brackets |
| 2546 |
are optional for IPv4 addresses. |
| 2547 |
|
| 2548 |
tftp> get [2001:1234::12]:issue |
| 2549 |
|
| 2550 |
‘mode TRANSFER-MODE’ |
| 2551 |
Set the mode for transfers; TRANSFER-MODE may be one of ‘ascii’ or |
| 2552 |
‘binary’. The default is ‘ascii’. |
| 2553 |
|
| 2554 |
‘put FILE’ |
| 2555 |
‘put LOCALFILE REMOTEFILE’ |
| 2556 |
‘put FILE... REMOTE-DIRECTORY’ |
| 2557 |
Put a file or set of files to the specified remote file or |
| 2558 |
directory. The destination can be in one of two forms: a filename |
| 2559 |
on the remote host, if the host has already been specified, or a |
| 2560 |
string of the form ‘host:filename’ to specify both a host and |
| 2561 |
filename at the same time. If the latter form is used, the |
| 2562 |
hostname specified becomes the default for future transfers. If |
| 2563 |
the ‘remote-directory’ form is used, the remote host is assumed to |
| 2564 |
be a UNIX machine. The same use of square brackets for enclosing |
| 2565 |
numeric IPv6 addresses applies here, as was mentioned for the |
| 2566 |
command ‘get’. |
| 2567 |
|
| 2568 |
‘quit’ |
| 2569 |
Exit ‘tftp’. An end of file also exits. |
| 2570 |
|
| 2571 |
‘rexmt RETRANSMISSION-TIMEOUT’ |
| 2572 |
Set the per-packet retransmission timeout, in seconds. |
| 2573 |
|
| 2574 |
‘status’ |
| 2575 |
Show current status. |
| 2576 |
|
| 2577 |
‘timeout TOTAL-TRANSMISSION-TIMEOUT’ |
| 2578 |
Set the total transmission timeout, in seconds. |
| 2579 |
|
| 2580 |
‘trace’ |
| 2581 |
Toggle packet tracing. |
| 2582 |
|
| 2583 |
‘verbose’ |
| 2584 |
Toggle verbose mode. |
| 2585 |
|
| 2586 |
Because there is no user-login or validation within the ‘tftp’ |
| 2587 |
protocol, the remote site will probably have some sort of file-access |
| 2588 |
restrictions in place. The exact methods are specific to each site and |
| 2589 |
therefore difficult to document here. |
| 2590 |
|
| 2591 |
|
| 2592 |
File: inetutils.info, Node: inetd invocation, Next: syslogd invocation, Prev: tftp invocation, Up: Top |
| 2593 |
|
| 2594 |
19 ‘inetd’: Internet super-server |
| 2595 |
********************************* |
| 2596 |
|
| 2597 |
‘inetd’ program should be run at boot time by /etc/rc. It then listens |
| 2598 |
for connections on certain internet sockets. When a connection is found |
| 2599 |
on one of its sockets, it decides what service the socket corresponds |
| 2600 |
to, and invokes a program to service the request. The server program is |
| 2601 |
invoked with the service socket as its standard input, output and error |
| 2602 |
descriptors. After the program is finished, inetd continues to listen |
| 2603 |
on the socket (except in some cases which will be described below). |
| 2604 |
Essentially, inetd allows running one daemon to invoke several others, |
| 2605 |
reducing load on the system. |
| 2606 |
|
| 2607 |
There are two types of services that inetd can start: standard and |
| 2608 |
TCPMUX. A standard service has a well-known port assigned to it; it may |
| 2609 |
be a service that implements an official Internet standard or is a |
| 2610 |
BSD-specific service. As described in RFC 1078, TCPMUX services are |
| 2611 |
nonstandard services that do not have a well-known port assigned to |
| 2612 |
them. They are invoked from inetd when a program connects to the |
| 2613 |
"tcpmux" well-known port and specifies the service name. This feature |
| 2614 |
is useful for adding locally-developed servers. |
| 2615 |
|
| 2616 |
* Menu: |
| 2617 |
|
| 2618 |
* Invocation:: |
| 2619 |
* Configuration file:: |
| 2620 |
* Built-in services:: |
| 2621 |
* TCPMUX:: |
| 2622 |
* Inetd Environment:: |
| 2623 |
* Error Messages:: |
| 2624 |
|
| 2625 |
|
| 2626 |
File: inetutils.info, Node: Invocation, Next: Configuration file, Up: inetd invocation |
| 2627 |
|
| 2628 |
19.1 Invocation |
| 2629 |
=============== |
| 2630 |
|
| 2631 |
Normally, ‘inetd’ is invoked without any arguments. It does, however, |
| 2632 |
support several command line options. These are: |
| 2633 |
|
| 2634 |
‘-d’ |
| 2635 |
‘--debug’ |
| 2636 |
Turns on debugging. With this option, ‘inetd’ stays in foreground |
| 2637 |
and prints additional debugging information of stderr. |
| 2638 |
|
| 2639 |
‘--environment’ |
| 2640 |
Pass local and remote socket information in environment variables. |
| 2641 |
*Note Inetd Environment::. |
| 2642 |
|
| 2643 |
‘--foreground’ |
| 2644 |
Run in foreground mode. Similar to debug mode, but does not enable |
| 2645 |
debug messages. |
| 2646 |
|
| 2647 |
‘-p[FILE]’ |
| 2648 |
‘--pidfile[=FILE]’ |
| 2649 |
Use FILE as location to store process ID of the running server |
| 2650 |
process, thus overriding the default location. Setting an empty |
| 2651 |
argument will disable the use of a file for storing the process ID. |
| 2652 |
|
| 2653 |
‘--resolve’ |
| 2654 |
Resolve IP addresses when setting environment variables. *Note |
| 2655 |
Inetd Environment::. |
| 2656 |
|
| 2657 |
‘-R RATE’ |
| 2658 |
‘--rate=RATE’ |
| 2659 |
Specify the maximum number of times a service can be invoked in one |
| 2660 |
minute; the default is 1000. |
| 2661 |
|
| 2662 |
|
| 2663 |
File: inetutils.info, Node: Configuration file, Next: Built-in services, Prev: Invocation, Up: inetd invocation |
| 2664 |
|
| 2665 |
19.2 Configuration file |
| 2666 |
======================= |
| 2667 |
|
| 2668 |
Upon execution, inetd reads its configuration information from |
| 2669 |
configuration files and directories named on the command line. By |
| 2670 |
default these are ‘/etc/inetd.conf’ and ‘/etc/inetd.d’. If the |
| 2671 |
configuration pathname is a directory, all files in the directory are |
| 2672 |
read and interpreted like a configuration file. All of the |
| 2673 |
configuration files are read and the results are merged. |
| 2674 |
|
| 2675 |
There must be an entry for each field in the configuration file, with |
| 2676 |
entries for each field separated by a tab or a space. Comments are |
| 2677 |
denoted by a "#" at the beginning of a line. The available fields of |
| 2678 |
the configuration file are summarized in the table below (optional parts |
| 2679 |
are enclosed in square brackets): |
| 2680 |
|
| 2681 |
[service node:]service name |
| 2682 |
The service-name entry is the name of a valid service in the file |
| 2683 |
‘/etc/services’. For "internal" services (*note Built-in |
| 2684 |
services::), the service name must be the official name of the |
| 2685 |
service (that is, the first entry in ‘/etc/services’), or a numeric |
| 2686 |
representation thereof. For TCPMUX services, the value of the |
| 2687 |
‘service name’ field consists of the string ‘tcpmux’ followed by a |
| 2688 |
slash and the locally-chosen service name (*note TCPMUX::). |
| 2689 |
|
| 2690 |
An optional ‘service node’ prefix is allowed for internet services. |
| 2691 |
When present, it supplies the local addresses ‘inetd’ should use |
| 2692 |
when listening for that service. ‘Service node’ consists of a |
| 2693 |
comma-separated list of addresses. Both symbolic host names and |
| 2694 |
numeric IP addresses are allowed. Symbolic hostnames are looked up |
| 2695 |
in DNS service. If a hostname has multiple address mappings, |
| 2696 |
‘inetd’ creates a socket to listen on each address. |
| 2697 |
|
| 2698 |
To avoid repeating an address that occurs frequently, a line with a |
| 2699 |
host address specifier and colon, but no further fields is allowed, |
| 2700 |
e.g.: |
| 2701 |
|
| 2702 |
127.0.0.1,192.168.0.5: |
| 2703 |
|
| 2704 |
The address specifier from such a line is remembered and used for |
| 2705 |
all further lines lacking an explicit host specifier. Such a |
| 2706 |
default address remains in effect until another such line or end of |
| 2707 |
the configuration is encountered, whichever occurs first. |
| 2708 |
|
| 2709 |
A special hostname ‘*’ stands for the wildcard address. When used |
| 2710 |
in a normal configuration line, it causes the default address |
| 2711 |
specifier to be ignored for that line. When used in a default |
| 2712 |
address specification, e.g.: |
| 2713 |
|
| 2714 |
*: |
| 2715 |
|
| 2716 |
it causes any previous default address specifier to be forgotten. |
| 2717 |
|
| 2718 |
socket type |
| 2719 |
The socket type should be one of ‘stream’, ‘dgram’, ‘raw’, ‘rdm’, |
| 2720 |
or ‘seqpacket’, depending on whether the socket is a stream, |
| 2721 |
datagram, raw, reliably delivered message, or sequenced packet |
| 2722 |
socket. TCPMUX services must use ‘stream’. |
| 2723 |
|
| 2724 |
protocol |
| 2725 |
The protocol must be a valid protocol as given in ‘/etc/protocols’. |
| 2726 |
Examples might be ‘tcp’ or ‘udp’. TCPMUX services must use ‘tcp’. |
| 2727 |
If IPv6 support is enabled the sockets will accept both IPv4 and |
| 2728 |
IPv6 connections if that is supported by the OS. If inetd should |
| 2729 |
only accept IPv4 or IPv6 connections, add ‘4’ or ‘6’ to the |
| 2730 |
protocol name. For example ‘tcp4’ will only accept IPv4 tcp |
| 2731 |
connections and ‘udp6’ will only accept IPv6 udp connections. |
| 2732 |
|
| 2733 |
wait/nowait[.max] |
| 2734 |
The ‘wait/nowait’ entry specifies whether the server that is |
| 2735 |
invoked by ‘inetd’ will take over the socket associated with the |
| 2736 |
service access point, and thus whether inetd should wait for the |
| 2737 |
server to exit before listening for new service requests. Datagram |
| 2738 |
servers must use ‘wait’, as they are always invoked with the |
| 2739 |
original datagram socket bound to the specified service address. |
| 2740 |
These servers must read at least one datagram from the socket |
| 2741 |
before exiting. If a datagram server connects to its peer, freeing |
| 2742 |
the socket so inetd can received further messages on the socket, it |
| 2743 |
is said to be a "multi-threaded" server; it should read one |
| 2744 |
datagram from the socket and create a new socket connected to the |
| 2745 |
peer. It should fork, and the parent should then exit to allow |
| 2746 |
inetd to check for new service requests to spawn new servers. |
| 2747 |
Datagram servers which process all incoming datagrams on a socket |
| 2748 |
and eventually time out are said to be "single-threaded". ‘comsat’ |
| 2749 |
and ‘talkd’ are both examples of the latter type of datagram |
| 2750 |
server. ‘tftpd’ is an example of a multi-threaded datagram server. |
| 2751 |
|
| 2752 |
Servers using stream sockets generally are multi-threaded and use |
| 2753 |
the ‘nowait’ entry. Connection requests for these services are |
| 2754 |
accepted by inetd, and the server is given only the newly-accepted |
| 2755 |
socket connected to a client of the service. Most stream-based |
| 2756 |
services and all TCPMUX services operate in this manner. For such |
| 2757 |
services, the number of running instances of the server can be |
| 2758 |
limited by specifying optional ‘max’ suffix (a decimal number), |
| 2759 |
e.g.: ‘nowait.15’. |
| 2760 |
|
| 2761 |
Stream-based servers that use ‘wait’ are started with the listening |
| 2762 |
service socket, and must accept at least one connection request |
| 2763 |
before exiting. Such a server would normally accept and process |
| 2764 |
incoming connection requests until a timeout. Other services must |
| 2765 |
use ‘nowait’. |
| 2766 |
|
| 2767 |
user |
| 2768 |
The user entry should contain the user name of the user as whom the |
| 2769 |
server should run. This allows for servers to be given less |
| 2770 |
permission than root. An optional form includes also a group name |
| 2771 |
as a suffix, separated from the user name by colon or a period, |
| 2772 |
i.e., ‘user:group’ or ‘user.group’. |
| 2773 |
|
| 2774 |
server program |
| 2775 |
The server-program entry should contain the pathname of the program |
| 2776 |
which is to be executed by inetd when a request is found on its |
| 2777 |
socket. If inetd provides this service internally, this entry |
| 2778 |
should be ‘internal’. |
| 2779 |
|
| 2780 |
It is common usage to specify ‘/usr/sbin/tcpd’ in this field. |
| 2781 |
|
| 2782 |
server program arguments |
| 2783 |
The server program arguments should be just as arguments normally |
| 2784 |
are, starting with ‘argv[0]’, which is the name of the program. If |
| 2785 |
the service is provided internally, this entry must contain the |
| 2786 |
word ‘internal’, or be empty. |
| 2787 |
|
| 2788 |
|
| 2789 |
File: inetutils.info, Node: Built-in services, Next: TCPMUX, Prev: Configuration file, Up: inetd invocation |
| 2790 |
|
| 2791 |
19.3 Built-in services |
| 2792 |
====================== |
| 2793 |
|
| 2794 |
The ‘inetd’ program provides several "trivial" services internally by |
| 2795 |
use of routines within itself. All these services can operate both in |
| 2796 |
‘stream’ and in ‘dgram’ mode. They are: |
| 2797 |
|
| 2798 |
echo |
| 2799 |
Send back to the originating source any data received from it. |
| 2800 |
This is a debugging and measurement tool. |
| 2801 |
|
| 2802 |
discard |
| 2803 |
Silently throw away any data received. |
| 2804 |
|
| 2805 |
chargen |
| 2806 |
This is a character generator service. It can be operated as both |
| 2807 |
stream or dgram service. When operating in ‘stream’ mode, once a |
| 2808 |
connection is established a stream of data is sent out the |
| 2809 |
connection (and any data received is thrown away). This continues |
| 2810 |
until the calling user terminates the connection. When operating |
| 2811 |
in ‘dgram’ mode, ‘inetd’ listens for UDP datagrams, and for each |
| 2812 |
received datagram, answers with a datagram containing a random |
| 2813 |
number (between 0 and 512) of characters. Any data in the received |
| 2814 |
datagram are ignored. |
| 2815 |
|
| 2816 |
daytime |
| 2817 |
Send back the current date and time in a human readable form. Any |
| 2818 |
input is discarded. |
| 2819 |
|
| 2820 |
time |
| 2821 |
Send back the current date and time as a 32-bit integer number, |
| 2822 |
nrepresenting the number of seconds since midnight, January 1, |
| 2823 |
1900. |
| 2824 |
|
| 2825 |
|
| 2826 |
File: inetutils.info, Node: TCPMUX, Next: Inetd Environment, Prev: Built-in services, Up: inetd invocation |
| 2827 |
|
| 2828 |
19.4 TCPMUX |
| 2829 |
=========== |
| 2830 |
|
| 2831 |
The TCPMUX protocol. |
| 2832 |
|
| 2833 |
A TCP client connects to a foreign host on TCP port 1. It sends |
| 2834 |
the service name followed by a carriage-return line-feed <CRLF>. |
| 2835 |
The service name is never case sensitive. The server replies with |
| 2836 |
a single character indicating positive (+) or negative (-) |
| 2837 |
acknowledgment, immediately followed by an optional message of |
| 2838 |
explanation, terminated with a <CRLF>. If the reply was positive, |
| 2839 |
the selected protocol begins; otherwise the connection is closed." |
| 2840 |
The program is passed the TCP connection as file descriptors 0 and |
| 2841 |
1. |
| 2842 |
|
| 2843 |
If the TCPMUX service name begins with a "+", ‘inetd’ returns the |
| 2844 |
positive reply for the program. This allows you to invoke programs that |
| 2845 |
use stdin/stdout without putting any special server code in them. |
| 2846 |
|
| 2847 |
The special service name ‘help’ causes inetd to list TCPMUX services |
| 2848 |
in ‘inetd.conf’. |
| 2849 |
|
| 2850 |
To define TCPMUX services, the configuration file must contain a |
| 2851 |
‘tcpmux internal’ definition. |
| 2852 |
|
| 2853 |
Here are several example service entries for the various types of |
| 2854 |
services: |
| 2855 |
|
| 2856 |
ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l |
| 2857 |
ntalk dgram udp wait nobody:tty /usr/libexec/talkd talkd |
| 2858 |
tcpmux stream tcp nowait root internal |
| 2859 |
tcpmux/+date stream tcp nowait guest /bin/date date |
| 2860 |
tcpmux/phonebook stream tcp nowait guest /usr/bin/phonebook phonebook |
| 2861 |
|
| 2862 |
|
| 2863 |
File: inetutils.info, Node: Inetd Environment, Next: Error Messages, Prev: TCPMUX, Up: inetd invocation |
| 2864 |
|
| 2865 |
19.5 Inetd Environment |
| 2866 |
====================== |
| 2867 |
|
| 2868 |
If a connection is made with a streaming protocol (‘stream’) and if |
| 2869 |
‘--environment’ option has been given, ‘inetd’ will set the following |
| 2870 |
environment variables before starting the program: |
| 2871 |
|
| 2872 |
‘PROTO’ |
| 2873 |
Always ‘TCP’. |
| 2874 |
|
| 2875 |
‘TCPLOCALIP’ |
| 2876 |
Local IP address of the interface which accepted the connection. |
| 2877 |
|
| 2878 |
‘TCPLOCALPORT’ |
| 2879 |
Port number on which the TCP connection was established. |
| 2880 |
|
| 2881 |
‘TCPREMOTEIP’ |
| 2882 |
IP address of the remote client. |
| 2883 |
|
| 2884 |
‘TCPREMOTEPORT’ |
| 2885 |
Port number on the client side of the TCP connection. |
| 2886 |
|
| 2887 |
Additionally, if given the ‘--remote’ option, ‘inetd’ sets the |
| 2888 |
following environment variables: |
| 2889 |
|
| 2890 |
‘TCPLOCALHOST’ |
| 2891 |
DNS name of ‘TCPLOCALIP’. |
| 2892 |
|
| 2893 |
‘TCPREMOTEHOST’ |
| 2894 |
DNS name of ‘TCPREMOTEIP’. |
| 2895 |
|
| 2896 |
|
| 2897 |
File: inetutils.info, Node: Error Messages, Prev: Inetd Environment, Up: inetd invocation |
| 2898 |
|
| 2899 |
19.6 Error Messages |
| 2900 |
=================== |
| 2901 |
|
| 2902 |
The inetd server logs error messages using syslog. Important error |
| 2903 |
messages and their explanations are: |
| 2904 |
|
| 2905 |
‘service/protocol server failing (looping), service terminated.’ |
| 2906 |
The number of requests for the specified service in the past minute |
| 2907 |
exceeded the limit. The limit exists to prevent a broken program |
| 2908 |
or a malicious user from swamping the system. This message may |
| 2909 |
occur for several reasons: |
| 2910 |
|
| 2911 |
1. there are lots of hosts requesting the service within a short |
| 2912 |
time period, |
| 2913 |
2. a "broken" client program is requesting the service too |
| 2914 |
frequently, |
| 2915 |
3. a malicious user is running a program to invoke the service in |
| 2916 |
a "denial of service" attack, |
| 2917 |
4. the invoked service program has an error that causes clients |
| 2918 |
to retry quickly. |
| 2919 |
|
| 2920 |
Use the ‘-R’ option, as described above, to change the rate limit. |
| 2921 |
Once the limit is reached, the service will be re-enabled |
| 2922 |
automatically in 10 minutes. |
| 2923 |
|
| 2924 |
‘service/protocol: No such user 'user', service ignored’ |
| 2925 |
‘service/protocol: getpwnam: user: No such user’ |
| 2926 |
No entry for user exists in the passwd file. The first message |
| 2927 |
occurs when inetd (re)reads the configuration file. The second |
| 2928 |
message occurs when the service is invoked. |
| 2929 |
|
| 2930 |
‘service/protocol: No such user 'user', service ignored’ |
| 2931 |
‘service/protocol: getpwnam: user: No such user’ |
| 2932 |
No entry for user exists in the passwd file. The first message |
| 2933 |
occurs when inetd (re)reads the configuration file. The second |
| 2934 |
message occurs when the service is invoked. |
| 2935 |
|
| 2936 |
‘service: can't set uid number’ |
| 2937 |
‘service: can't set gid number’ |
| 2938 |
The user or group ID for the entry's user is invalid. |
| 2939 |
|
| 2940 |
|
| 2941 |
File: inetutils.info, Node: syslogd invocation, Next: ftpd invocation, Prev: inetd invocation, Up: Top |
| 2942 |
|
| 2943 |
20 ‘syslogd’: system service logging faclity |
| 2944 |
******************************************** |
| 2945 |
|
| 2946 |
‘syslogd’ is a system service that provides error logging facility. |
| 2947 |
Messages are read from the UNIX domain socket ‘/dev/log’, from an |
| 2948 |
Internet domain socket specified in ‘/etc/services’, and from the |
| 2949 |
special device ‘/dev/klog’ (to read kernel messages). |
| 2950 |
|
| 2951 |
‘syslogd’ creates the file ‘/var/run/syslog.pid’, and stores its |
| 2952 |
process id there. This can be used to kill or reconfigure ‘syslogd’. |
| 2953 |
|
| 2954 |
The message sent to ‘syslogd’ should consist of a single line. The |
| 2955 |
message can contain a priority code, which should be a preceding decimal |
| 2956 |
number in angle braces, for example, ‘<5>’. This priority code should |
| 2957 |
map into the priorities defined in the include file ‘sys/syslog.h’. |
| 2958 |
|
| 2959 |
syslogd [OPTIONS]... |
| 2960 |
|
| 2961 |
‘-f FILE’ |
| 2962 |
‘--rcfile=FILE’ |
| 2963 |
Override configuration (the default file is ‘/etc/syslog.conf’). |
| 2964 |
|
| 2965 |
‘-D DIR’ |
| 2966 |
‘--rcdir=DIR’ |
| 2967 |
Override configuration directory (the default is ‘/etc/syslog.d’). |
| 2968 |
|
| 2969 |
‘-P FILE’ |
| 2970 |
‘--pidfile=FILE’ |
| 2971 |
Override pidfile (the default file is ‘/var/run/syslogd.pid’). |
| 2972 |
|
| 2973 |
‘-n’ |
| 2974 |
‘--no-detach’ |
| 2975 |
Do not enter daemon mode. |
| 2976 |
|
| 2977 |
‘-d’ |
| 2978 |
‘--debug’ |
| 2979 |
Print debug information (implies ‘-n’). |
| 2980 |
|
| 2981 |
‘-p FILE’ |
| 2982 |
‘--socket=FILE’ |
| 2983 |
Override default UNIX domain socket ‘/dev/log’. |
| 2984 |
|
| 2985 |
‘-a SOCKET’ |
| 2986 |
Add UNIX socket to listen. An unlimited number of sockets is |
| 2987 |
allowed. |
| 2988 |
|
| 2989 |
‘-r’ |
| 2990 |
‘--inet’ |
| 2991 |
Receive remote messages via Internet domain socket. Without this |
| 2992 |
option no remote massages are received, since there is no listening |
| 2993 |
socket. Yet sockets for forwarding are created on the fly as |
| 2994 |
needed, which might cause performance issues on busy systems. |
| 2995 |
|
| 2996 |
‘-b ADDRESS’ |
| 2997 |
‘--bind=ADDRESS’ |
| 2998 |
Restrict the listening Internet domain socket to a single address. |
| 2999 |
The default (given the use of ‘-r’) is a wildcard address, implying |
| 3000 |
that the server listens at every available address. Any name will |
| 3001 |
be resolved, and the lookup result will depend on the options ‘-4’, |
| 3002 |
‘-6’, and ‘--ipany’. |
| 3003 |
|
| 3004 |
‘--no-unixaf’ |
| 3005 |
Do not listen on UNIX domain sockets (overrides ‘-a’ and ‘-p’). |
| 3006 |
|
| 3007 |
‘--no-klog’ |
| 3008 |
Do not listen to the kernel log device ‘/dev/klog’. |
| 3009 |
|
| 3010 |
‘--ipany’ |
| 3011 |
Allow both address families: IPv4 and IPv6. |
| 3012 |
|
| 3013 |
‘-4’ |
| 3014 |
‘--ipv4’ |
| 3015 |
Use only IPv4 for Internet domain sockets. |
| 3016 |
|
| 3017 |
‘-6’ |
| 3018 |
‘--ipv6’ |
| 3019 |
Use only IPv6 for Internet domain sockets. |
| 3020 |
|
| 3021 |
‘--no-forward’ |
| 3022 |
Do not forward any messages (overrides ‘-h’). This disables even |
| 3023 |
temporary creation of forwarding sockets, an ability which is |
| 3024 |
otherwise active when the option ‘-r’ is left out. |
| 3025 |
|
| 3026 |
‘-h’ |
| 3027 |
‘--hop’ |
| 3028 |
Forward messages from remote hosts. |
| 3029 |
|
| 3030 |
‘-m INTERVAL’ |
| 3031 |
‘--mark=INTERVAL’ |
| 3032 |
Specify timestamp interval expressed in minutes (0 for no |
| 3033 |
timestamping). |
| 3034 |
|
| 3035 |
‘-l HOSTLIST’ |
| 3036 |
Log hosts in HOSTLIST by their hostname. Multiple lists are |
| 3037 |
allowed. |
| 3038 |
|
| 3039 |
‘-s DOMAINLIST’ |
| 3040 |
List of domains which should be stripped from the FQDN of hosts |
| 3041 |
before logging their name. Multiple lists are allowed. |
| 3042 |
|
| 3043 |
‘-T’ |
| 3044 |
‘--local-time’ |
| 3045 |
Ignore any time contained in a received message. In its stead, |
| 3046 |
record the time of reception on the local system. This circumvents |
| 3047 |
problems caused by remote hosts with skewed clocks. |
| 3048 |
|
| 3049 |
20.1 Configuration file |
| 3050 |
======================= |
| 3051 |
|
| 3052 |
‘syslogd’ reads its configuration file when it starts up and whenever it |
| 3053 |
receives a hangup signal. The ‘syslog.conf’ file is the main |
| 3054 |
configuration file for the ‘syslogd’ program. In addition, the server |
| 3055 |
looks below the directory ‘syslog.d/’ for further configuration files, |
| 3056 |
making it easy to arrange a common set of logging conventions in |
| 3057 |
‘syslog.conf’, augmented by system and service specific drop-in |
| 3058 |
configuration in ‘syslog.d/’. |
| 3059 |
|
| 3060 |
Each configuration file consists of lines with two fields: a |
| 3061 |
“selector” field which specifies the types of messages and priorities to |
| 3062 |
which the line applies, and an “action” field which specifies the action |
| 3063 |
to be taken if a message ‘syslogd’ receives matches the selection |
| 3064 |
criteria. The selector field is separated from the action field by one |
| 3065 |
or more tab or space characters. A rule can be split in several lines |
| 3066 |
if all lines except the last are terminated with a backslash ‘\’. |
| 3067 |
|
| 3068 |
There are two exceptional forms of line content. The first is the |
| 3069 |
“tagged selector”, and the second is a comment. The latter begins with |
| 3070 |
an octothorp (‘#’), also called hash, and continues until end-of-line. |
| 3071 |
|
| 3072 |
A tagged selector commences with an exclamation mark, as in ‘!name’, |
| 3073 |
or with a shebang, like ‘#! name’, and continues with a program name, a |
| 3074 |
“tag” in the sense used by ‘logger’. It has the effect of applying the |
| 3075 |
following configuration rules only to messages submitted with the |
| 3076 |
specified tag. This selection remains in effect until another tag is |
| 3077 |
selected, or until it is reset by means of stating the program name as |
| 3078 |
an asterisque ‘*’. |
| 3079 |
|
| 3080 |
The selector fields are encoded as a facility, followed by a period |
| 3081 |
(‘.’), and a level, with no intervening white-space. The facility as |
| 3082 |
well as the level are case insensitive. |
| 3083 |
|
| 3084 |
The facility describes the part of the system generating the message, |
| 3085 |
and is one of the following keywords: ‘auth’, ‘authpriv’, ‘cron’, |
| 3086 |
‘daemon’, ‘ftp’, ‘kern’, ‘lpr’, ‘mail’, ‘mark’, ‘news’, ‘syslog’, |
| 3087 |
‘user’, ‘uucp’ and ‘local0’ through ‘local7’. These keywords (with the |
| 3088 |
exception of ‘mark’) correspond to the similar ‘LOG_’ values specified |
| 3089 |
to the ‘openlog’ and ‘syslog’ library routines. *Note Syslog: |
| 3090 |
(libc)Syslog, for details. |
| 3091 |
|
| 3092 |
The level describes the severity of the message, and is a keyword |
| 3093 |
from the following ordered list (higher to lower): ‘emerg’, ‘alert’, |
| 3094 |
‘crit’, ‘err, warning’, ‘notice’, ‘info’ and ‘debug’. These keywords |
| 3095 |
correspond to the similar ‘LOG_’ values specified to the syslog library |
| 3096 |
routine. |
| 3097 |
|
| 3098 |
*Note syslog and vsyslog: (libc)syslog; vsyslog, for a further |
| 3099 |
descriptions of both the facility and level keywords and their |
| 3100 |
significance. |
| 3101 |
|
| 3102 |
If a received message matches the specified facility and is of the |
| 3103 |
specified level (or a higher level), the action specified in the action |
| 3104 |
field will be taken. |
| 3105 |
|
| 3106 |
Multiple selectors may be specified for a single action by separating |
| 3107 |
them with semicolon (‘;’) characters. It is important to note, however, |
| 3108 |
that each selector can modify the ones preceding it. |
| 3109 |
|
| 3110 |
Multiple facilities may be specified for a single level by separating |
| 3111 |
them with comma (‘,’) characters. |
| 3112 |
|
| 3113 |
An asterisk (‘*’) can be used to specify all facilities or all |
| 3114 |
levels. Two asterisks (‘**’) specifie all facilities not named |
| 3115 |
previously in the configuration file. |
| 3116 |
|
| 3117 |
By default, a level applies to all messages with the same or higher |
| 3118 |
level. The equal (‘=’) character can be prepended to a level to |
| 3119 |
restrict this line of the configuration file to messages with the very |
| 3120 |
same level. |
| 3121 |
|
| 3122 |
An exclamation mark (‘!’) prepended to a level or the asterisk means |
| 3123 |
that this line of the configuration file does not apply to the specified |
| 3124 |
level (and higher ones). In conjunction with the equal sign, you can |
| 3125 |
exclude single levels as well. |
| 3126 |
|
| 3127 |
The special facility ‘mark’ receives a message at priority ‘info’ |
| 3128 |
every 20 minutes. This is not enabled by a facility field containing an |
| 3129 |
asterisk. |
| 3130 |
|
| 3131 |
The special level ‘none’ disables a particular facility. |
| 3132 |
|
| 3133 |
The action field of each line specifies the action to be taken when |
| 3134 |
the selector field selects a message. There are five forms: |
| 3135 |
|
| 3136 |
• A pathname (beginning with a leading slash). Selected messages are |
| 3137 |
appended to the file. |
| 3138 |
|
| 3139 |
You may prepend a minus (‘-’) to the path to omit syncing the file |
| 3140 |
after each message log. This can cause data loss at system |
| 3141 |
crashes, but increases performance for programs which use logging |
| 3142 |
extensively. |
| 3143 |
|
| 3144 |
• A named pipe, beginning with a vertical bar (‘|’) followed by a |
| 3145 |
pathname. The pipe must be created with ‘mkfifo’ before ‘syslogd’ |
| 3146 |
reads its configuration file. This feature is especially useful |
| 3147 |
for debugging. |
| 3148 |
|
| 3149 |
• A hostname (preceded by an at (‘@’) sign). Selected messages are |
| 3150 |
forwarded to ‘syslogd’ on the named host. |
| 3151 |
|
| 3152 |
• A comma separated list of users. Selected messages are written to |
| 3153 |
those users if they are logged in. |
| 3154 |
|
| 3155 |
• An asterisk. Selected messages are written to all logged-in users. |
| 3156 |
|
| 3157 |
Blank lines and lines whose first non-blank character is a hash |
| 3158 |
(‘#’) character are ignored. |
| 3159 |
|
| 3160 |
A configuration file might appear as follows: |
| 3161 |
|
| 3162 |
# Log all kernel messages, authentication messages of |
| 3163 |
# level notice or higher and anything of level err or |
| 3164 |
# higher to the console. |
| 3165 |
# Don't log private authentication messages! |
| 3166 |
*.err;kern.*;auth.notice;authpriv.none /dev/console |
| 3167 |
|
| 3168 |
# Log anything (except mail) of level info or higher. |
| 3169 |
# Don't log private authentication messages! |
| 3170 |
*.info;mail.none;authpriv.none /var/log/messages |
| 3171 |
|
| 3172 |
# The authpriv file has restricted access. |
| 3173 |
authpriv.* /var/log/secure |
| 3174 |
|
| 3175 |
# Log all the mail messages in one place. |
| 3176 |
mail.* /var/log/maillog |
| 3177 |
|
| 3178 |
# Everybody gets emergency messages, plus log them on another |
| 3179 |
# machine. |
| 3180 |
*.emerg * |
| 3181 |
*.emerg @arpa.berkeley.edu |
| 3182 |
|
| 3183 |
# Root and Eric get alert and higher messages. |
| 3184 |
*.alert root,eric |
| 3185 |
|
| 3186 |
# Simplify security auditing, by collecting sudo uses. |
| 3187 |
! sudo |
| 3188 |
*.info /var/log/sudo |
| 3189 |
|
| 3190 |
# Collect time server reports. |
| 3191 |
#! ntpd |
| 3192 |
*.* /var/log/ntpd |
| 3193 |
|
| 3194 |
# Stop selecting on message tags. |
| 3195 |
!* |
| 3196 |
|
| 3197 |
# Save mail and news errors of level err and higher in a |
| 3198 |
# special file. |
| 3199 |
uucp,news.crit /var/log/spoolerr |
| 3200 |
|
| 3201 |
The effects of multiple selectors are sometimes not intuitive. For |
| 3202 |
example ‘mail.crit,*.err’ will select the ‘mail’ facility messages at |
| 3203 |
the level of ‘err’ or higher, not at the level of ‘crit’ or higher. |
| 3204 |
|
| 3205 |
|
| 3206 |
File: inetutils.info, Node: ftpd invocation, Next: rexecd invocation, Prev: syslogd invocation, Up: Top |
| 3207 |
|
| 3208 |
21 ‘ftpd’: FTP daemon |
| 3209 |
********************* |
| 3210 |
|
| 3211 |
‘ftpd’ is the Internet File Transfer Protocol server process. The |
| 3212 |
server uses the TCP protocol and listens at the port specified in the |
| 3213 |
‘ftp’ service specification. |
| 3214 |
|
| 3215 |
ftpd [OPTION]... |
| 3216 |
|
| 3217 |
‘-4’ |
| 3218 |
‘--ipv4’ |
| 3219 |
Daemon uses only IPv4 addressing. Ignored in inetd mode. |
| 3220 |
|
| 3221 |
‘-6’ |
| 3222 |
‘--ipv6’ |
| 3223 |
Daemon uses only IPv6 addressing. Ignored in inetd mode. |
| 3224 |
|
| 3225 |
‘-A’ |
| 3226 |
‘--anonymous-only’ |
| 3227 |
Only anonymous login is allowed. |
| 3228 |
|
| 3229 |
‘-a AUTH’ |
| 3230 |
‘--auth=AUTH’ |
| 3231 |
Specify what authentication mechanism to use for incoming |
| 3232 |
connections. Possible values are: ‘kerberos’, ‘kerberos5’, ‘opie’, |
| 3233 |
‘pam’, and ‘default’. |
| 3234 |
|
| 3235 |
Anonymous logins will continue to work when this option is used, |
| 3236 |
unless the user ‘ftp’ is removed from the system. |
| 3237 |
|
| 3238 |
‘-D’ |
| 3239 |
‘--daemon’ |
| 3240 |
‘ftpd’ enters daemon-mode. That allows ‘ftpd’ to be run without |
| 3241 |
‘inetd’. |
| 3242 |
|
| 3243 |
‘-d’ |
| 3244 |
‘--debug’ |
| 3245 |
Debugging information is written to the ‘syslog’ using facility |
| 3246 |
‘LOG_FTP’. |
| 3247 |
|
| 3248 |
‘-l’ |
| 3249 |
‘--logging’ |
| 3250 |
Each successful and failed ftp session is logged using ‘syslog’ |
| 3251 |
with a facility of ‘LOG_FTP’. If this option is specified twice, |
| 3252 |
the retrieve (‘get’), store (‘put’), append, delete, make |
| 3253 |
directory, remove directory and rename operations and their |
| 3254 |
filename arguments are also logged. |
| 3255 |
|
| 3256 |
‘--non-rfc2577’ |
| 3257 |
Do not follow the suggestion of RFC 2577 to suppress messages that |
| 3258 |
could help an attacker to conduct user name enumeration. This |
| 3259 |
option allows the server to return with an error message |
| 3260 |
immediately upon receipt of a user name. Such information includes |
| 3261 |
non-existence claims and expiration claims. The ideal mode would |
| 3262 |
otherwise be to fake the relevance of asking for a password, and |
| 3263 |
only thereafter report an invalid login. |
| 3264 |
|
| 3265 |
‘-p PIDFILE’ |
| 3266 |
‘--pidfile=PIDFILE’ |
| 3267 |
Change default location of PIDFILE. |
| 3268 |
|
| 3269 |
‘-q’ |
| 3270 |
‘--no-version’ |
| 3271 |
Quiet mode. No information about the version of the ‘ftpd’ is |
| 3272 |
given to the client. |
| 3273 |
|
| 3274 |
‘-T’ |
| 3275 |
‘--max-timeout’ |
| 3276 |
A client may also request a different timeout period; the maximum |
| 3277 |
period allowed may be set to timeout seconds with the ‘-T’ option. |
| 3278 |
The default limit is 2 hours. |
| 3279 |
|
| 3280 |
‘-t TIMEOUT’ |
| 3281 |
‘--timeout=TIMEOUT’ |
| 3282 |
The inactivity timeout period is set to timeout seconds (the |
| 3283 |
default is 15 minutes). |
| 3284 |
|
| 3285 |
‘-u UMASK’ |
| 3286 |
‘--umask=UMASK’ |
| 3287 |
Set default umask, expressed in base 8. |
| 3288 |
|
| 3289 |
The file ‘/etc/nologin’ can be used to disable FTP access. If the |
| 3290 |
file exists, ‘ftpd’ displays it and exits. If the file |
| 3291 |
‘/etc/ftpwelcome’ exists, ‘ftpd’ prints it before issuing the ‘ready’ |
| 3292 |
message. If the file ‘/etc/motd’ exists, ‘ftpd’ prints it after a |
| 3293 |
successful login. |
| 3294 |
|
| 3295 |
If this server was compiled with PAM support, then any non-anonymous |
| 3296 |
connection request will also be checked for settings pertaining to the |
| 3297 |
PAM service ‘ftp’, before finally being accepted. |
| 3298 |
|
| 3299 |
Linux-PAM is particular in that it also provides a module |
| 3300 |
‘pam_ftp.so’ influencing even anonymous access. By convention the |
| 3301 |
present server relies on the functionality in that module when built on |
| 3302 |
relevant systems. However, the module is known to be partially broken |
| 3303 |
since ten years back, when one compares the claims in its manual page, |
| 3304 |
so not all claimed trickery is available! |
| 3305 |
|
| 3306 |
21.1 Standards |
| 3307 |
============== |
| 3308 |
|
| 3309 |
The FTP server currently supports the following FTP requests. The |
| 3310 |
letter case of any request is ignored. |
| 3311 |
|
| 3312 |
Request Description |
| 3313 |
-------------------------------------------------------------------------- |
| 3314 |
ABOR abort previous command |
| 3315 |
ACCT specify account (ignored) |
| 3316 |
ALLO allocate storage (vacuously) |
| 3317 |
APPE append to a file |
| 3318 |
CDUP change to parent of current working directory |
| 3319 |
CWD change working directory |
| 3320 |
DELE delete a file |
| 3321 |
EPSV extended passive transfer request |
| 3322 |
EPRT specify data connection port |
| 3323 |
HELP give help information |
| 3324 |
LIST give list files in a directory ("ls -lgA") |
| 3325 |
LPRT specify data connection port |
| 3326 |
LPSV long passive transfer request |
| 3327 |
MKD make a directory |
| 3328 |
MDTM show last modification time of file |
| 3329 |
MODE specify data transfer mode |
| 3330 |
NLST give name list of files in directory |
| 3331 |
NOOP do nothing |
| 3332 |
PASS specify password |
| 3333 |
PASV prepare for server-to-server transfer |
| 3334 |
PORT specify data connection port |
| 3335 |
PWD print the current working directory |
| 3336 |
QUIT terminate session |
| 3337 |
REST restart incomplete transfer |
| 3338 |
RETR retrieve a file |
| 3339 |
RMD remove a directory |
| 3340 |
RNFR specify rename-from file name |
| 3341 |
RNTO specify rename-to file name |
| 3342 |
SITE non-standard commands |
| 3343 |
SIZE return size of file |
| 3344 |
STAT return status of server |
| 3345 |
STOR store a file |
| 3346 |
STOU store a file with a unique name |
| 3347 |
STRU specify data transfer structure |
| 3348 |
SYST show operating system type of server system |
| 3349 |
TYPE specify data transfer type |
| 3350 |
USER specify user name |
| 3351 |
XCUP change to parent of current working directory |
| 3352 |
(deprecated) |
| 3353 |
XCWD change working directory (deprecated) |
| 3354 |
XMKD make a directory (deprecated) |
| 3355 |
XPWD print the current working directory (deprecated) |
| 3356 |
XRMD remove a directory (deprecated) |
| 3357 |
|
| 3358 |
The following non-standard, or UNIX specific, commands are supported |
| 3359 |
by the ‘SITE’ request. |
| 3360 |
|
| 3361 |
Request Description |
| 3362 |
UMASK change umask, e.g. ‘SITE UMASK 002’ |
| 3363 |
IDLE set idle-timer, e.g. ‘SITE IDLE 60’ |
| 3364 |
CHMOD change mode of a file, e.g. ‘SITE CHMOD0 |
| 3365 |
0CHMOD1 1CHMOD2’ |
| 3366 |
HELP give help information. |
| 3367 |
|
| 3368 |
The remaining FTP requests specified in RFC 959 are recognized, but |
| 3369 |
not implemented. The extensions ‘MDTM’, ‘REST’, and ‘SIZE’ are |
| 3370 |
specified in RFC 3659, while ‘EPRT’ and ‘EPSV’ appear in RFC 2428, |
| 3371 |
‘LPRT’ and ‘LPSV’ in RFC 1639. |
| 3372 |
|
| 3373 |
The ftp server will abort an active file transfer only when the |
| 3374 |
‘ABOR’ command is preceded by a Telnet ‘Interrupt Process’ (IP) signal |
| 3375 |
and a Telnet ‘Synch’ signal in the command Telnet stream, as described |
| 3376 |
in Internet RFC 959. If a ‘STAT’ command is received during a data |
| 3377 |
transfer, preceded by a Telnet IP and Synch, transfer status will be |
| 3378 |
returned. |
| 3379 |
|
| 3380 |
‘ftpd’ interprets file names according to the globbing conventions |
| 3381 |
used by ‘csh’. This allows users to utilize the metacharacters |
| 3382 |
‘*?[]{}~’. |
| 3383 |
|
| 3384 |
The server applies the suggestions in RFC 2577, but the legacy |
| 3385 |
behaviour with informational content in denials can be restored using |
| 3386 |
the option ‘--non-rfc2577’. |
| 3387 |
|
| 3388 |
21.2 Authentication |
| 3389 |
=================== |
| 3390 |
|
| 3391 |
‘ftpd’ authenticates users according to four rules. |
| 3392 |
|
| 3393 |
1. The login name must be in the password data base, ‘/etc/passwd’, |
| 3394 |
and must not have a null password. In this case a password must be |
| 3395 |
provided by the client before any file operations can be performed. |
| 3396 |
|
| 3397 |
2. The login name must not appear in the file ‘/etc/ftpusers’. |
| 3398 |
|
| 3399 |
3. The user must have a standard shell. If the file ‘/etc/shells’ |
| 3400 |
exists and is readable, only programs listed there are considered |
| 3401 |
standard shells. ‘ftpd’ uses the C library function ‘getusershell’ |
| 3402 |
to enumerate standard shells. Standard shells are also known as |
| 3403 |
valid login shells, valid user shells, or permitted user shells. |
| 3404 |
|
| 3405 |
4. If the user name is ‘anonymous’ or ‘ftp’, an anonymous ftp account |
| 3406 |
must be present in the password file (user ‘ftp’). In this case |
| 3407 |
the user is allowed to log in by specifying any password (by |
| 3408 |
convention an email address for the user should be used as the |
| 3409 |
password). |
| 3410 |
|
| 3411 |
A further access mechanism is provided by the file ‘/etc/ftpchroot’. |
| 3412 |
A user mentioned therein will have all access confined to the subtree |
| 3413 |
rooted at the home directory specified in ‘/etc/passwd’. |
| 3414 |
|
| 3415 |
In the case of anonymous access, ‘ftpd’ takes special measures to |
| 3416 |
restrict the client's access privileges. The server always performs a |
| 3417 |
chroot to the home directory of the ‘ftp’ user. |
| 3418 |
|
| 3419 |
In order that system security is not breached, it is recommended that |
| 3420 |
the ‘ftp’ subtree be constructed with care, following these rules: |
| 3421 |
|
| 3422 |
‘~ftp’ |
| 3423 |
Make the home directory owned by ‘root’ and not writable by anyone. |
| 3424 |
|
| 3425 |
‘~ftp/bin’ |
| 3426 |
Make this directory owned by ‘root’ and not writable by anyone |
| 3427 |
(mode 555). The program ‘ls’ must be present to support the list |
| 3428 |
command, unless the server was compiled with libls support. This |
| 3429 |
program should be mode 111. |
| 3430 |
|
| 3431 |
‘~ftp/etc’ |
| 3432 |
Make this directory owned by ‘root’ and not writable by anyone |
| 3433 |
(mode 555). The files ‘passwd’ and ‘group’ must be present for the |
| 3434 |
‘ls’ command to be able to produce owner names rather than numbers. |
| 3435 |
The password field in ‘passwd’ is not used, and should not contain |
| 3436 |
real passwords. The file ‘motd’, if present, will be printed after |
| 3437 |
a successful login. These files should be mode 444. |
| 3438 |
|
| 3439 |
‘~ftp/pub’ |
| 3440 |
Make this directory mode 777 and owned by ‘ftp’. Guests can then |
| 3441 |
place files which are to be accessible via the anonymous account in |
| 3442 |
this directory. |
| 3443 |
|
| 3444 |
21.3 Configuration files |
| 3445 |
======================== |
| 3446 |
|
| 3447 |
‘‘/etc/ftpchroot’’ |
| 3448 |
List of users to enclose in a chrooted directory. The anonymous |
| 3449 |
user ‘ftp’ is always considered to be a member of this list, |
| 3450 |
explicit or not. |
| 3451 |
|
| 3452 |
‘‘/etc/ftpusers’’ |
| 3453 |
List of unwelcome/restricted users, always to be denied access. |
| 3454 |
|
| 3455 |
‘‘/etc/ftpwelcome’’ |
| 3456 |
Welcome notice printed before server identification and any |
| 3457 |
authentication exchange. |
| 3458 |
|
| 3459 |
‘‘/etc/motd’’ |
| 3460 |
Welcome notice presented after completed login. |
| 3461 |
|
| 3462 |
‘‘/etc/nologin’’ |
| 3463 |
If present, the contents are displayed and all further access is |
| 3464 |
refused. |
| 3465 |
|
| 3466 |
21.4 File format of ftpusers and ftpchroot |
| 3467 |
========================================== |
| 3468 |
|
| 3469 |
The files ‘/etc/ftpusers’ and ‘/etc/ftpchroot’ share a common file |
| 3470 |
format. For better conformity with other implementations, each line is |
| 3471 |
understood as consisting of fields separated by spaces, or by horizontal |
| 3472 |
tabulators. Only the first non-empty field is examined at present. |
| 3473 |
Both files are used for matching against a user name, desiring to use |
| 3474 |
the FTP service. |
| 3475 |
|
| 3476 |
Whenever the first printable character is a hash ‘#’, the input line |
| 3477 |
is taken as a comment, and is ignored. Lines lacking non-empty fields |
| 3478 |
are likewise ignored. |
| 3479 |
|
| 3480 |
A field consisting of a single at-sign ‘@’, is treated as a wildcard |
| 3481 |
and matches every input. |
| 3482 |
|
| 3483 |
A field commencing with an at-sign ‘@’ and then continuing with an |
| 3484 |
identifier, is understood as giving the name of a group. Should this |
| 3485 |
name exist in ‘/etc/groups’, and the user name be a member of this same |
| 3486 |
group, then the user name matches. |
| 3487 |
|
| 3488 |
In all other cases, the field is taken as the identifier of a user, |
| 3489 |
with which the requesting user is compared for verbatim match. |
| 3490 |
|
| 3491 |
It is worthwhile to observe from the above cases, that a single ‘@’ |
| 3492 |
on a line by itself in ‘/etc/ftpchroot’, will enforce chrooting upon |
| 3493 |
every user allowed to access the FTP service. This gives a Draconian, |
| 3494 |
protective configuration. |
| 3495 |
|
| 3496 |
|
| 3497 |
File: inetutils.info, Node: rexecd invocation, Next: rlogind invocation, Prev: ftpd invocation, Up: Top |
| 3498 |
|
| 3499 |
22 ‘rexecd’: server for ‘rexec’ |
| 3500 |
******************************* |
| 3501 |
|
| 3502 |
‘rexecd’ is the server for the ‘rexec’ routine. The server provides |
| 3503 |
remote execution facilities with authentication based on user names and |
| 3504 |
passwords. It passes error messages and notices to the ‘syslog’ |
| 3505 |
facility ‘LOG_DAEMON’. |
| 3506 |
|
| 3507 |
rexecd [OPTION]... |
| 3508 |
|
| 3509 |
‘rexecd’ listens for service requests at the port indicated in the |
| 3510 |
‘exec’ service specification. When a service request is received the |
| 3511 |
following protocol is initiated: |
| 3512 |
|
| 3513 |
1. The server reads characters from the socket up to a NUL (‘\0’) |
| 3514 |
byte. The resultant string is interpreted as an ASCII number, base |
| 3515 |
10. |
| 3516 |
|
| 3517 |
2. If the number received in step 1 is non-zero, it is interpreted as |
| 3518 |
the port number of a secondary stream to be used for the stderr. A |
| 3519 |
second connection is then created to the specified port on the |
| 3520 |
client's machine. |
| 3521 |
|
| 3522 |
3. A NUL terminated user name of at most 16 characters is retrieved on |
| 3523 |
the initial socket. |
| 3524 |
|
| 3525 |
4. A NUL terminated, unencrypted password of at most 16 characters is |
| 3526 |
retrieved on the initial socket. |
| 3527 |
|
| 3528 |
5. A NUL terminated command to be passed to a shell is retrieved on |
| 3529 |
the initial socket. The length of the command is limited by the |
| 3530 |
upper bound on the size of the system's argument list. |
| 3531 |
|
| 3532 |
6. ‘rexecd’ then validates the user as is done at login time and, if |
| 3533 |
the authentication was successful, changes to the user's home |
| 3534 |
directory, and establishes the user and group protections of the |
| 3535 |
user. If any of these steps fail the connection is aborted with a |
| 3536 |
diagnostic message returned. |
| 3537 |
|
| 3538 |
7. A NUL byte is returned on the initial socket and the command line |
| 3539 |
is passed to the normal login shell of the user. The shell |
| 3540 |
inherits the network connections established by rexecd. |
| 3541 |
|
| 3542 |
22.1 Invoking |
| 3543 |
============= |
| 3544 |
|
| 3545 |
The only option is as follows: |
| 3546 |
|
| 3547 |
‘-l’ |
| 3548 |
‘--logging’ |
| 3549 |
Raise logging level for this service; use more than once for |
| 3550 |
increased verbosity. The ‘syslog’ facility in use is ‘LOG_DAEMON’. |
| 3551 |
|
| 3552 |
Should ‘rexecd’ have been built with PAM support, it reads any |
| 3553 |
setting specified for a service named ‘rexec’. |
| 3554 |
|
| 3555 |
22.2 Diagnostics |
| 3556 |
================ |
| 3557 |
|
| 3558 |
Except for the last one listed below, all diagnostic messages are |
| 3559 |
returned on the initial socket, after which any network connections are |
| 3560 |
closed. An error is indicated by a leading byte with a value of 1 (0 is |
| 3561 |
returned in step 7 above upon successful completion of all the steps |
| 3562 |
prior to the command execution). |
| 3563 |
|
| 3564 |
‘username too long’ |
| 3565 |
The name is longer than 16 characters. |
| 3566 |
|
| 3567 |
‘password too long’ |
| 3568 |
The password is longer than 16 characters. |
| 3569 |
|
| 3570 |
‘command too long’ |
| 3571 |
The command line passed exceeds the size of the argument list (as |
| 3572 |
configured into the system). |
| 3573 |
|
| 3574 |
‘Login incorrect.’ |
| 3575 |
No password file entry for the user name existed. |
| 3576 |
|
| 3577 |
‘Password incorrect.’ |
| 3578 |
The wrong password was supplied. |
| 3579 |
|
| 3580 |
‘No remote directory.’ |
| 3581 |
The chdir command to the home directory failed. |
| 3582 |
|
| 3583 |
‘Try again.’ |
| 3584 |
A fork by the server failed. |
| 3585 |
|
| 3586 |
‘<shellname>: ...’ |
| 3587 |
The user's login shell could not be started. This message is |
| 3588 |
returned on the connection associated with the stderr, and is not |
| 3589 |
... |
| 3590 |
|
| 3591 |
_Note_, that indicating ‘Login incorrect’ as opposed to ‘Password |
| 3592 |
incorrect’ is a security breach which allows people to probe a system |
| 3593 |
for users with null passwords. |
| 3594 |
|
| 3595 |
|
| 3596 |
File: inetutils.info, Node: rlogind invocation, Next: rshd invocation, Prev: rexecd invocation, Up: Top |
| 3597 |
|
| 3598 |
23 ‘rlogind’: Remote login server |
| 3599 |
********************************* |
| 3600 |
|
| 3601 |
‘rlogind’ is the server for the ‘rlogin’ client program (*note rlogin |
| 3602 |
invocation::). The server provides a remote login facility with |
| 3603 |
authentication based on privileged port numbers from trusted hosts, or |
| 3604 |
using authentication according to a Kerberos protocol. |
| 3605 |
|
| 3606 |
‘rlogind’ in daemon mode listens for service requests at the port |
| 3607 |
indicated in the ‘login’ service specification. A common alternative is |
| 3608 |
to have the super-server ‘inetd’ listen at the same port, which then |
| 3609 |
invokes ‘rlogind’ as demand arises. In Kerberised mode, the port is |
| 3610 |
either ‘eklogin’, or ‘klogin’, depending on preset encryption, or none. |
| 3611 |
|
| 3612 |
The standard authentication procedure assumes the integrity of each |
| 3613 |
client machine and of the connecting medium. This is insecure, since it |
| 3614 |
transmits credentials in clear text, but is useful in an "open" |
| 3615 |
environment. This weakness is reduced when running the service in |
| 3616 |
Kerberised version, at the price of a larger complexity of the |
| 3617 |
supporting infrastructure. Using an encrypting Kerberised service even |
| 3618 |
avoids all clear text processing. |
| 3619 |
|
| 3620 |
23.1 Invoking |
| 3621 |
============= |
| 3622 |
|
| 3623 |
The available options are as follows: |
| 3624 |
|
| 3625 |
‘-4’ |
| 3626 |
‘--ipv4’ |
| 3627 |
Accept only IPv4 connections in daemon mode. |
| 3628 |
|
| 3629 |
‘-6’ |
| 3630 |
‘--ipv6’ |
| 3631 |
Only IPv6 connections in daemon mode. |
| 3632 |
|
| 3633 |
‘-a’ |
| 3634 |
‘--verify-hostname’ |
| 3635 |
Ask hostname for verification. |
| 3636 |
|
| 3637 |
‘-d[MAX]’ |
| 3638 |
‘--daemon[=MAX]’ |
| 3639 |
Run in background daemon mode, optionally setting the maximal |
| 3640 |
number of simultaneously running client sessions. The default |
| 3641 |
limit is 10. |
| 3642 |
|
| 3643 |
‘-D[LEVEL]’ |
| 3644 |
‘--debug[=LEVEL]’ |
| 3645 |
Set debug level, not implemented. |
| 3646 |
|
| 3647 |
‘-l’ |
| 3648 |
‘--no-rhosts’ |
| 3649 |
Ignore client's ‘.rhosts’ file. |
| 3650 |
|
| 3651 |
‘-L NAME’ |
| 3652 |
‘--local-domain=NAME’ |
| 3653 |
Set local domain name, to which the server host belongs. By |
| 3654 |
default the domain is recovered from the canonical name of the |
| 3655 |
host. |
| 3656 |
|
| 3657 |
‘-n’ |
| 3658 |
‘--no-keepalive’ |
| 3659 |
Do not set SO_KEEPALIVE on sockets. This decreases the ability to |
| 3660 |
close lost connections to once active clients. |
| 3661 |
|
| 3662 |
‘-o’ |
| 3663 |
‘--allow-root’ |
| 3664 |
Allow the root user to login, which is disallowed by default. |
| 3665 |
|
| 3666 |
‘-p PORT’ |
| 3667 |
‘--port=PORT’ |
| 3668 |
Listen on given port. Applicable only in daemon mode. |
| 3669 |
|
| 3670 |
‘-r’ |
| 3671 |
‘--reverse-required’ |
| 3672 |
Require reverse resolvability of remote host's numerical IP. |
| 3673 |
|
| 3674 |
For sites requiring improved authentication, Kerberos authentication |
| 3675 |
is a viable decision, and possibly even with encryption for enhanced |
| 3676 |
integrity. Three additional options are available for an executable |
| 3677 |
‘rlogind’ compiled with Kerberos support. |
| 3678 |
|
| 3679 |
‘-k’ |
| 3680 |
‘--kerberos’ |
| 3681 |
Activate Kerberos authentication on all incoming requests. |
| 3682 |
|
| 3683 |
‘-S NAME’ |
| 3684 |
‘--server-principal=NAME’ |
| 3685 |
Set Kerberos server name, overriding canonical hostname. |
| 3686 |
|
| 3687 |
‘-x’ |
| 3688 |
‘--encrypt’ |
| 3689 |
Activate encryption of all data passed via the ‘rlogind’ session. |
| 3690 |
This may impact response time and CPU utilization, but provides |
| 3691 |
increased security. Only for Kerberised mode of operation. |
| 3692 |
|
| 3693 |
Should ‘rlogind’ have been built with PAM support, it reads any |
| 3694 |
setting specified for a service named either ‘rlogin’ or ‘krlogin’, the |
| 3695 |
latter name for clients using Kerberised authentication. |
| 3696 |
|
| 3697 |
23.2 Kerberos specific details |
| 3698 |
============================== |
| 3699 |
|
| 3700 |
The option ‘-k’ is mandatory for Kerberised operation mode, while |
| 3701 |
addition of the option ‘-x’ will also demand encryption of every request |
| 3702 |
to this particular server. |
| 3703 |
|
| 3704 |
‘rlogind’ will, in Kerberised operation mode, as default instantiate |
| 3705 |
itself using the principal name ‘host/canonical_name@DEFAULT_REALM’, a |
| 3706 |
compound arranged from the running host's canonical name, and from the |
| 3707 |
default realm configured for the system. Either of these can be |
| 3708 |
overridden using the option ‘--server-principal’, as follows: |
| 3709 |
|
| 3710 |
rlogind -k -S alias.server.our |
| 3711 |
rlogind --kerberos [email protected] |
| 3712 |
rlogind -k -x -S rlogin/[email protected] |
| 3713 |
|
| 3714 |
When overriding only the realm, with the option ‘-S’, an initial |
| 3715 |
at-sign is mandatory. |
| 3716 |
|
| 3717 |
23.3 Protocol details |
| 3718 |
===================== |
| 3719 |
|
| 3720 |
When a service request is received, in non-Kerberised mode, the |
| 3721 |
following protocol is initiated: |
| 3722 |
|
| 3723 |
1. The server checks the client's source port. If the port is not in |
| 3724 |
the range 512-1023, the server aborts the connection. |
| 3725 |
|
| 3726 |
2. The server next checks the client's source address and requests the |
| 3727 |
corresponding host name. If the hostname cannot be determined, the |
| 3728 |
numerical representation of the host address is used. If the |
| 3729 |
hostname is in the same domain as the server (according to the last |
| 3730 |
two components of the domain name), or if the option ‘-a’ is in |
| 3731 |
effect, the address for the hostname is requested, verifying that |
| 3732 |
the name and address correspond. Normal authentication is |
| 3733 |
considered as failed, should this address verification fail. |
| 3734 |
|
| 3735 |
Once the source port and address have been checked, ‘rlogind’ |
| 3736 |
proceeds with the authentication process as described in *note rshd |
| 3737 |
invocation::. The server then allocates a pseudo terminal, and |
| 3738 |
manipulates file descriptors so that the slave half of the pseudo |
| 3739 |
terminal becomes the stdin, stdout, and stderr for a login process. The |
| 3740 |
login process is an instance of the ‘login’ program, invoked with the |
| 3741 |
option ‘-f’ if authentication had succeeded. If automatic |
| 3742 |
authentication had failed, the user is prompted to log in as if on a |
| 3743 |
standard terminal line. |
| 3744 |
|
| 3745 |
The parent of the login process manipulates the master side of the |
| 3746 |
pseudo terminal, operating as an intermediary between the login process |
| 3747 |
and the client instance of the rlogin program. In normal operation, the |
| 3748 |
packet protocol described in ‘PTY’ is invoked to provide flow control |
| 3749 |
using ‘C-S’/‘C-Q’, and to propagate interrupt signals to the remote |
| 3750 |
program. The login process transmits the client terminal's baud rate, |
| 3751 |
and its terminal type, as found in the environment variable ‘TERM’. The |
| 3752 |
screen or window size of the terminal is requested from the client, and |
| 3753 |
any later window size changes at the client's side are propagated to the |
| 3754 |
pseudo terminal as well. |
| 3755 |
|
| 3756 |
Transport-level keepalive messages are enabled unless the option ‘-n’ |
| 3757 |
was in effect when starting ‘rlogind’. The use of keepalive messages |
| 3758 |
allows sessions to be timed out, should the client crash, or otherwise |
| 3759 |
become unreachable. |
| 3760 |
|
| 3761 |
*Note ruserok: (libc)ruserok, for details. |
| 3762 |
|
| 3763 |
23.4 Diagnostics |
| 3764 |
================ |
| 3765 |
|
| 3766 |
The exchange protocol states that a negotiation reaches a successful |
| 3767 |
completion as soon as the server ‘rlogind’ transmits back to the client |
| 3768 |
a single null byte, marking the completion of all information exchange. |
| 3769 |
|
| 3770 |
Error conditions are instead transmitted back to the client as a |
| 3771 |
message containing an initial byte value 1, followed by a C-string |
| 3772 |
indicating the cause of failure. All network connections are closed at |
| 3773 |
the server side after this message. Some common messages follow: |
| 3774 |
|
| 3775 |
‘Permission denied.’ |
| 3776 |
The client presented insufficient credentials, or the client's |
| 3777 |
address is not sufficiently resolvable to pass the checks induced |
| 3778 |
by options ‘-a’ or ‘-r’. |
| 3779 |
|
| 3780 |
‘Try again.’ |
| 3781 |
A fork by the server failed. |
| 3782 |
|
| 3783 |
|
| 3784 |
File: inetutils.info, Node: rshd invocation, Next: talkd invocation, Prev: rlogind invocation, Up: Top |
| 3785 |
|
| 3786 |
24 ‘rshd’: Remote shell server |
| 3787 |
****************************** |
| 3788 |
|
| 3789 |
The ‘rshd’ server is the server for the ‘rcmd’ routine and, |
| 3790 |
consequently, for the ‘rsh’ (*note rsh invocation::) program. The |
| 3791 |
server provides remote execution facilities with authentication based on |
| 3792 |
privileged port numbers from trusted hosts. The ‘rshd’ server listens |
| 3793 |
for service requests at the port indicated in the ‘cmd’ service |
| 3794 |
specification. When a service request is received the following |
| 3795 |
protocol is initiated: |
| 3796 |
|
| 3797 |
1. The server checks the client's source port. If the port is not in |
| 3798 |
the range 512-1023, the server aborts the connection. However, |
| 3799 |
this condition is not applied for Kerberized service. |
| 3800 |
|
| 3801 |
2. The server reads characters from the socket up to a NUL (‘\0’) |
| 3802 |
byte. The resultant string is interpreted as an ASCII number, base |
| 3803 |
10. |
| 3804 |
|
| 3805 |
3. If the number received in step 2 is non-zero, it is interpreted as |
| 3806 |
the port number of a secondary stream to be used for the stderr. A |
| 3807 |
second connection is then created to the specified port on the |
| 3808 |
client's machine. The source port of this second connection is |
| 3809 |
also in the range 512-1023. |
| 3810 |
|
| 3811 |
4. The server checks the client's source address and requests the |
| 3812 |
corresponding host name. If the hostname cannot be determined, the |
| 3813 |
dot-notation representation of the host address is used. If the |
| 3814 |
hostname is in the same domain as the server (according to the last |
| 3815 |
two components of the domain name), or if the ‘-a’ option is given, |
| 3816 |
the addresses for the hostname are requested, verifying that the |
| 3817 |
name and address correspond. If address verification fails, the |
| 3818 |
connection is aborted with the message, ‘Host address mismatch.’ |
| 3819 |
|
| 3820 |
5. A null terminated user name of at most 16 characters is retrieved |
| 3821 |
on the initial socket. This user name is interpreted as the user |
| 3822 |
identity on the client's machine. |
| 3823 |
|
| 3824 |
6. A null terminated user name of at most 16 characters is retrieved |
| 3825 |
on the initial socket. This user name is interpreted as a user |
| 3826 |
identity to use on the server's machine. |
| 3827 |
|
| 3828 |
7. A null terminated command to be passed to a shell is retrieved on |
| 3829 |
the initial socket. The length of the command is limited by the |
| 3830 |
upper bound on the size of the system's argument list. |
| 3831 |
|
| 3832 |
8. Rshd then validates the user using ‘ruserok’, which uses the file |
| 3833 |
‘/etc/hosts.equiv’ and the ‘.rhosts’ file found in the user's home |
| 3834 |
directory. The ‘-l’ option prevents ‘ruserok’ from doing any |
| 3835 |
validation based on the user's ‘.rhosts’ file, unless the user is |
| 3836 |
the superuser. |
| 3837 |
|
| 3838 |
9. If the file ‘/etc/nologin’ exists and the user is not the |
| 3839 |
superuser, the connection is closed. |
| 3840 |
|
| 3841 |
10. A null byte is returned on the initial socket and the command line |
| 3842 |
is passed to the normal login shell of the user. The shell |
| 3843 |
inherits the network connections established by ‘rshd’. |
| 3844 |
|
| 3845 |
11. Transport-level keepalive messages are enabled unless the ‘-n’ |
| 3846 |
option is present. The use of keepalive messages allows sessions |
| 3847 |
to be timed out if the client crashes or becomes unreachable. |
| 3848 |
|
| 3849 |
12. The ‘-L’ option causes all successful accesses to be logged to |
| 3850 |
‘syslogd’ (*note syslogd invocation::) as ‘auth.info’ messages. |
| 3851 |
|
| 3852 |
*Note ruserok: (libc)ruserok, for details. |
| 3853 |
|
| 3854 |
24.1 Invoking |
| 3855 |
============= |
| 3856 |
|
| 3857 |
The options are as follows: |
| 3858 |
|
| 3859 |
‘-a’ |
| 3860 |
‘--verify-hostname’ |
| 3861 |
Ask hostname for verification. |
| 3862 |
|
| 3863 |
‘-k’ |
| 3864 |
‘--kerberos’ |
| 3865 |
Use Kerberos authentication. |
| 3866 |
|
| 3867 |
‘-l’ |
| 3868 |
‘--no-rhosts’ |
| 3869 |
Ignore ‘.rhosts’ file. |
| 3870 |
|
| 3871 |
‘-L’ |
| 3872 |
‘--log-sessions’ |
| 3873 |
Log successful logins. |
| 3874 |
|
| 3875 |
‘-n’ |
| 3876 |
‘--no-keepalive’ |
| 3877 |
Do not set SO_KEEPALIVE. |
| 3878 |
|
| 3879 |
‘-S NAME’ |
| 3880 |
‘--servername=NAME’ |
| 3881 |
Set Kerberos server name, overriding canonical hostname. |
| 3882 |
|
| 3883 |
‘-v’ |
| 3884 |
‘--vacuous’ |
| 3885 |
Fail any call asking for non-Kerberos authentication. |
| 3886 |
|
| 3887 |
‘-r’ |
| 3888 |
‘--reverse-required’ |
| 3889 |
Demand that the client's IP address be resolvable as a host name. |
| 3890 |
|
| 3891 |
Should ‘rshd’ have been built with PAM support, it reads any setting |
| 3892 |
specified for a service named either ‘rsh’ or ‘krsh’, the latter name |
| 3893 |
for clients seeking Kerberised authentication. |
| 3894 |
|
| 3895 |
24.2 Diagnostics |
| 3896 |
================ |
| 3897 |
|
| 3898 |
Except for the last one listed below, all diagnostic messages are |
| 3899 |
returned on the initial socket, after which any network connections are |
| 3900 |
closed. An error is indicated by a leading byte with a value of 1 (0 is |
| 3901 |
returned in step 10 above upon successful completion of all the steps |
| 3902 |
prior to the execution of the login shell). |
| 3903 |
|
| 3904 |
‘Locuser too long’ |
| 3905 |
The name of the user on the client's machine is longer than 16 |
| 3906 |
characters. |
| 3907 |
|
| 3908 |
‘Ruser too long’ |
| 3909 |
The name of the user on the remote machine is longer than 16 |
| 3910 |
characters. |
| 3911 |
|
| 3912 |
‘Command too long’ |
| 3913 |
The command line passed exceeds the size of the argument list (as |
| 3914 |
configured into the system). |
| 3915 |
|
| 3916 |
‘Login incorrect’ |
| 3917 |
No password file entry for the user name existed. |
| 3918 |
|
| 3919 |
‘Remote directory’ |
| 3920 |
The chdir command to the home directory failed. |
| 3921 |
|
| 3922 |
‘Permission denied’ |
| 3923 |
The authentication procedure described above failed, or address |
| 3924 |
resolution was insufficient. |
| 3925 |
|
| 3926 |
‘Can't make pipe.’ |
| 3927 |
The pipe needed for the stderr, wasn't created. |
| 3928 |
|
| 3929 |
‘Can't fork; try again.’ |
| 3930 |
A fork by the server failed. |
| 3931 |
|
| 3932 |
‘<shellname>: ...’ |
| 3933 |
The user's login shell could not be started. This message is |
| 3934 |
returned on the connection associated with the stderr, and is not |
| 3935 |
preceded by a flag byte. |
| 3936 |
|
| 3937 |
The authentication procedure used here assumes the integrity of each |
| 3938 |
client machine and the connecting medium. This is insecure, but is |
| 3939 |
useful in an "open" environment. |
| 3940 |
|
| 3941 |
|
| 3942 |
File: inetutils.info, Node: talkd invocation, Next: telnetd invocation, Prev: rshd invocation, Up: Top |
| 3943 |
|
| 3944 |
25 ‘talkd’: a server for communication between users |
| 3945 |
**************************************************** |
| 3946 |
|
| 3947 |
‘talkd’ is a server that notifies users that someone else wants to |
| 3948 |
initiate a conversation. It acts as a repository of invitations, |
| 3949 |
responding to requests by clients wishing to rendezvous for a |
| 3950 |
conversation. |
| 3951 |
|
| 3952 |
This implementation uses the newer protocol ‘ntalk/udp’, and is |
| 3953 |
intended to be invoked by a super-server ‘inetd’ at that datagram port. |
| 3954 |
It is recommended that ‘inetd’ launch ‘talkd’ with ownership |
| 3955 |
‘nobody:tty’, or with ‘tty:tty’. However, this works with ACL only if |
| 3956 |
‘.talkrc’ can be assumed to be world readable for all users. This |
| 3957 |
failing, the process ownership will need to be ‘root:tty’ if the |
| 3958 |
ACL-mechanism is to be usable and trustworthy. |
| 3959 |
|
| 3960 |
Keep in mind that this service is usable with IPv4 only, since the |
| 3961 |
exchange protocol was conceived to handle only this particular address |
| 3962 |
family. This fact is independent of the abilities of ‘inetd’. |
| 3963 |
|
| 3964 |
Observe also that the server ‘talkd’ depends on the name returned by |
| 3965 |
‘hostname’, for establishing connections between interested parties. A |
| 3966 |
server ‘talkd’ running on a multi-homed host is not able to respond to |
| 3967 |
invitations for a valid host name that differs from the name reported by |
| 3968 |
‘hostname’. |
| 3969 |
|
| 3970 |
The present implementation offers ACL-mechanisms for fine grained |
| 3971 |
access control. |
| 3972 |
|
| 3973 |
25.1 Invoking |
| 3974 |
============= |
| 3975 |
|
| 3976 |
The following switches and options are available. |
| 3977 |
|
| 3978 |
‘-a FILE’ |
| 3979 |
‘--acl=FILE’ |
| 3980 |
Read site-wide ACLs from FILE. |
| 3981 |
|
| 3982 |
‘-d’ |
| 3983 |
‘--debug’ |
| 3984 |
Enable debugging. |
| 3985 |
|
| 3986 |
‘-i SECONDS’ |
| 3987 |
‘--idle-timeout=SECONDS’ |
| 3988 |
Set idle timeout length |
| 3989 |
|
| 3990 |
‘-l’ |
| 3991 |
‘--logging’ |
| 3992 |
Enable a somewhat enhanced logging verbosity, reporting attempted |
| 3993 |
and dropped connections, as well as some more unexpected events |
| 3994 |
that might arise. |
| 3995 |
|
| 3996 |
‘-r SECONDS’ |
| 3997 |
‘--request-ttl=SECONDS’ |
| 3998 |
Set time-to-live length for requests. |
| 3999 |
|
| 4000 |
‘-S’ |
| 4001 |
‘--strict-policy’ |
| 4002 |
Apply strict ACL policy on this system. This means that the |
| 4003 |
site-wide ACL must provide explicit ‘allow’ rules for admitting |
| 4004 |
traffic at all. |
| 4005 |
|
| 4006 |
‘-t SECONDS’ |
| 4007 |
‘--timeout=SECONDS’ |
| 4008 |
Set timeout length. |
| 4009 |
|
| 4010 |
25.2 Modus operandi |
| 4011 |
=================== |
| 4012 |
|
| 4013 |
In normal operation, a client, the caller, initiates a rendezvous by |
| 4014 |
sending a ‘CTL_MSG’ of type ‘LOOK_UP’ to the server (see |
| 4015 |
‘protocols/talkd.h’). This causes the server to search its invitation |
| 4016 |
tables to check whether an invitation currently exists for the caller |
| 4017 |
(wanting to talk to the callee specified in the message). If the lookup |
| 4018 |
fails, the caller then sends an ‘ANNOUNCE’ message causing the server to |
| 4019 |
broadcast an announcement on the callee's login ports requesting |
| 4020 |
contact. When the callee responds, the local server uses the recorded |
| 4021 |
invitation to respond with the appropriate rendezvous address and the |
| 4022 |
caller and callee client programs establish a stream connection through |
| 4023 |
which the conversation takes place. |
| 4024 |
|
| 4025 |
This implementation offers an additional mechanism, whereby a |
| 4026 |
site-wide access control list can be used to limit service access in |
| 4027 |
general. For any local user, i.e., present on the server's system, a |
| 4028 |
further user owned file ‘.talkrc’ is parsed, if at all present, in order |
| 4029 |
to even further fine tune access to this particular user. |
| 4030 |
|
| 4031 |
25.3 Access control in talkd |
| 4032 |
============================ |
| 4033 |
|
| 4034 |
The server can be run in a mode with additional access control, beyond |
| 4035 |
the legacy capabilities of ‘ntalkd’. This is activated using the option |
| 4036 |
‘-a’, or equivalently ‘--acl’. |
| 4037 |
|
| 4038 |
The format of this access control list is shared with the user |
| 4039 |
specific file ‘.talkrc’. Normally the site-wide setting operates with a |
| 4040 |
default value ‘allow’, but specifying the option ‘-S’, or |
| 4041 |
‘--strict-policy’, changes this default action to ‘deny’. In addition, |
| 4042 |
the strict policy disables the possibility that an allowing action from |
| 4043 |
the user specific ACL be able to override a denial resulting from the |
| 4044 |
system-wide ACL setting. |
| 4045 |
|
| 4046 |
As is usual, indentation, empty lines, and lines whose first |
| 4047 |
printable character is the hash character, are all ignored. The general |
| 4048 |
line format is |
| 4049 |
|
| 4050 |
action user-exp [net-exp ...] |
| 4051 |
|
| 4052 |
Each active line must contain at least two fields: an ‘action’ and a |
| 4053 |
‘user-exp’. |
| 4054 |
|
| 4055 |
The first field, ‘action’, must be either of ‘allow’ and ‘deny’. Any |
| 4056 |
other value will lead to the line being ignored, but reported in the |
| 4057 |
system log. Of course, the two values represent admitting and rejecting |
| 4058 |
interpretations for the resulting rule. |
| 4059 |
|
| 4060 |
The second field, ‘user-exp’, is a POSIX regular expression crafted |
| 4061 |
to match user names. Remember that the regular expression would need |
| 4062 |
anchors in order to test not only substrings. |
| 4063 |
|
| 4064 |
It is important to note that in a site-wide ACL, the file selected by |
| 4065 |
the switch ‘-a’, the expression ‘user-exp’ is matched against the |
| 4066 |
requested local user name, that of the callee. |
| 4067 |
|
| 4068 |
While checking the callee's private ACL-file ‘.talkrc’, the matching |
| 4069 |
of ‘user-exp’ is done against the remote caller's name. Any other |
| 4070 |
interpretation is plainly futile. |
| 4071 |
|
| 4072 |
Each line may be augmented by a net list, containing one or more |
| 4073 |
expressions ‘net-exp’. Each of these is either the simple word ‘any’, a |
| 4074 |
numeric IPv4 address, or a full IPv4 address with an appended netmask. |
| 4075 |
The effect is to restrict the applicability of the rule to the specified |
| 4076 |
address range, or to set an explicit wildcard match ‘any’. The absence |
| 4077 |
of a net list is equivalent to specifying a single ‘any’. The netmask |
| 4078 |
can be specified as a CIDR mask length, or as an explicit address mask. |
| 4079 |
|
| 4080 |
The actual evaluation is made separately for the site-wide ACL, and |
| 4081 |
for the requested local user ACL, contained in the callee's private file |
| 4082 |
‘.talkrc’. This latter file must be a regular file and must be owned by |
| 4083 |
the very same user, have his primary group ownership, and not be group |
| 4084 |
or world writeable. Should any of these prerequisites be violated, the |
| 4085 |
user's ACL is replaced by a single deny-all rule. |
| 4086 |
|
| 4087 |
All rules in each set are evaluated, in the sense that whenever an |
| 4088 |
expression ‘net-exp’ matches the incoming IPv4 address, then the regular |
| 4089 |
expression ‘user-exp’ is tested for a match. That being the case, the |
| 4090 |
corresponding action is recorded. The last match in each set determines |
| 4091 |
the outcome in its category. |
| 4092 |
|
| 4093 |
In the most common case, a system wide ‘deny’ is overridden if the |
| 4094 |
local user has specified at least one valid and applicable rule, |
| 4095 |
admitting access. In the contrary case, where no admitting user rule |
| 4096 |
could be established at all, then a resulting ‘deny’, from a system wide |
| 4097 |
ACL, will be used as the final action. |
| 4098 |
|
| 4099 |
In strict policy mode, a site-wide ‘deny’ is always final, ignoring |
| 4100 |
any user's desire. The administrator must explicitly arrange some |
| 4101 |
admitting rule, with an action ‘allow’, and some suitable net list. |
| 4102 |
Still, the individual user can arrange his private file for an even |
| 4103 |
narrower selection of friends. |
| 4104 |
|
| 4105 |
|
| 4106 |
File: inetutils.info, Node: telnetd invocation, Next: tftpd invocation, Prev: talkd invocation, Up: Top |
| 4107 |
|
| 4108 |
26 ‘telnetd’: Telnet server |
| 4109 |
*************************** |
| 4110 |
|
| 4111 |
telnetd [OPTION]... |
| 4112 |
|
| 4113 |
‘--accept-env VAR’ |
| 4114 |
Allow clients to define the VAR environment variable. GNU |
| 4115 |
‘telnetd’ removes all environment variables by default since many |
| 4116 |
of them can be used to escalate privileges. |
| 4117 |
|
| 4118 |
‘-a AUTHMODE’ |
| 4119 |
‘--authmode=AUTHMODE’ |
| 4120 |
Specify what mode to use for authentication. Allowed values are: |
| 4121 |
‘none’, ‘other’, ‘user’, ‘valid’, and ‘off’. |
| 4122 |
|
| 4123 |
‘-E STRING’ |
| 4124 |
‘--exec-login=STRING’ |
| 4125 |
Set program to be executed instead of ‘/bin/login’. |
| 4126 |
|
| 4127 |
‘-h’ |
| 4128 |
‘--no-hostinfo’ |
| 4129 |
Do not print host information before login has been completed. |
| 4130 |
|
| 4131 |
‘-l[MODE]’ |
| 4132 |
‘--linemode=[MODE]’ |
| 4133 |
Set line mode. An empty argument will force line read mode at all |
| 4134 |
times. The only recognised value is otherwise ‘nokludge’. |
| 4135 |
|
| 4136 |
‘-n’ |
| 4137 |
‘--no-keepalive’ |
| 4138 |
Disable TCP keep-alive. |
| 4139 |
|
| 4140 |
‘-S PRINCIPAL’ |
| 4141 |
‘--server-principal=PRINCIPAL’ |
| 4142 |
Set principal name for the server, to be used in Kerberos |
| 4143 |
authentication. The value PRINCIPAL can be set to provide full |
| 4144 |
specification like ‘srv.local@REALM’ and ‘tnt/localhost@REALM’, |
| 4145 |
where the first uses the standard prefix 'host/'. Or PRINCIPAL can |
| 4146 |
override default settings in part only, like ‘srv.local’, |
| 4147 |
‘tnt/srv.local’, or ‘@REALM’. |
| 4148 |
|
| 4149 |
‘-U’ |
| 4150 |
‘--reverse-lookup’ |
| 4151 |
Refuse connections from addresses that cannot be mapped back into a |
| 4152 |
symbolic name. A client is accepted only if the IP address can be |
| 4153 |
resolved as a host name, and the same name is resolvable to |
| 4154 |
addresses among which the clients's address is included. |
| 4155 |
|
| 4156 |
‘-X AUTHTYPE’ |
| 4157 |
‘--disable-auth-type=AUTHTYPE’ |
| 4158 |
Disable the use of the given authentication type. Use this option |
| 4159 |
multiple times if more than one type is to be disabled. Standard |
| 4160 |
choices are ‘null’, ‘kerberos_v4’, and ‘kerberos_v5’. |
| 4161 |
|
| 4162 |
26.1 Crafting an execution string |
| 4163 |
================================= |
| 4164 |
|
| 4165 |
The server ‘telnetd’ contains a built-in execution string which invokes |
| 4166 |
‘login’ with arguments suitable for the operating system at hand. This |
| 4167 |
preset choice corresponds to the standard use case of the service. For |
| 4168 |
specialized purposes this implementation also offers a command line |
| 4169 |
option ‘-E’, or ‘--exec-login’, to override the built-in execution of |
| 4170 |
‘login’, thus allowing almost any choice of handler. |
| 4171 |
|
| 4172 |
A custom execution string could look like |
| 4173 |
|
| 4174 |
telnetd -h -E '/usr/local/sbin/avrop %t %U' |
| 4175 |
|
| 4176 |
The execution string must as its first part provide an absolute path to |
| 4177 |
an executable file. After that may follow arbitrary additional |
| 4178 |
arguments. For this latter part, ‘telnetd’ offers some replacement |
| 4179 |
tokens that dynamically are replaced by content. All are of the form |
| 4180 |
‘%<var>’, where ‘<var>’ is a single letter from the following collection |
| 4181 |
of selectors. A valid letter is called “variable”. The mark |
| 4182 |
_conditional_, appearing below, indicates that the corresponding |
| 4183 |
variable is conditionally assigned a value. |
| 4184 |
|
| 4185 |
‘%a’ |
| 4186 |
Returns ‘ok’ whenever authentication is complete. _conditional_ |
| 4187 |
|
| 4188 |
‘%d’ |
| 4189 |
Produces a time and date string. |
| 4190 |
|
| 4191 |
‘%h’ |
| 4192 |
Gives the remote host name in canonical form. |
| 4193 |
|
| 4194 |
‘%l’ |
| 4195 |
States the local host name, also in canonical form. |
| 4196 |
|
| 4197 |
‘%L’ |
| 4198 |
Returns the path of the pseudo terminal assigned to the client. |
| 4199 |
|
| 4200 |
‘%t’ |
| 4201 |
Gives the terminal device stripped of the leading ‘/dev/’. |
| 4202 |
|
| 4203 |
‘%T’ |
| 4204 |
States the terminal type, like ‘xterm’. _conditional_ |
| 4205 |
|
| 4206 |
‘%u’ |
| 4207 |
Provides the authenticated user name. _conditional_ |
| 4208 |
|
| 4209 |
‘%U’ |
| 4210 |
Returns the user name passed as an environment variable ‘USER’ by |
| 4211 |
the remote client software. The value is empty, should the |
| 4212 |
environment not provide a value. |
| 4213 |
|
| 4214 |
In addition, a conditional construct is able to take one action in |
| 4215 |
case a variable has an assigned value, and optionally to take another |
| 4216 |
action in the opposite case. The construct is |
| 4217 |
|
| 4218 |
%?<var>{true-stmt}[{false-stmt}] |
| 4219 |
|
| 4220 |
The braces are here mandatory, while the brackets enclose the optional |
| 4221 |
else-clause and are not included in actual use. The initial, motivating |
| 4222 |
example, could thus be expanded to read |
| 4223 |
|
| 4224 |
telnetd -h -E '/usr/local/sbin/avrop %t %?a{%u krb5}{%U}' |
| 4225 |
|
| 4226 |
In case authentication was completed as user ‘sigge’, the execution |
| 4227 |
string would resolve to |
| 4228 |
|
| 4229 |
/usr/local/sbin/avrop pts/1 sigge krb5 |
| 4230 |
|
| 4231 |
In all other cases the result would be |
| 4232 |
|
| 4233 |
/usr/local/sbin/avrop pts/1 $USER |
| 4234 |
|
| 4235 |
where ‘$USER’ is the value of the corresponding environment variable and |
| 4236 |
could possibly be empty. |
| 4237 |
|
| 4238 |
|
| 4239 |
File: inetutils.info, Node: tftpd invocation, Next: uucpd invocation, Prev: telnetd invocation, Up: Top |
| 4240 |
|
| 4241 |
27 ‘tftpd’: TFTP server |
| 4242 |
*********************** |
| 4243 |
|
| 4244 |
‘tftpd’ is intended to be invoked via ‘inetd’ at all times. |
| 4245 |
|
| 4246 |
Synopsis: |
| 4247 |
|
| 4248 |
tftpd [OPTIONS] [DIRECTORY ...] |
| 4249 |
|
| 4250 |
‘-g GROUP’ |
| 4251 |
‘--group=GROUP’ |
| 4252 |
Specify group membership of the process owner. This is used only |
| 4253 |
along with the option ‘-s’, and replaces the group membership that |
| 4254 |
comes from the process owner himself. |
| 4255 |
|
| 4256 |
‘-l’ |
| 4257 |
‘--logging’ |
| 4258 |
Enable logging. |
| 4259 |
|
| 4260 |
‘-n’ |
| 4261 |
‘--nonexistent’ |
| 4262 |
Suppress negative acknowledgement of requests for nonexistent |
| 4263 |
relative filenames. |
| 4264 |
|
| 4265 |
‘-s DIR’ |
| 4266 |
‘--secure-dir=DIR’ |
| 4267 |
Let the serving process change its root directory to DIR before |
| 4268 |
attending to any requests. This directory is not observable by any |
| 4269 |
client, but improves server isolation, since servable contents must |
| 4270 |
be located below this chrooted directory DIR. |
| 4271 |
|
| 4272 |
‘-u USER’ |
| 4273 |
‘--user=USER’ |
| 4274 |
Specify the process owner for serving requests. Only relevant |
| 4275 |
along with the option ‘-s’. The default name is ‘nobody’. |
| 4276 |
|
| 4277 |
27.1 Directory prefixes |
| 4278 |
======================= |
| 4279 |
|
| 4280 |
In addition to options, an invocation of ‘tftpd’ can specify an optional |
| 4281 |
list of directory prefixes. These are approved of according to two |
| 4282 |
principles: |
| 4283 |
|
| 4284 |
• Relative pathnames are ignored. |
| 4285 |
|
| 4286 |
• At most twenty prefixes are approved, the rest is discarded. |
| 4287 |
|
| 4288 |
A request for a file is decided upon as a consequence of evaluating |
| 4289 |
these criteria: |
| 4290 |
|
| 4291 |
• Every file request containing the substring ‘/../’ is denied, as is |
| 4292 |
a file name beginning with ‘../’. |
| 4293 |
|
| 4294 |
• Write requests must specify absolute locations. |
| 4295 |
|
| 4296 |
• A file request, if specified as an _absolute_ pathname, must begin |
| 4297 |
with one of the approved directory prefixes, should at least one |
| 4298 |
such prefix have been accepted. |
| 4299 |
|
| 4300 |
• In the absence of a prefix collection, any absolute pathname is |
| 4301 |
accepted, should the corresponding file exist. |
| 4302 |
|
| 4303 |
• A file request, if specified as a _relative_ name, will only be |
| 4304 |
searched for below the acceptable prefixes, should at least one |
| 4305 |
such prefix have been approved. |
| 4306 |
|
| 4307 |
• A request for a relatively named file, is denied in the absence of |
| 4308 |
approved directory prefixes. |
| 4309 |
|
| 4310 |
• The resulting file must be world readable, or world writable, for a |
| 4311 |
read request, or a write request, to succeed. |
| 4312 |
|
| 4313 |
27.2 Use cases |
| 4314 |
============== |
| 4315 |
|
| 4316 |
The standard use case is an entry in ‘/etc/inetd.conf’ like |
| 4317 |
|
| 4318 |
tftp dgram udp4 wait root /usr/sbin/tftpd \ |
| 4319 |
tftpd /tftpboot /altboot |
| 4320 |
|
| 4321 |
This would allow the TFTP client to use any of |
| 4322 |
|
| 4323 |
get kernel |
| 4324 |
get /tftpboot/kernel |
| 4325 |
get kernel.alt |
| 4326 |
get /altboot/kernel.alt |
| 4327 |
get /etc/motd |
| 4328 |
|
| 4329 |
given that ‘/tftpboot/kernel’ and ‘/altboot/kernel.alt’ exist. Observe |
| 4330 |
that also ‘/etc/motd’ is accessible, in spite of there being no explicit |
| 4331 |
mention of standard file locations. |
| 4332 |
|
| 4333 |
A stronger mode of running a TFTP server is to use the 'secure mode', |
| 4334 |
meaning that the serving process is running in a chrooted mode. Then a |
| 4335 |
suitable configuration could be |
| 4336 |
|
| 4337 |
tftp dgram udp4 wait root /usr/sbin/tftpd \ |
| 4338 |
tftpd --secure-dir=/srv/tftp-root /tftpboot /altboot |
| 4339 |
|
| 4340 |
Supposing the files ‘kernel’ and ‘kernel.alt’ to exist in the common |
| 4341 |
directory ‘/srv/tftp-root/altboot/’, all the previously suggested client |
| 4342 |
requests for a kernel would still be granted, but now any request for |
| 4343 |
‘/etc/motd’ would be declined, and would get a reply 'File not found' |
| 4344 |
back. |
| 4345 |
|
| 4346 |
The chrooted setting is denying access outside of ‘/srv/tftp-root’, |
| 4347 |
yet is not indicating this lock-in to the client, and is thus improving |
| 4348 |
server isolation. Since neither of ‘-u’ and ‘-g’ were specified, the |
| 4349 |
configuration reproduced above will in fact have the transmitting server |
| 4350 |
process running with the default owner set to ‘nobody:nogroup’. |
| 4351 |
|
| 4352 |
|
| 4353 |
File: inetutils.info, Node: uucpd invocation, Next: GNU Free Documentation License, Prev: tftpd invocation, Up: Top |
| 4354 |
|
| 4355 |
28 ‘uucpd’: Unix to Unix Copy relay daemon. |
| 4356 |
******************************************* |
| 4357 |
|
| 4358 |
‘uucpd’ is a relay daemon responsible for accepting TCP transported |
| 4359 |
connections for ‘uucico’. It is started by ‘inetd’, conducts any |
| 4360 |
authentication, and then hands acceptable requests over to ‘uucico’. |
| 4361 |
|
| 4362 |
uucpd [OPTION]... |
| 4363 |
|
| 4364 |
28.1 Options |
| 4365 |
============ |
| 4366 |
|
| 4367 |
There is a single, specific option available: |
| 4368 |
|
| 4369 |
‘-u LOCATION’ |
| 4370 |
‘--uucico=LOCATION’ |
| 4371 |
Replace the hard coded location of ‘uucico’ with the value |
| 4372 |
specified as LOCATION. |
| 4373 |
|
| 4374 |
28.2 Authentication steps |
| 4375 |
========================= |
| 4376 |
|
| 4377 |
Invocation is expected to be conducted by a protocol described exchange |
| 4378 |
of user name and password; unfortunately in clear text. If those agree |
| 4379 |
with existing local entries, then ‘uucpd’ verifies that the stated user |
| 4380 |
also has user shell location identical to the full file system location |
| 4381 |
of ‘uucico’. Should that not be the case, the request is declined. |
| 4382 |
|
| 4383 |
For this latter check, the option ‘--uucico’ is useful when setting |
| 4384 |
the configuration for ‘inetd’. It is recommended to wrap the invocation |
| 4385 |
line of ‘uucpd’ within a call to ‘tcpd’ in the standard fashion. |
| 4386 |
|
| 4387 |
|
| 4388 |
File: inetutils.info, Node: GNU Free Documentation License, Next: Index, Prev: uucpd invocation, Up: Top |
| 4389 |
|
| 4390 |
Appendix A GNU Free Documentation License |
| 4391 |
***************************************** |
| 4392 |
|
| 4393 |
Version 1.3, 3 November 2008 |
| 4394 |
|
| 4395 |
Copyright © 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc. |
| 4396 |
<https://fsf.org/> |
| 4397 |
|
| 4398 |
Everyone is permitted to copy and distribute verbatim copies |
| 4399 |
of this license document, but changing it is not allowed. |
| 4400 |
|
| 4401 |
0. PREAMBLE |
| 4402 |
|
| 4403 |
The purpose of this License is to make a manual, textbook, or other |
| 4404 |
functional and useful document “free” in the sense of freedom: to |
| 4405 |
assure everyone the effective freedom to copy and redistribute it, |
| 4406 |
with or without modifying it, either commercially or |
| 4407 |
noncommercially. Secondarily, this License preserves for the |
| 4408 |
author and publisher a way to get credit for their work, while not |
| 4409 |
being considered responsible for modifications made by others. |
| 4410 |
|
| 4411 |
This License is a kind of "copyleft", which means that derivative |
| 4412 |
works of the document must themselves be free in the same sense. |
| 4413 |
It complements the GNU General Public License, which is a copyleft |
| 4414 |
license designed for free software. |
| 4415 |
|
| 4416 |
We have designed this License in order to use it for manuals for |
| 4417 |
free software, because free software needs free documentation: a |
| 4418 |
free program should come with manuals providing the same freedoms |
| 4419 |
that the software does. But this License is not limited to |
| 4420 |
software manuals; it can be used for any textual work, regardless |
| 4421 |
of subject matter or whether it is published as a printed book. We |
| 4422 |
recommend this License principally for works whose purpose is |
| 4423 |
instruction or reference. |
| 4424 |
|
| 4425 |
1. APPLICABILITY AND DEFINITIONS |
| 4426 |
|
| 4427 |
This License applies to any manual or other work, in any medium, |
| 4428 |
that contains a notice placed by the copyright holder saying it can |
| 4429 |
be distributed under the terms of this License. Such a notice |
| 4430 |
grants a world-wide, royalty-free license, unlimited in duration, |
| 4431 |
to use that work under the conditions stated herein. The |
| 4432 |
"Document", below, refers to any such manual or work. Any member |
| 4433 |
of the public is a licensee, and is addressed as "you". You accept |
| 4434 |
the license if you copy, modify or distribute the work in a way |
| 4435 |
requiring permission under copyright law. |
| 4436 |
|
| 4437 |
A "Modified Version" of the Document means any work containing the |
| 4438 |
Document or a portion of it, either copied verbatim, or with |
| 4439 |
modifications and/or translated into another language. |
| 4440 |
|
| 4441 |
A "Secondary Section" is a named appendix or a front-matter section |
| 4442 |
of the Document that deals exclusively with the relationship of the |
| 4443 |
publishers or authors of the Document to the Document's overall |
| 4444 |
subject (or to related matters) and contains nothing that could |
| 4445 |
fall directly within that overall subject. (Thus, if the Document |
| 4446 |
is in part a textbook of mathematics, a Secondary Section may not |
| 4447 |
explain any mathematics.) The relationship could be a matter of |
| 4448 |
historical connection with the subject or with related matters, or |
| 4449 |
of legal, commercial, philosophical, ethical or political position |
| 4450 |
regarding them. |
| 4451 |
|
| 4452 |
The "Invariant Sections" are certain Secondary Sections whose |
| 4453 |
titles are designated, as being those of Invariant Sections, in the |
| 4454 |
notice that says that the Document is released under this License. |
| 4455 |
If a section does not fit the above definition of Secondary then it |
| 4456 |
is not allowed to be designated as Invariant. The Document may |
| 4457 |
contain zero Invariant Sections. If the Document does not identify |
| 4458 |
any Invariant Sections then there are none. |
| 4459 |
|
| 4460 |
The "Cover Texts" are certain short passages of text that are |
| 4461 |
listed, as Front-Cover Texts or Back-Cover Texts, in the notice |
| 4462 |
that says that the Document is released under this License. A |
| 4463 |
Front-Cover Text may be at most 5 words, and a Back-Cover Text may |
| 4464 |
be at most 25 words. |
| 4465 |
|
| 4466 |
A "Transparent" copy of the Document means a machine-readable copy, |
| 4467 |
represented in a format whose specification is available to the |
| 4468 |
general public, that is suitable for revising the document |
| 4469 |
straightforwardly with generic text editors or (for images composed |
| 4470 |
of pixels) generic paint programs or (for drawings) some widely |
| 4471 |
available drawing editor, and that is suitable for input to text |
| 4472 |
formatters or for automatic translation to a variety of formats |
| 4473 |
suitable for input to text formatters. A copy made in an otherwise |
| 4474 |
Transparent file format whose markup, or absence of markup, has |
| 4475 |
been arranged to thwart or discourage subsequent modification by |
| 4476 |
readers is not Transparent. An image format is not Transparent if |
| 4477 |
used for any substantial amount of text. A copy that is not |
| 4478 |
"Transparent" is called "Opaque". |
| 4479 |
|
| 4480 |
Examples of suitable formats for Transparent copies include plain |
| 4481 |
ASCII without markup, Texinfo input format, LaTeX input format, |
| 4482 |
SGML or XML using a publicly available DTD, and standard-conforming |
| 4483 |
simple HTML, PostScript or PDF designed for human modification. |
| 4484 |
Examples of transparent image formats include PNG, XCF and JPG. |
| 4485 |
Opaque formats include proprietary formats that can be read and |
| 4486 |
edited only by proprietary word processors, SGML or XML for which |
| 4487 |
the DTD and/or processing tools are not generally available, and |
| 4488 |
the machine-generated HTML, PostScript or PDF produced by some word |
| 4489 |
processors for output purposes only. |
| 4490 |
|
| 4491 |
The "Title Page" means, for a printed book, the title page itself, |
| 4492 |
plus such following pages as are needed to hold, legibly, the |
| 4493 |
material this License requires to appear in the title page. For |
| 4494 |
works in formats which do not have any title page as such, "Title |
| 4495 |
Page" means the text near the most prominent appearance of the |
| 4496 |
work's title, preceding the beginning of the body of the text. |
| 4497 |
|
| 4498 |
The "publisher" means any person or entity that distributes copies |
| 4499 |
of the Document to the public. |
| 4500 |
|
| 4501 |
A section "Entitled XYZ" means a named subunit of the Document |
| 4502 |
whose title either is precisely XYZ or contains XYZ in parentheses |
| 4503 |
following text that translates XYZ in another language. (Here XYZ |
| 4504 |
stands for a specific section name mentioned below, such as |
| 4505 |
"Acknowledgements", "Dedications", "Endorsements", or "History".) |
| 4506 |
To "Preserve the Title" of such a section when you modify the |
| 4507 |
Document means that it remains a section "Entitled XYZ" according |
| 4508 |
to this definition. |
| 4509 |
|
| 4510 |
The Document may include Warranty Disclaimers next to the notice |
| 4511 |
which states that this License applies to the Document. These |
| 4512 |
Warranty Disclaimers are considered to be included by reference in |
| 4513 |
this License, but only as regards disclaiming warranties: any other |
| 4514 |
implication that these Warranty Disclaimers may have is void and |
| 4515 |
has no effect on the meaning of this License. |
| 4516 |
|
| 4517 |
2. VERBATIM COPYING |
| 4518 |
|
| 4519 |
You may copy and distribute the Document in any medium, either |
| 4520 |
commercially or noncommercially, provided that this License, the |
| 4521 |
copyright notices, and the license notice saying this License |
| 4522 |
applies to the Document are reproduced in all copies, and that you |
| 4523 |
add no other conditions whatsoever to those of this License. You |
| 4524 |
may not use technical measures to obstruct or control the reading |
| 4525 |
or further copying of the copies you make or distribute. However, |
| 4526 |
you may accept compensation in exchange for copies. If you |
| 4527 |
distribute a large enough number of copies you must also follow the |
| 4528 |
conditions in section 3. |
| 4529 |
|
| 4530 |
You may also lend copies, under the same conditions stated above, |
| 4531 |
and you may publicly display copies. |
| 4532 |
|
| 4533 |
3. COPYING IN QUANTITY |
| 4534 |
|
| 4535 |
If you publish printed copies (or copies in media that commonly |
| 4536 |
have printed covers) of the Document, numbering more than 100, and |
| 4537 |
the Document's license notice requires Cover Texts, you must |
| 4538 |
enclose the copies in covers that carry, clearly and legibly, all |
| 4539 |
these Cover Texts: Front-Cover Texts on the front cover, and |
| 4540 |
Back-Cover Texts on the back cover. Both covers must also clearly |
| 4541 |
and legibly identify you as the publisher of these copies. The |
| 4542 |
front cover must present the full title with all words of the title |
| 4543 |
equally prominent and visible. You may add other material on the |
| 4544 |
covers in addition. Copying with changes limited to the covers, as |
| 4545 |
long as they preserve the title of the Document and satisfy these |
| 4546 |
conditions, can be treated as verbatim copying in other respects. |
| 4547 |
|
| 4548 |
If the required texts for either cover are too voluminous to fit |
| 4549 |
legibly, you should put the first ones listed (as many as fit |
| 4550 |
reasonably) on the actual cover, and continue the rest onto |
| 4551 |
adjacent pages. |
| 4552 |
|
| 4553 |
If you publish or distribute Opaque copies of the Document |
| 4554 |
numbering more than 100, you must either include a machine-readable |
| 4555 |
Transparent copy along with each Opaque copy, or state in or with |
| 4556 |
each Opaque copy a computer-network location from which the general |
| 4557 |
network-using public has access to download using public-standard |
| 4558 |
network protocols a complete Transparent copy of the Document, free |
| 4559 |
of added material. If you use the latter option, you must take |
| 4560 |
reasonably prudent steps, when you begin distribution of Opaque |
| 4561 |
copies in quantity, to ensure that this Transparent copy will |
| 4562 |
remain thus accessible at the stated location until at least one |
| 4563 |
year after the last time you distribute an Opaque copy (directly or |
| 4564 |
through your agents or retailers) of that edition to the public. |
| 4565 |
|
| 4566 |
It is requested, but not required, that you contact the authors of |
| 4567 |
the Document well before redistributing any large number of copies, |
| 4568 |
to give them a chance to provide you with an updated version of the |
| 4569 |
Document. |
| 4570 |
|
| 4571 |
4. MODIFICATIONS |
| 4572 |
|
| 4573 |
You may copy and distribute a Modified Version of the Document |
| 4574 |
under the conditions of sections 2 and 3 above, provided that you |
| 4575 |
release the Modified Version under precisely this License, with the |
| 4576 |
Modified Version filling the role of the Document, thus licensing |
| 4577 |
distribution and modification of the Modified Version to whoever |
| 4578 |
possesses a copy of it. In addition, you must do these things in |
| 4579 |
the Modified Version: |
| 4580 |
|
| 4581 |
A. Use in the Title Page (and on the covers, if any) a title |
| 4582 |
distinct from that of the Document, and from those of previous |
| 4583 |
versions (which should, if there were any, be listed in the |
| 4584 |
History section of the Document). You may use the same title |
| 4585 |
as a previous version if the original publisher of that |
| 4586 |
version gives permission. |
| 4587 |
|
| 4588 |
B. List on the Title Page, as authors, one or more persons or |
| 4589 |
entities responsible for authorship of the modifications in |
| 4590 |
the Modified Version, together with at least five of the |
| 4591 |
principal authors of the Document (all of its principal |
| 4592 |
authors, if it has fewer than five), unless they release you |
| 4593 |
from this requirement. |
| 4594 |
|
| 4595 |
C. State on the Title page the name of the publisher of the |
| 4596 |
Modified Version, as the publisher. |
| 4597 |
|
| 4598 |
D. Preserve all the copyright notices of the Document. |
| 4599 |
|
| 4600 |
E. Add an appropriate copyright notice for your modifications |
| 4601 |
adjacent to the other copyright notices. |
| 4602 |
|
| 4603 |
F. Include, immediately after the copyright notices, a license |
| 4604 |
notice giving the public permission to use the Modified |
| 4605 |
Version under the terms of this License, in the form shown in |
| 4606 |
the Addendum below. |
| 4607 |
|
| 4608 |
G. Preserve in that license notice the full lists of Invariant |
| 4609 |
Sections and required Cover Texts given in the Document's |
| 4610 |
license notice. |
| 4611 |
|
| 4612 |
H. Include an unaltered copy of this License. |
| 4613 |
|
| 4614 |
I. Preserve the section Entitled "History", Preserve its Title, |
| 4615 |
and add to it an item stating at least the title, year, new |
| 4616 |
authors, and publisher of the Modified Version as given on the |
| 4617 |
Title Page. If there is no section Entitled "History" in the |
| 4618 |
Document, create one stating the title, year, authors, and |
| 4619 |
publisher of the Document as given on its Title Page, then add |
| 4620 |
an item describing the Modified Version as stated in the |
| 4621 |
previous sentence. |
| 4622 |
|
| 4623 |
J. Preserve the network location, if any, given in the Document |
| 4624 |
for public access to a Transparent copy of the Document, and |
| 4625 |
likewise the network locations given in the Document for |
| 4626 |
previous versions it was based on. These may be placed in the |
| 4627 |
"History" section. You may omit a network location for a work |
| 4628 |
that was published at least four years before the Document |
| 4629 |
itself, or if the original publisher of the version it refers |
| 4630 |
to gives permission. |
| 4631 |
|
| 4632 |
K. For any section Entitled "Acknowledgements" or "Dedications", |
| 4633 |
Preserve the Title of the section, and preserve in the section |
| 4634 |
all the substance and tone of each of the contributor |
| 4635 |
acknowledgements and/or dedications given therein. |
| 4636 |
|
| 4637 |
L. Preserve all the Invariant Sections of the Document, unaltered |
| 4638 |
in their text and in their titles. Section numbers or the |
| 4639 |
equivalent are not considered part of the section titles. |
| 4640 |
|
| 4641 |
M. Delete any section Entitled "Endorsements". Such a section |
| 4642 |
may not be included in the Modified Version. |
| 4643 |
|
| 4644 |
N. Do not retitle any existing section to be Entitled |
| 4645 |
"Endorsements" or to conflict in title with any Invariant |
| 4646 |
Section. |
| 4647 |
|
| 4648 |
O. Preserve any Warranty Disclaimers. |
| 4649 |
|
| 4650 |
If the Modified Version includes new front-matter sections or |
| 4651 |
appendices that qualify as Secondary Sections and contain no |
| 4652 |
material copied from the Document, you may at your option designate |
| 4653 |
some or all of these sections as invariant. To do this, add their |
| 4654 |
titles to the list of Invariant Sections in the Modified Version's |
| 4655 |
license notice. These titles must be distinct from any other |
| 4656 |
section titles. |
| 4657 |
|
| 4658 |
You may add a section Entitled "Endorsements", provided it contains |
| 4659 |
nothing but endorsements of your Modified Version by various |
| 4660 |
parties--for example, statements of peer review or that the text |
| 4661 |
has been approved by an organization as the authoritative |
| 4662 |
definition of a standard. |
| 4663 |
|
| 4664 |
You may add a passage of up to five words as a Front-Cover Text, |
| 4665 |
and a passage of up to 25 words as a Back-Cover Text, to the end of |
| 4666 |
the list of Cover Texts in the Modified Version. Only one passage |
| 4667 |
of Front-Cover Text and one of Back-Cover Text may be added by (or |
| 4668 |
through arrangements made by) any one entity. If the Document |
| 4669 |
already includes a cover text for the same cover, previously added |
| 4670 |
by you or by arrangement made by the same entity you are acting on |
| 4671 |
behalf of, you may not add another; but you may replace the old |
| 4672 |
one, on explicit permission from the previous publisher that added |
| 4673 |
the old one. |
| 4674 |
|
| 4675 |
The author(s) and publisher(s) of the Document do not by this |
| 4676 |
License give permission to use their names for publicity for or to |
| 4677 |
assert or imply endorsement of any Modified Version. |
| 4678 |
|
| 4679 |
5. COMBINING DOCUMENTS |
| 4680 |
|
| 4681 |
You may combine the Document with other documents released under |
| 4682 |
this License, under the terms defined in section 4 above for |
| 4683 |
modified versions, provided that you include in the combination all |
| 4684 |
of the Invariant Sections of all of the original documents, |
| 4685 |
unmodified, and list them all as Invariant Sections of your |
| 4686 |
combined work in its license notice, and that you preserve all |
| 4687 |
their Warranty Disclaimers. |
| 4688 |
|
| 4689 |
The combined work need only contain one copy of this License, and |
| 4690 |
multiple identical Invariant Sections may be replaced with a single |
| 4691 |
copy. If there are multiple Invariant Sections with the same name |
| 4692 |
but different contents, make the title of each such section unique |
| 4693 |
by adding at the end of it, in parentheses, the name of the |
| 4694 |
original author or publisher of that section if known, or else a |
| 4695 |
unique number. Make the same adjustment to the section titles in |
| 4696 |
the list of Invariant Sections in the license notice of the |
| 4697 |
combined work. |
| 4698 |
|
| 4699 |
In the combination, you must combine any sections Entitled |
| 4700 |
"History" in the various original documents, forming one section |
| 4701 |
Entitled "History"; likewise combine any sections Entitled |
| 4702 |
"Acknowledgements", and any sections Entitled "Dedications". You |
| 4703 |
must delete all sections Entitled "Endorsements." |
| 4704 |
|
| 4705 |
6. COLLECTIONS OF DOCUMENTS |
| 4706 |
|
| 4707 |
You may make a collection consisting of the Document and other |
| 4708 |
documents released under this License, and replace the individual |
| 4709 |
copies of this License in the various documents with a single copy |
| 4710 |
that is included in the collection, provided that you follow the |
| 4711 |
rules of this License for verbatim copying of each of the documents |
| 4712 |
in all other respects. |
| 4713 |
|
| 4714 |
You may extract a single document from such a collection, and |
| 4715 |
distribute it individually under this License, provided you insert |
| 4716 |
a copy of this License into the extracted document, and follow this |
| 4717 |
License in all other respects regarding verbatim copying of that |
| 4718 |
document. |
| 4719 |
|
| 4720 |
7. AGGREGATION WITH INDEPENDENT WORKS |
| 4721 |
|
| 4722 |
A compilation of the Document or its derivatives with other |
| 4723 |
separate and independent documents or works, in or on a volume of a |
| 4724 |
storage or distribution medium, is called an "aggregate" if the |
| 4725 |
copyright resulting from the compilation is not used to limit the |
| 4726 |
legal rights of the compilation's users beyond what the individual |
| 4727 |
works permit. When the Document is included in an aggregate, this |
| 4728 |
License does not apply to the other works in the aggregate which |
| 4729 |
are not themselves derivative works of the Document. |
| 4730 |
|
| 4731 |
If the Cover Text requirement of section 3 is applicable to these |
| 4732 |
copies of the Document, then if the Document is less than one half |
| 4733 |
of the entire aggregate, the Document's Cover Texts may be placed |
| 4734 |
on covers that bracket the Document within the aggregate, or the |
| 4735 |
electronic equivalent of covers if the Document is in electronic |
| 4736 |
form. Otherwise they must appear on printed covers that bracket |
| 4737 |
the whole aggregate. |
| 4738 |
|
| 4739 |
8. TRANSLATION |
| 4740 |
|
| 4741 |
Translation is considered a kind of modification, so you may |
| 4742 |
distribute translations of the Document under the terms of section |
| 4743 |
4. Replacing Invariant Sections with translations requires special |
| 4744 |
permission from their copyright holders, but you may include |
| 4745 |
translations of some or all Invariant Sections in addition to the |
| 4746 |
original versions of these Invariant Sections. You may include a |
| 4747 |
translation of this License, and all the license notices in the |
| 4748 |
Document, and any Warranty Disclaimers, provided that you also |
| 4749 |
include the original English version of this License and the |
| 4750 |
original versions of those notices and disclaimers. In case of a |
| 4751 |
disagreement between the translation and the original version of |
| 4752 |
this License or a notice or disclaimer, the original version will |
| 4753 |
prevail. |
| 4754 |
|
| 4755 |
If a section in the Document is Entitled "Acknowledgements", |
| 4756 |
"Dedications", or "History", the requirement (section 4) to |
| 4757 |
Preserve its Title (section 1) will typically require changing the |
| 4758 |
actual title. |
| 4759 |
|
| 4760 |
9. TERMINATION |
| 4761 |
|
| 4762 |
You may not copy, modify, sublicense, or distribute the Document |
| 4763 |
except as expressly provided under this License. Any attempt |
| 4764 |
otherwise to copy, modify, sublicense, or distribute it is void, |
| 4765 |
and will automatically terminate your rights under this License. |
| 4766 |
|
| 4767 |
However, if you cease all violation of this License, then your |
| 4768 |
license from a particular copyright holder is reinstated (a) |
| 4769 |
provisionally, unless and until the copyright holder explicitly and |
| 4770 |
finally terminates your license, and (b) permanently, if the |
| 4771 |
copyright holder fails to notify you of the violation by some |
| 4772 |
reasonable means prior to 60 days after the cessation. |
| 4773 |
|
| 4774 |
Moreover, your license from a particular copyright holder is |
| 4775 |
reinstated permanently if the copyright holder notifies you of the |
| 4776 |
violation by some reasonable means, this is the first time you have |
| 4777 |
received notice of violation of this License (for any work) from |
| 4778 |
that copyright holder, and you cure the violation prior to 30 days |
| 4779 |
after your receipt of the notice. |
| 4780 |
|
| 4781 |
Termination of your rights under this section does not terminate |
| 4782 |
the licenses of parties who have received copies or rights from you |
| 4783 |
under this License. If your rights have been terminated and not |
| 4784 |
permanently reinstated, receipt of a copy of some or all of the |
| 4785 |
same material does not give you any rights to use it. |
| 4786 |
|
| 4787 |
10. FUTURE REVISIONS OF THIS LICENSE |
| 4788 |
|
| 4789 |
The Free Software Foundation may publish new, revised versions of |
| 4790 |
the GNU Free Documentation License from time to time. Such new |
| 4791 |
versions will be similar in spirit to the present version, but may |
| 4792 |
differ in detail to address new problems or concerns. See |
| 4793 |
<https://www.gnu.org/licenses/>. |
| 4794 |
|
| 4795 |
Each version of the License is given a distinguishing version |
| 4796 |
number. If the Document specifies that a particular numbered |
| 4797 |
version of this License "or any later version" applies to it, you |
| 4798 |
have the option of following the terms and conditions either of |
| 4799 |
that specified version or of any later version that has been |
| 4800 |
published (not as a draft) by the Free Software Foundation. If the |
| 4801 |
Document does not specify a version number of this License, you may |
| 4802 |
choose any version ever published (not as a draft) by the Free |
| 4803 |
Software Foundation. If the Document specifies that a proxy can |
| 4804 |
decide which future versions of this License can be used, that |
| 4805 |
proxy's public statement of acceptance of a version permanently |
| 4806 |
authorizes you to choose that version for the Document. |
| 4807 |
|
| 4808 |
11. RELICENSING |
| 4809 |
|
| 4810 |
"Massive Multiauthor Collaboration Site" (or "MMC Site") means any |
| 4811 |
World Wide Web server that publishes copyrightable works and also |
| 4812 |
provides prominent facilities for anybody to edit those works. A |
| 4813 |
public wiki that anybody can edit is an example of such a server. |
| 4814 |
A "Massive Multiauthor Collaboration" (or "MMC") contained in the |
| 4815 |
site means any set of copyrightable works thus published on the MMC |
| 4816 |
site. |
| 4817 |
|
| 4818 |
"CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0 |
| 4819 |
license published by Creative Commons Corporation, a not-for-profit |
| 4820 |
corporation with a principal place of business in San Francisco, |
| 4821 |
California, as well as future copyleft versions of that license |
| 4822 |
published by that same organization. |
| 4823 |
|
| 4824 |
"Incorporate" means to publish or republish a Document, in whole or |
| 4825 |
in part, as part of another Document. |
| 4826 |
|
| 4827 |
An MMC is "eligible for relicensing" if it is licensed under this |
| 4828 |
License, and if all works that were first published under this |
| 4829 |
License somewhere other than this MMC, and subsequently |
| 4830 |
incorporated in whole or in part into the MMC, (1) had no cover |
| 4831 |
texts or invariant sections, and (2) were thus incorporated prior |
| 4832 |
to November 1, 2008. |
| 4833 |
|
| 4834 |
The operator of an MMC Site may republish an MMC contained in the |
| 4835 |
site under CC-BY-SA on the same site at any time before August 1, |
| 4836 |
2009, provided the MMC is eligible for relicensing. |
| 4837 |
|
| 4838 |
ADDENDUM: How to use this License for your documents |
| 4839 |
==================================================== |
| 4840 |
|
| 4841 |
To use this License in a document you have written, include a copy of |
| 4842 |
the License in the document and put the following copyright and license |
| 4843 |
notices just after the title page: |
| 4844 |
|
| 4845 |
Copyright (C) YEAR YOUR NAME. |
| 4846 |
Permission is granted to copy, distribute and/or modify this document |
| 4847 |
under the terms of the GNU Free Documentation License, Version 1.3 |
| 4848 |
or any later version published by the Free Software Foundation; |
| 4849 |
with no Invariant Sections, no Front-Cover Texts, and no Back-Cover |
| 4850 |
Texts. A copy of the license is included in the section entitled ``GNU |
| 4851 |
Free Documentation License''. |
| 4852 |
|
| 4853 |
If you have Invariant Sections, Front-Cover Texts and Back-Cover |
| 4854 |
Texts, replace the "with...Texts." line with this: |
| 4855 |
|
| 4856 |
with the Invariant Sections being LIST THEIR TITLES, with |
| 4857 |
the Front-Cover Texts being LIST, and with the Back-Cover Texts |
| 4858 |
being LIST. |
| 4859 |
|
| 4860 |
If you have Invariant Sections without Cover Texts, or some other |
| 4861 |
combination of the three, merge those two alternatives to suit the |
| 4862 |
situation. |
| 4863 |
|
| 4864 |
If your document contains nontrivial examples of program code, we |
| 4865 |
recommend releasing these examples in parallel under your choice of free |
| 4866 |
software license, such as the GNU General Public License, to permit |
| 4867 |
their use in free software. |
| 4868 |
|
| 4869 |
|
| 4870 |
File: inetutils.info, Node: Index, Prev: GNU Free Documentation License, Up: Top |
| 4871 |
|
| 4872 |
Index |
| 4873 |
***** |
| 4874 |
|
| 4875 |
|