RLINETD.CONF(5)
π RLINETD.CONF(5) π
okay so this is the RLINETD.CONF(5) page from rlinetd 0.9.3, bestie β it's the manual for rlinetd.conf, and it's lowkey long, so buckle up and hydrate π
β¨ NAME β¨
rlinetd.conf β the configuration file for rlinetd. that's the whole name section, she's brief and she's iconic π
πΈ DESCRIPTION πΈ
rlinetd.conf holds configuration information for rlinetd. There are a small number of similar top level constructs, differing chiefly in which options can be meaningfully used with them.
All strings are quoted with the " character. In some situations (e.g. the log, exec, and chroot directives), there are a number of variables that can be substituted into the string. Unless stated otherwise, all numbers must be positive. π¦
π service "name" { ... }
This construct describes a service. The name parameter is for naming convenience alone β it simply serves to distinguish logging messages and provides a default for options which can logically accept a name as an argument. no cap, it's literally just a vibe label π«Ά
π enabled
This construct allows easily enabling or disabling service. The argument can be either yes or no. The default value is yes. Setting this to no disables service.
Example:
enabled no;
π port
This lists the ports that the service should be made available on. The ports can be listed in either string or numeric format. If unspecified, this defaults to the name of the service unless the service is an RPC service, in which case the port value will be dynamically assigned by the system.
Example:
port "telnet", "rcmd", 56, 99;
π« interface
This specifies which interfaces the listed ports should be bound on. It takes a list of IP addresses as an argument, corresponding to the configured addresses of the interfaces required. If this keyword is not given or when a special value any is assigned to it, the service will bind to all available interfaces.
Examples:
interface 192.168.1.1, 192.168.1.2;
interface any;
π₯ exec
This specifies the invocation of the service. A number of substitutions can be made within the string; please see String Modifiers below.
Example:
exec "/usr/sbin/in.telnetd -d";
π server
This specifies the binary to be executed, if different to exec.
Example:
server "/usr/sbin/tcpd";
π§ protocol
This specifies the socket protocol to use when listening on ports for the service. The argument can be either tcp or udp. The default setting for this variable is tcp.
Example:
protocol tcp;
π user
This specifies the userid under which this service should run. It will accept an argument in either symbolic or numeric form. Unless group (see below) is given, the groupid is also set to the user's primary group.
Example:
user "nobody";
πΈ group
This specifies the groupid under which this service should run. It will accept an argument in either symbolic or numeric form.
Example:
group "system";
π¦ backlog
This is the backlog argument which will be passed to the listen(2) system call.
Example:
backlog 30;
β instances
This specifies the maximum number of service instances that can be running at any one time. The default setting for this variable is 40.
Example:
instances 50;
π wait
This directive emulates the inetd(8) wait behaviour. The argument can be either yes or no. The default value is no. Setting this to yes also resets the value of instances option to 1.
Example:
wait yes;
π nice
This specifies the process priority to run this service at. The argument is passed directly to the setpriority(2) system call. The value may be negative.
Example:
nice -5;
π« rpc
This specifies that the service should be registered with the system's portmap(8) mapper as an RPC service. It accepts a list of arguments as follows.
rpc {
name "string"; version 3,6,9-15,22;
}
The name parameter is optional, and defaults to the service name.
π§ chroot
This specifies the root directory for the service. The string argument can accept modifiers as detailed in String Modifiers below.
Example:
chroot "/tftpboot/%O";
π₯ log
This directive takes two arguments. The first must be either the symbolic name of a previously specified log directive (see below), or the unquoted word syslog. If the latter, the message will be logged via the syslog(3) call. The second argument is the message that will be logged, subject to the modifiers detailed in String Modifiers below.
Example:
log syslog "Service from %O complete";
π
tcpd
This directive causes access controls as specified by tcp_wrappers to be applied. This has the same effect as invoking a service with a server argument of /usr/sbin/tcpd (or wherever your tcpd(8) program is kept), but saves the additional step of starting the program. It will accept up to two additional arguments. The first is a service name to apply against its rules, and the second is a block of instructions to execute if matched. If no name is specified, it defaults to the name of the service. If the instruction block is not specified, it defaults to 'exit;'.
Examples:
tcpd "in.telnetd";
tcpd { exec "/usr/local/bin/winnuke %O"; }
tcpd "pointless" { echo "Hi guys, come on in."; }
tcpd "defiant" { echo "500 Access denied from %O."; exit; }
π exit
This directive is only useful in an instruction block argument to the tcpd directive. Note well β not using it (and not specifying some other terminating directive, such as exec) will result in the service being run forever. π
Example:
exit;
π«Ά capability
This directive specifies the capabilities that this service should have when running. The argument is a string that is passed directly to cap_from_text(3). I know, that's a pretty lousy description, but this feature is of limited utility until and unless you read the README.capabilities file anyway. π
Example:
capability "cap_setuid=ep";
π rlimit
This directive takes two arguments. The first is a symbol specifying the type of limit required. These are listed below. The second argument takes one of two forms. It can either be a single numeric value, in which case both of the soft and hard limits of the resource in question will be set to this value. Alternatively, it can be a list in the form:
rlimit type {
soft x; hard y;
}
In which case the hard and soft limits will be set appropriately. In either case, the word unlimited can be specified instead of a numeric value, thus removing any restriction. The values are passed directly to the setrlimit(2) syscall, and should be specified in that context.
Types:
cpufsizedatastackcorerssnprocnofilememlock
Example:
rlimit cpu 15;
π¦ initgroups
The argument can be either yes or no. This directive causes initgroups(3) to be called at service startup, which sets the supplementary groups of the service according to the /etc/group file.
Example:
initgroups yes;
π family
This directive specifies the protocol family that rlinetd should bind sockets on for this service. Currently, this can be either ipv4 or ipv6. If unspecified, this defaults to something appropriate for the system.
Example:
family ipv6;
π banner
This directive lets you dump a file as output to a connection.
Example:
banner "/etc/nologin";
β echo
This directive allows you to output a dynamically generated line to the connection.
Example:
echo "500 Service denied from your IP (%O)";
π« filter
This directive allows you to specify a Linux Socket Filter program to be associated with the listening socket. These can be generated with a tool such as lsfcc(1).
Example:
filter "/usr/local/lib/rlinetd/filters/privport";
π₯ chargen
This directive loops eternally, outputting data to any connection. If no argument is given, it echoes a subset of the printable characters. However, a filename can be supplied as an argument, in which case the contents of that file are output in a loop.
Example:
chargen "/usr/local/lib/spam";
π log "name" { ... }
This construct describes a logging target. The name parameter is used as an argument to the log directive in service configurations. iykyk π
pathβ this is literally just where the logfile lives. hand over the filename and we're done π
Example:
path "/var/log/service.log";
modeβ the file permissions for the logfile, and yes it has to be numeric, no vibes-based guessing. if you don't say anything it defaults to0640. slay, sensible.
Example:
mode 0600;
userβ whose uid the logfile gets. you can drop it as a numeric uid or as a username, dealer's choice π
Example:
user "adm";
groupβ same energy, but for the gid. numeric gid or a groupname, both work β¨
Example:
group "adm";
π«Ά defaults { ... } π«Ά
okay so this construct takes the exact same parameters as a service declaration, but the plot twist is it doesn't declare a service at all β instead it sets the defaults for every single service that gets specified after it. main character energy, honestly.
πΈ directory "path" "match" "ignore"; πΈ
this one names a directory that's holding extra configuration files to be parsed. and here's the thing bestie β parsing of those extra files does not start until the current file is totally complete. no cutting in line π
the match and ignore arguments are optional, and if you do give them, they filter what's in the directory. a filename must match the match regexp if one is given, and must not match the ignore regexp if one is given. and filenames starting with a period (.) get skipped in all cases, no exceptions, periodt. directories are not recursed into, so don't come looking for a deep dive π
π¦ String Modifiers π¦
so there's a bunch of variables you can substitute into the arguments of some directives. and yes they can all be used in the same places, but ngl β the info that some of them pull in is just unavailable in certain cases. not a bug, just how it is.
%Oβ the source IP address of the connection.%Pβ the source port of the connection.%Cβ the total CPU time used.%Uβ the user CPU time used.%Sβ the system CPU time.%rβ maximum resident set size.%mβ shared memory size.%dβ unshared data size.%sβ unshared stack size.%fβ page reclaims.%Fβ page faults.%pβ swaps.%iβ block input operations.%oβ block output operations.%nβ messages sent.%cβ messages received.%kβ signals received.%wβ voluntary context switches.%Wβ involuntary context switches.%eβ exit code.%tβ running time.%Mβ the current time expressed as seconds since epoch 1980, dumped as a network order 32 bit word. and bestie, this has absolutely no use other than implementing the inetd-like time functionality. that's it. that's the whole job π%Iβ the current time and date, in pretty-printedctime(3)format. it's giving cute, it's giving readable π
π SEE ALSO π
π AUTHOR π
this manual page was written by Mikolaj J. Habryn <dichro-doc@rcpt.to>. Modified by Robert Luberda <robert@debian.org>.
and that's a wrap on this one, bestie π this page comes to you from Debian, dated November 11th, 2013, and it's page RLINETD.CONF(5) β go forth and configure responsibly π
β¨
π¦ where this page comes from
- debian bookworm: rlinetd 0.9.3-1 Β· GPL-2.0-or-later
- debian trixie: rlinetd 0.9.3-3 Β· GPL-2.0-or-later
- ubuntu jammy: rlinetd 0.9.3-1 Β· GPL-2.0-or-later
- ubuntu noble: rlinetd 0.9.3-2 Β· GPL-2.0-or-later
- ubuntu questing: rlinetd 0.9.3-3
- ubuntu resolute: rlinetd 0.9.3-3build1 Β· GPL-2.0-or-later
- ubuntu stonking: rlinetd 0.9.3-4 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms