IRC bot
Encyclopedia
An IRC bot is a set of scripts
Scripting language
A scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...

 or an independent program
Computer program
A computer program is a sequence of instructions written to perform a specified task with a computer. A computer requires programs to function, typically executing the program's instructions in a central processor. The program has an executable form that the computer can use directly to execute...

 that connects to Internet Relay Chat
Internet Relay Chat
Internet Relay Chat is a protocol for real-time Internet text messaging or synchronous conferencing. It is mainly designed for group communication in discussion forums, called channels, but also allows one-to-one communication via private message as well as chat and data transfer, including file...

 as a client
Client (computing)
A client is an application or system that accesses a service made available by a server. The server is often on another computer system, in which case the client accesses the service by way of a network....

, and so appears to other IRC users as another user. An IRC bot differs from a regular client in that instead of providing interactive access to IRC for a human user, it performs automated functions.

History

The historically oldest IRC bots were Bill Wisner's Bartender and Greg Lindahl's GM (Game Manager for the Hunt the Wumpus
Hunt the Wumpus
Hunt the Wumpus is an early computer game, based on a simple hide and seek format featuring a mysterious monster that lurks deep inside a network of rooms. It was originally a text-based game written in BASIC...

 game). Over time, bots evolved to provide special services, such as managing channels on behalf of groups of users, maintaining access lists, and providing access to databases.

Function

Often, an IRC bot is deployed as a detached program running from a stable host. It sits on an IRC channel to keep it open and prevents malicious users from taking over
IRC takeover
An IRC channel takeover is an acquisition of IRC channel operator status by someone other than the channel's owner. It has largely been eliminated due to the increased use of services on IRC networks.-Riding the split:...

 the channel. It can be configured to give channel operator status to privileged users when they join the channel, and can provide a unified channel operator list. Many of these features require that the bot be a channel operator. Thus, most IRC bots are run from computers which have long uptime
Uptime
Uptime is a measure of the time a machine has been up without any downtime.It is often used as a measure of computer operating system reliability or stability, in that this time represents the time a computer can be left unattended without crashing, or needing to be rebooted for administrative or...

s (generally running a BSD derivative or Linux
Linux
Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution. The defining component of any Linux system is the Linux kernel, an operating system kernel first released October 5, 1991 by Linus Torvalds...

) and a fast, stable Internet
Internet
The Internet is a global system of interconnected computer networks that use the standard Internet protocol suite to serve billions of users worldwide...

 connection. As IRC has become popular with many dial-up users as well, special services have appeared that offer limited user-level access to a stable Linux server with a decent connection. The user may run an IRC bot from this shell account
Shell account
A shell account is a user account on a remote server which gives access to a shell via a command-line interface protocol such as telnet or ssh....

. These services are commonly known as shell providers.

A bot can also perform many other useful functions, such as logging what happens in an IRC channel, giving out information on demand (very popular in IRC channels dealing with user support), creating statistics
Statistics
Statistics is the study of the collection, organization, analysis, and interpretation of data. It deals with all aspects of this, including the planning of data collection in terms of the design of surveys and experiments....

, hosting trivia
Trivia
The trivia are the three lower Artes Liberales, i.e. grammar, rhetoric and logic. These were the topics of basic education, foundational to the quadrivia of higher education, and hence the material of basic education, of interest only to undergraduates...

 games, and so on. These functions are usually provided by user-writable scripts, often written in a scripting programming language such as Tcl
Tcl
Tcl is a scripting language created by John Ousterhout. Originally "born out of frustration", according to the author, with programmers devising their own languages intended to be embedded into applications, Tcl gained acceptance on its own...

 or Perl
Perl
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Perl was originally developed by Larry Wall in 1987 as a general-purpose Unix scripting language to make report processing easier. Since then, it has undergone many changes and revisions and become widely popular...

, added to the bot in question. Channels dedicated to file sharing
File sharing
File sharing is the practice of distributing or providing access to digitally stored information, such as computer programs, multimedia , documents, or electronic books. It may be implemented through a variety of ways...

 often use XDCC
XDCC
XDCC was initially a script written in 1994 for ircII by . This script extends the ircII DCC command.Now XDCC refers to IRC bots running file sharing programs in general. XDCC bots serve one or more usually large files for download using the DCC protocol...

 bots to distribute their files.

IRC bots are particularly well-used on IRC networks without channel registration services like ChanServ, such as EFnet
EFnet
EFnet or Eris Free network is a major IRC network, with more than 35,000 users. It is the modern-day descendant of the original IRC network.- History :...

 and IRCnet
IRCnet
IRCnet is one of the largest IRC networks with more than 60,000 users using it daily. An early 2005 record had approximately 123,110 users simultaneously connected to the network.-History:...

, and on networks that may prevent channels from being registered due to certain registration requirements (minimum user count, etc.), such as Undernet
Undernet
The Undernet is the fourth-largest publicly-monitored Internet Relay Chat network circa 2011, with about 12 client servers serving 60,000 users in 11,000 channels at any given time....

 or QuakeNet
QuakeNet
QuakeNet is currently the largest Internet Relay Chat network, with a peak average of about 135,000 users and 100,000 channels. The network was founded in 1997 by Garfield and Oli as a new home for their respective countries' Quake channels...

. Where bots are used for administrative functions such as this, they may need more access than a normal client connection allows. Some versions of IRC have a "Service" protocol that allows clients with these extra powers. Such server-sanctioned bots are called IRC services
IRC services
Internet Relay Chat services is a name for a set of features implemented on many modern Internet Relay Chat networks. Services are automated bots with special status which are generally used to provide users with access with certain privileges and protection...

.

Bots are not always welcome. Some IRC networks forbid the usage of bots. One of the reasons for doing so is that each nickname
Nickname
A nickname is "a usually familiar or humorous but sometimes pointed or cruel name given to a person or place, as a supposedly appropriate replacement for or addition to the proper name.", or a name similar in origin and pronunciation from the original name....

 connected to the network increases the size of the network database
Database
A database is an organized collection of data for one or more purposes, usually in digital form. The data are typically organized to model relevant aspects of reality , in a way that supports processes requiring this information...

 which is being kept in sync
Synchronization
Synchronization is timekeeping which requires the coordination of events to operate a system in unison. The familiar conductor of an orchestra serves to keep the orchestra in time....

 across all servers. Allowing for bots in large networks can cause a relevant amount of network traffic
Internet traffic
-Historical Internet Traffic Growth:Because of the distributed nature of the Internet, there is no single point of measurement for total Internet traffic...

 overhead which needs to be financed and may even lead to netsplit
Netsplit
In computer networking, specifically Internet Relay Chat , netsplit is the disconnection of a given node from the previously established network or between two nodes. As an IRC network is an undirected acyclic graph, a split between any two nodes splits the entire network into two pieces.Consider...

s. This however is a shortcoming of the IRC technology, not the bots.

People that create an IRC bot use either the scripting language
Scripting language
A scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...

 built into a client, or appropriate framework
Software framework
In computer programming, a software framework is an abstraction in which software providing generic functionality can be selectively changed by user code, thus providing application specific software...

s of a suitable programming language
Programming language
A programming language is an artificial language designed to communicate instructions to a machine, particularly a computer. Programming languages can be used to create programs that control the behavior of a machine and/or to express algorithms precisely....

to connect to an IRC server(s), or they use an existing bot implementation, and adapt it to their needs.
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK