Home

nslay

Contents

Introduction

IRCBNX Chatterbot is a remake of the original Battle.net text gateway bot BNX Chatterbot for IRC. Like the original, it features a rule-based response system, an access system, and several moderation features, including:

  • On-demand banning/kicking (for those users with sufficient access).
  • Banning due to distasteful comments to the bot.
  • Splatterkick, a humorous way to ban a user.
  • Voteban, queries channel members whether or not to ban a user.
  • Wildcard-based shit list.
  • Channel flood protection, progressively warns, kicks and bans flooding users (not an original feature).
  • Seen list for keeping track of visitors of a channel.

Its chatter abilities are quite limited. The original read in user-defined DOS wildcard-like patterns and responses. For flexibility and simplicity, IRCBNX instead uses regular expressions. Unmatched rules are met with one of four default responses. Its chattering can be enabled or disabled on demand. It will also permanently ignore users who either tell it to "shutup" or attempt to abuse it.

Unfortunately, the exact origins of the original BNX Chatterbot are unknown.

History

Around the late 1990's, Battle.net featured a text gateway for use by bots and telnet users. Battle.net lacked many of the channel protection mechanisms commonly seen in IRC today. It also had restrictions such as 1 operator per channel. There was no such thing as a half op (or any other IRC mode). Like IRC, it also had network splitting and nickname collision problems (many splits were severe).

Groups of gamers (called "clans") used to meet up consistently in a common private channel. Some rival clans would try to take over the channel and this prompted the development of moderation bots. However, bots were also being developed to take over channels too. BNX is among one of the earliest moderation bots to appear on Battle.net. Other common examples included (not chronological order):

  • Winters bot
  • Wolf`C`Bot
  • UltimateBot

Eventually, takeover wars became a game in itself. An entire bot development culture emerged to produce several varieties of takeover and moderation bots. This community even reverse engineered the challenging game authentication protocols to produce ever more sophisticated takeover bots. You could login up to eight bots as apparent game clients where the text gateway only permitted one.

Around the mid 2000s, Battle.net attempted to address the takeover wars. They created so-called "Clan" channels that would only give operator status to a user sharing the name of the channel (e.g. nslay would be the unique channel operator of "Clan nslay"). However, as takeover wars had become a sport, clans continued to pit bots against bots in private channels. Finally, Battle.net restricted all text gateway connections to designated public channels. This effectively marked the end of text gateway bots. However, bots that authenticated as games still continued to wage takeover wars for a short time until finally private channels no longer featured operators.

The text gateway met its end in the late 2000s when it was deemed to be abused by spammers and advertisers.

Server and Bot Case Mapping

While it seems to be a good idea to use the same case mapping as the server reports in RPL_ISUPPORT, it turns out that this introduces problems. Particularly, the hostmasks in the user list and shit list can potentially change their meaning between servers. There are also some internal programming problems that I can't seem to remember at the moment.

For simplicity and consistency, one case mapping (ascii) will be used for user-to-bot communications. The case mapping should only really matter in bot-to-server communications. Aside, it seems reasonable to assume that servers will report nicknames in their original form so that even case-sensitive comparisons could be used for IRC accounting (e.g. such as maintaining internal channel lists).

As of late January 2013, the bot now honors case mapping when dealing with the server. This change only affects two areas of the bot's programming:

  • Determining if the target of an IRC command (protocol) is the bot itself.
  • Channel accounting (maintaining internal channel lists).

The standard does not disallow the server from doing something unusual such as converting nicknames to lower case (or upper case) in IRC commands (protocol). I also suspect that nickname collisions could be problematic.

However, the access and shit list will always be interpreted in ascii case mapping. This ensures consistent interpretation of the lists across IRC networks (wherever you may bring the bot).

Implementation Status

This is a break-down of implemented features and those that remain to be implemented. Many details are not listed but are added when remembered.

  • Basic IRC support
    • Basic socket code (done)
    • Reconnect logic (done)
    • Protocol parsing (done)
    • High level event dispatching (done)
    • IRC traits (RPL_ISUPPORT) (done)
    • Wildcards (done)
    • Channel accounting (done)
    • Send queue (done)
    • Server-side ban list management
  • Basic CTCP support (done)
    • Encode mixed CTCP messages (done)
    • Decode mixed CTCP messages (done)
    • Version (done)
    • Action (done)
    • Time (done)
    • Ping (done)
  • Configuration file (done)
  • Logging
    • Basic socket events (done)
    • File I/O errors
    • Log auto-shitlisted users (done)
    • Log auto-ignored users (done)
    • Log failed login attempts (done)
  • Bot Behavior
    • Automatic responses (done)
      • Regex rules (done)
      • Auto-ignore users who tell bot to shutup (done)
      • Auto-ignore users who abuse the bot (done)
    • Shit list users who kick the bot (done)
    • Ban users for distasteful comments to the bot (done)
    • Ban shit listed users upon joining the channel (done)
    • Periodically attempt to rejoin channels that the bot was banned/kicked from (done)
    • Anti-idle messages (historical, not useful on IRC)
  • User commands
    • shutup (done)
    • chatter (done)
    • login (done)
    • logout (done)
    • say (done)
    • shutdown (done)
    • userlist (done)
    • useradd (done)
    • userdel (done)
    • shitlist (done)
    • shitadd (done)
    • shitdel (done)
    • kick (done)
    • ban (done)
    • unban (done)
    • voteban (done)
    • splatterkick (done)
    • ignore/squelch (done)
    • unsquelch (done)
    • designate (not applicable on IRC)
    • join (done)
    • where (done)
  • New or planned features
    • User commands
      • part (done)
      • nick (done)
      • op/deop (done)
      • mode
      • topic
      • rejoin (done)
      • who (done)
      • seen (done)
      • lastseen (done)
    • Logging
      • Log nickname registrations and changes (done)
      • Log channel flood kick/ban warnings (done)
    • DCC chat (for secure access)
    • Channel flood protection (done)
    • Support invites
    • Support channel keys

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks