Skip to content

Channel List Modes

Channel list modes maintain lists of hostmask patterns. Each entry in a list applies to users whose nick!ident@hostname matches the pattern.

All list modes use IRC hostmask format: nick!ident@hostname

Wildcards:

  • * — matches zero or more characters
  • ? — matches exactly one character

Examples:

*!*@192.168.1.100 # Specific IP
*!*@*.spammer.net # Entire domain
BadNick!*@* # Specific nick regardless of host
*!badident@* # Specific ident
Alice!*@* # User with nick "Alice"

Purpose: Prevent users matching the mask from joining the channel.

Setting a ban:

MODE #channel +b *!*@baduser.host.com
MODE #channel +b SpamBot!*@*

Removing a ban:

MODE #channel -b *!*@baduser.host.com

Listing bans:

MODE #channel +b

(or just MODE #channel b)

Behavior:

  • Masks are normalized on set (e.g., unanchored patterns get * prefix/suffix)
  • A banned user cannot join the channel and receives ERR_BANNEDFROMCHAN
  • A user who is already in the channel is not kicked by being banned — use KICK to remove them
  • If the user also matches a ban exception (+e), they are allowed in (exception wins)
  • Maximum entries: 100 (configurable via max_list_entries: %{"b" => 100})

Response format:

:server 367 yournick #channel mask setter timestamp
:server 368 yournick #channel :End of channel ban list

Purpose: Exempt users matching the mask from channel bans (+b).

Setting an exception:

MODE #channel +e TrustedUser!*@*
MODE #channel +e *!*@trusted.host.org

Removing an exception:

MODE #channel -e *!*@trusted.host.org

Listing exceptions:

MODE #channel +e

Behavior:

  • If a user matches a ban (+b) but also matches an exception (+e), the exception takes priority and they can join
  • Exceptions do not override invite-only (+i) — for that, use invite exceptions (+I)

Response format:

:server 348 yournick #channel mask setter timestamp
:server 349 yournick #channel :End of channel exception list

Purpose: Allow users matching the mask to join an invite-only (+i) channel without an explicit invite.

Setting an invite exception:

MODE #channel +I TrustedUser!*@*
MODE #channel +I *!*@staff.mynetwork.org

Removing an invite exception:

MODE #channel -I *!*@staff.mynetwork.org

Listing invite exceptions:

MODE #channel +I

Behavior:

  • Only relevant when the channel has +i set
  • Users matching +I can join the channel as if they had been explicitly invited
  • This does not override bans — a banned user matching +I is still banned
  • Explicit invites (from INVITE) are stored separately and work independently

Response format:

:server 346 yournick #channel mask setter timestamp
:server 347 yournick #channel :End of channel invite list

User situationChannel modesResult
Matches +b, no +e+i not setCannot join (banned)
Matches +b, matches +e+i not setCan join (exception overrides ban)
Matches +b, matches +I+i setCannot join (banned; +I doesn’t override ban)
Matches +I, no +b+i setCan join (invite exception)
Has explicit invite, matches +bCannot join (banned)
Has explicit invite, no +b+i setCan join