Skip to content

Command: search#


Summary#

Command Default Level Global Only?
search 1 no

Description#

  • Matches a search value (or mask) against whitelist or blacklist entries.

Usage#

search ?chan? <value> [white|black|*] [-type <method>]
  • Channel parameter is optional. If not given, the bot will default to the originating channel, the channel the user has the most access in, or lastly, the default Armour channel.
  • If chan is specified, * denotes entries added as global, and ? denotes any channel (all channel entries)
  • Specify white to search only whitelists, black to search only blacklists, or * to search both list types (the default)
  • Add -type <method> and include the type of list entry to further restrict results.
Possible Methods
  • user: user ACCOUNT on network (e.g., X usernames on Undernet)
  • host or ip: host or IP
  • rname: realname field of client
  • regex: regular expression using format nick!user@host/realname
  • text: text match, whereby for whitelist entries to make the bot responds with comment and for blacklist entries the bot kickbans the client using reason as the kick message
  • country: two digit code of the IP address country of origin
  • asn: Autonomous System Number of the client's IP address
  • chan: matching channels the user is in (from /whois response)

Examples#

Search all channel entry values matching *foo* of all types:

@Empus | y search ? *foo*
 @yolk | list match: blacklist user: foo2 (id: 6 chan: #armour action: kickban hits: 0 added: 2 years, 246 days, 07:31:23 ago by: Empus!empus@172.16.164.1 reason: another test)
 @yolk | list match: blacklist user: foo (id: 9 chan: #armour action: kickban hits: 0 added: 2 years, 244 days, 00:51:39 ago by: Empus!empus@172.16.164.1 reason: abuse)
 @yolk | list match: blacklist host: *!foo@*.isp.com (id: 94 chan: #newchan action: kickban hits: 0 added: 0 days, 00:52:48 ago by: Empus!empus@172.16.164.1 reason: abuse)
 @yolk | search complete (results: 3 -- runtime: 0.003 sec)

Search all channel entry values matching *foo* of all only type host:

@Empus | y search ? *foo* -type host
 @yolk | list match: blacklist host: *!foo@*.isp.com (id: 94 chan: #newchan action: kickban hits: 0 added: 0 days, 00:54:38 ago by: Empus!empus@172.16.164.1 reason: abuse)
 @yolk | search complete (results: 1 -- runtime: 0.002 sec)

Search whitelist entry values matching *foo* of all only type host:

@Empus | y search ? *foo* white -type host
 @yolk | no whitelist match found for: *foo* (0.002 sec)


Command Description
cmds List commands available to user
add Add a whitelist or blacklist entry to database
help View the help for a given command
chanscan Scans the entire channel and acts upon matches
mod Modifies the settings of a list entry
rem Remove a list entry
scan Scan a client or value against lists and return results
view View an existing list entry