OIDENTD.CONF(5)
NAME π β oidentd.conf / OIDENTD.CONF(5) and we're so back
okay so this is the oidentd.conf manual page, bestie β OIDENTD.CONF(5), straight from the oidentd User Manual. Itβs literally the tea on how oidentdβs config files work. π«Ά
DESCRIPTION πΈ
The oidentd config files control what oidentd sends back to clients after it gets a query about a connection owned by a particular user. π
- The system-wide config file
/usr/local/etc/oidentd.confsays what types of responses individual users are allowed to send. By default, users must respond with their real username. No cap. - The user config files
~/.config/oidentd.conflet users send custom Ident responses or hide their identities β but only if theyβve been granted the necessary capabilities through the system-wide config file. If this file does not exist oroidentdwas compiled without XDG Base Directory support, the file~/.oidentd.confis used instead. Note that user config files are read only after a connection is determined to belong to the user in question. π¦
SYSTEM-WIDE CONFIGURATION FILE π
The system-wide config file is used to grant capabilities to users or force users to use a certain capability. The default behavior is not to grant any privileges, which means all users must send their real usernames in response to Ident queries. The system-wide config file may be empty or missing, in which case this default applies. Changes to this file take effect only after oidentd is reloaded β which occurs when a SIGHUP signal is received β or restarted. β
The system-wide config file contains zero or one directive of the following form:
default {
range-directives...
}
This default directive matches all users for which no explicit rules have been defined. Any user directives following this directive inherit the capabilities it defines. If present, the default directive should be the first directive in the user configuration file. π
The system-wide config file may also contain zero or more directives of the following form:
user username {
range-directives...
}
This user directive applies only to the specified user. π«
USER CONFIGURATION FILE π¦
Each user may create a user config file at ~/.config/oidentd.conf or ~/.oidentd.conf. This file must be readable by the user oidentd runs as. The user config file is read automatically after every successful lookup, so any changes take effect immediately. Literally instant. β¨
The user config file contains zero or one directive of the following form:
global {
capability-statements...
}
This global directive matches all connections owned by the user. If present, it should be the first directive in the user config file. π
The user config file may also contain zero or more directives of the following form:
range-specification {
capability-statements...
}
This range directive applies only to connections that match the given range specification. π¦
RANGE DIRECTIVES π
At most one range directive in any given scope may take the following form:
default {
capability-directives...
}
This default directive defines rules for all connections that do not match any other range directive. If present, the default directive should be the first directive in its scope. π
A range directive may also take the following form:
range-specification {
capability-directives...
}
This range directive applies only to connections that match the given range specification. π
RANGE SPECIFICATIONS π₯
A range specification consists of filters that define which connections a range directive applies to. It takes the following form:
to fhost fport fport from lhost lport lport
This range specification matches only connections with the specified foreign host, foreign port, local host, and local port. At least one of these filters must be specified. Omitted filters match any value. Filters may be specified in any order. π₯
- The
fhostfilter specifies the foreign host or address of a connection, from the perspective of the machine runningoidentd. - The
fportfilter specifies the foreign port or port range of a connection. - The
lhostfilter specifies the local host or address of a connection, from the perspective of the machine runningoidentd. This may be useful for supporting virtual hosts on systems with more than one IP address. - The
lportfilter specifies the local port or port range of a connection.
Ports can be specified either numerically (e.g., 113) or using a service name (e.g., ident). Port ranges are specified numerically as min:max. The min port may be omitted to select all ports less than or equal to the max port. Likewise, the max port may be omitted to select all ports greater than or equal to the min port. π
CAPABILITY DIRECTIVES β
A capability directive may take one of the following forms:
allow capabilityβ grants the user permission to use the specified capability.deny capabilityβ revokes the userβs permission to use the specified capability.force capability-statementβ forces the user to use the specified capability.
periodt. β
CAPABILITIES π
The following expressions are valid capabilities:
forward,hide,numeric,random,random_numericβ these are valid capabilities, and they let users use the corresponding capability statements. π«spoofβ lets users send custom Ident replies. Note that this does not include replying with the name of another user or spoofing replies for connections to privileged foreign ports. πspoof_allβ lets users reply with the names of other users. This capability should be used with care, as it allows users to impersonate other users on the local system. Thespoof_allcapability only works in conjunction withspoof, but does not imply it. Careful, bestie. πspoof_privportβ lets users spoof replies for connections to privileged foreign ports (with port numbers below 1024). Thespoof_privportcapability only works in conjunction withspoof, but does not imply it. π₯
CAPABILITY STATEMENTS β¨
A capability statement may take one of the following forms:
forward host portβ forward received queries to another Ident server. The target server must support forwarding (likeoidentdwith the--proxyoption). Additional capabilities may be required for forwarding to succeed. For example, thespoofcapability is required if the target server sends a response other than the userβs name on the forwarding server. It may therefore be desirable to also grant at least one ofhide,spoof,spoof_all, andspoof_privportin addition to theforwardcapability. Ifforce forwardis used, no additional checks are performed and no capabilities are required. If forwarding fails,oidentdresponds with a"HIDDEN-USER"error or with the userβs real username, depending on whether the user has been granted thehidecapability. Replies are logged, allowing the system administrator to identify which user sent a particular reply. π«Άhideβ hide Ident replies from clients. When this capability is used,oidentdreports a"HIDDEN-USER"error to Ident clients instead of sending an Ident reply. πnumericβ respond with the user ID (UID). π’randomβ send randomly generated, alphanumeric Ident replies. A new reply is generated for each Ident lookup. Replies are logged, allowing the system administrator to identify which user sent a particular reply. π²random_numericβ send randomly generated, numeric Ident replies between0(inclusive) and100,000(exclusive), prefixed with"user". A new reply is generated for each Ident lookup. Replies are logged, allowing the system administrator to identify which user sent a particular reply. π²reply reply1 [reply2 ...]β send an Ident reply chosen at random from the given list of quoted replies. When used in a user config file, at most20replies may be specified. In the system-wide config file, up to255replies may be specified. Replies are logged, allowing the system administrator to identify which user sent a particular reply. π
EXAMPLES π§
SYSTEM-WIDE CONFIGURATION FILE
default {
default {
allow spoof
}
fport 6667 {
deny spoof
allow hide
}
}
Allow all users to spoof Ident replies, except on connections to port 6667. Only on connections to port 6667, allow users to hide their Ident replies. π
user "root" {
default {
force hide
}
}
Hide all connections owned by the root user. π
user "lisa" {
lport 1024: {
force reply "me"
}
}
For connections owned by user "lisa" on local port 1024 or greater, always reply with "me", ignoring any settings in the user configuration file. π
USER CONFIGURATION FILE
global {
reply "paul"
}
Reply with "paul" to all Ident queries. β¨
to irc.example.net fport 6667 {
hide
}
Hide Ident replies for connections to irc.example.net on port 6667. π¦
STRING FORMATTING π
Strings may be enclosed in double quotes. This is useful for strings containing special characters that would otherwise be interpreted in an unintended way. π
Quoted strings may contain the following escape sequences:
\a alert (bell)
\b backspace
\f form feed
\n newline (line feed)
\r carriage return
\t horizontal tab
\v vertical tab
\\:\ backslash
\" double quotation mark
\\:NNN the character with octal numerical value NNN
\xNN the character with hexadecimal numerical value NN
COMMENTS π¬
After encountering a number sign (#), oidentd ignores any remaining text on the same line. This allows users to add comments to the config file. Comments can also be written in the following form, which allows them to span multiple lines:
/* comment */
iykyk. π¬
AUTHOR π«Ά
- Janik Rabe
<info@janikrabe.com>β https://janikrabe.com - Originally written by Ryan McCabe.
BUGS π
Please report any bugs to Janik Rabe <info@janikrabe.com>. π«Ά
SEE ALSO π
oidentd(8) oidentd_masq.conf(5)
thatβs the whole manual, bestie β sourced from oidentd 3.1.0, and youβre reading OIDENTD.CONF(5). ππ
π¦ where this page comes from
- alpine 3.22: oidentd-doc 3.1.0-r0 Β· GPL-2.0-only
- alpine 3.23: oidentd-doc 3.1.0-r0 Β· GPL-2.0-only
- alpine 3.24: oidentd-doc 3.1.0-r0 Β· GPL-2.0-only
- arch rolling: oidentd 3.1.0-1 Β· GPL
- nixos 26.05: oidentd 3.1.0
- nixpkgs unstable: oidentd 3.1.0
- opensuse-leap 16.0: oidentd 3.1.0-bp160.1.12 Β· GPL-2.0-or-later
- opensuse-leap 16.0: oidentd 3.1.0-bp160.1.12 Β· GPL-2.0-or-later
- opensuse-leap 16.0: oidentd 3.1.0-bp160.1.12 Β· GPL-2.0-or-later
- opensuse-leap 16.0: oidentd 3.1.0-bp160.1.12 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms