From EggWiki
Jump to navigation Jump to search

A "hostmask" is one of the methods Eggdrop uses to distinguish between users on IRC. However, the format often confuses new users.

Sections of a hostmask

There are three parts to a hostmask: The nickname, the ident, and the hostname. These three strings are combined to create a hostmask in the format of "nickname!ident@hostname".


The nickname portion of a hostmask is the nickname used by a user on IRC


The ident is a string (generally) provided by your server when you register with IRC.

Ident history

"Back in the day", the ident value was provided by an ident daemon running on the server. The intent was to associate an IRC connection with a specific user from the server, thereby adding a level of non-repudiation to connections and assisting in banning unwanted users with a dynamic IP (such as reconnecting on a dialup connection). Usually, the ident provided was the account name of the user running the client. However, if the server was queried and did not supply an ident response, the server would instead query the client, which could reply with a customizable string. An IRC server would denote this client-chosen ident by prefixing it with a '~' character (nickname!


The hostname can be either an IP or a string (, or

Matching hostmasks

Eggdrop (and IRC) uses hostmasks in several ways. One such way is to associate users in a channel with users added to the Eggdrop's internal user management system. Because hostmasks can change from connection to connection (or even just changing a nickname) Eggdrop uses hostmask matching with wildcards to make it easier to track users. A '?' will match any single character, and a '*' will match any series of characters


A user with the ident "trogdor" has a dynamic hostname. It has been seen as,, and Valid hostmasks to match this user could be:

  • *!trogdor@dynamic-*
  • *!trogdor@dynamic-???

While adding broader hostmasks do make it easier to identify the user, overly broad hostmasks (such as *!*@*.com) will likely lead to users without access matching against hostmasks for users who do have access