Tip of the day: The Security article gives hands-on tips on how to deal with drone attacks, flooding, spammers, (D)DoS and more.

Standard variables

From UnrealIRCd documentation wiki
Jump to navigation Jump to search

You can use use certain variables like $nick and $ip in various config items.

This functionality only exists in UnrealIRCd 6.1.8 and later

Where

This functionality is available in: oper::vhost, vhost::vhost, blacklist::reason

Variables

The following variables are supported that expand information about the user:

  • $nick: Nickname
  • $username: Username (ident)
  • $realname: Real name (also called gecos)
  • $ip: IP address
  • $hostname: Hostname
  • $servername: name of the IRC server
  • $account: If logged into Services then the account name, otherwise 0 (zero)
  • $operlogin: If the user is an IRCOp, then the name of the Oper block
  • $operclass: If the user is an IRCOp, then the name of the operclass (oper::operclass)
  • $country_code: The country code of the user (eg: US) or XX if unknown.
  • $asn: The ASN of the users' IP, or 0 if unknown.

If the user is in the handshake phase then some fields will not be available such as $nick, simply because we have don't have that info yet. This happens for instance in case of quick blacklist killing, and thus applies to variables in blacklist::reason.