21
Linux IRC mini-HOWTO Frédéric L. W. Meunier v0.4 7 January, 2005 Revision History Revision 0.4 2005-01-07 Revised by: fredlwm Fifth revision. This document aims to describe the basics of IRC and respective applications for Linux.

Linux IRC mini-HOWTO fileLinux IRC mini−HOWTO Frédéric L. W. Meunier v0.4 7 January, 2005 Revision History Revision 0.4 2005−01−07 Revised by: fredlwm Fifth revision

Embed Size (px)

Citation preview

Linux IRC mini−HOWTO

Frédéric L. W. Meunier

v0.4 7 January, 2005

Revision HistoryRevision 0.4 2005−01−07 Revised by: fredlwmFifth revision.

This document aims to describe the basics of IRC and respective applications for Linux.

Table of Contents1. Introduction.....................................................................................................................................................1

1.1. Objectives.........................................................................................................................................11.2. Miscellaneous...................................................................................................................................11.3. Translations.......................................................................................................................................2

2. About IRC........................................................................................................................................................3

3. Brief History of IRC.......................................................................................................................................4

4. Beginner's guide on using IRC......................................................................................................................54.1. Running the ircII program................................................................................................................54.2. Commands........................................................................................................................................54.3. IRC Etiquette....................................................................................................................................6

5. Console IRC Clients........................................................................................................................................75.1. ircII....................................................................................................................................................75.2. EPIC..................................................................................................................................................75.3. BitchX...............................................................................................................................................75.4. irssi....................................................................................................................................................75.5. Other Console IRC Clients...............................................................................................................8

6. X Window IRC Clients...................................................................................................................................96.1. Zircon................................................................................................................................................96.2. KVIrc................................................................................................................................................96.3. X−Chat..............................................................................................................................................96.4. QuIRC...............................................................................................................................................9

7. IRC Servers...................................................................................................................................................107.1. IRCD...............................................................................................................................................107.2. IRCD−Hybrid.................................................................................................................................107.3. ircu..................................................................................................................................................107.4. Bahamut..........................................................................................................................................10

8. IRC Bots.........................................................................................................................................................128.1. Eggdrop...........................................................................................................................................128.2. EnergyMech....................................................................................................................................12

9. IRC Bouncers (IRC Proxy)..........................................................................................................................139.1. bnc...................................................................................................................................................139.2. muh.................................................................................................................................................139.3. ezbounce.........................................................................................................................................13

10. Installation...................................................................................................................................................1410.1. Clients...........................................................................................................................................1410.2. Servers...........................................................................................................................................14

Linux IRC mini−HOWTO

i

Table of Contents11. But what's already included in my distribution ? (Linux on x86)..........................................................15

11.1. Debian...........................................................................................................................................1511.2. Fedora (Red Hat)...........................................................................................................................1511.3. Slackware......................................................................................................................................15

12. Hell and Paradise........................................................................................................................................1712.1. Gods (developers).........................................................................................................................1712.2. Saints (contributors)......................................................................................................................1712.3. Angels (feedback).........................................................................................................................1712.4. Devils............................................................................................................................................17

13. Revision History..........................................................................................................................................18

Linux IRC mini−HOWTO

ii

1. IntroductionThis document is still WIP, and should be treated as such. I'll do my best to keep it updated and accurate.

The following bibles shouldn't be ignored:

RFC 1459 by Jarkko Oikarinen and Darren Reed was the first about the Internet Relay Chat Protocol− http://ftp.isi.edu/in−notes/rfc1459.txt

RFC 2810 by Christophe Kalt updates RFC 1459 and describes the Architecture of the Internet RelayChat − http://ftp.isi.edu/in−notes/rfc2810.txt

RFC 2811 by Christophe Kalt updates RFC 1459 and describes the Channel Management of theInternet Relay Chat − http://ftp.isi.edu/in−notes/rfc2811.txt

RFC 2812 by Christophe Kalt updates RFC 1459 and describes the Client Protocol of the InternetRelay Chat − http://ftp.isi.edu/in−notes/rfc2812.txt

RFC 2813 by Christophe Kalt updates RFC 1459 and describes the Server Protocol of the InternetRelay Chat − http://ftp.isi.edu/in−notes/rfc2813.txt

Also be sure to check the following links:

http://www.irchelp.org/

1.1. Objectives

Among others, the objectives of this mini−HOWTO are:

Link important resources about IRC;• Avoid common misuses of IRC by writing an IRC Etiquette;• List popular clients, servers, bots, and bouncers, along with their maintainers, #channel, smalldescription, download location, home page, and hints;

List IRC tools available in the latest release of all major distributions.•

1.2. Miscellaneous

The latest version of this document is available athttp://www.pervalidus.net/documentation/IRC−mini−HOWTO/

A WIP of the next draft may be available athttp://www.pervalidus.net/documentation/IRC−mini−HOWTO/WIP/

All drafts are archived athttp://www.pervalidus.net/documentation/IRC−mini−HOWTO/old/

Everything may be mirrored athttp://www2.pervalidus.net/documentation/IRC−mini−HOWTO/

You can e−mail me (in English, French, or Portuguese) with suggestions about the mini−HOWTO. I knowthis is far from finished, but hope you find it useful. Just try to avoid asking me to add your application,distribution, or site. Most likely I won't, but you can try to persuade me. Also don't ask for technical support. I

1. Introduction 1

have no time to help everyone.

BTW, someone to work on the protocol and server sides would be very welcome.

Frédéric L. W. Meunier − http://www.pervalidus.net/contact.html

1.3. Translations

Proposed translations will be linked here. Although I can write in Brazilian Portuguese and French, I'm notgoing to translate this document in the near future, so feel free to make them.

Linux IRC mini−HOWTO

1. Introduction 2

2. About IRCExcerpt from RFC2810:

The IRC (Internet Relay Chat) protocol is for use with text based conferencing. It has been developed since1989 when it was originally implemented as a mean for users on a BBS to chat amongst themselves.

First formally documented in May 1993 by RFC 1459 [IRC], the protocol has kept evolving.

The IRC Protocol is based on the client−server model, and is well suited to running on many machines in adistributed fashion. A typical setup involves a single process (the server) forming a central point for clients (orother servers) to connect to, performing the required message delivery/multiplexing and other functions.

This distributed model, which requires each server to have a copy of the global state information, is still themost flagrant problem of the protocol as it is a serious handicap, which limits the maximum size a networkcan reach. If the existing networks have been able keep growing at an incredible pace, we must thankhardware manufacturers for giving us ever more powerful systems.

2. About IRC 3

3. Brief History of IRCThe first IRC daemon was written in the summer of 1998 by Jarkko "WiZ" Oikarinen of the University ofOulu, Finland. Originally intended as a BBS−style replacement for Talk, IRC quickly spread; first throughScandinavian, and then throughout the rest of the world. Within a year there were over 40 servers linked up.

At this stage there was only one network, and so a name unnecessary − it was simply 'IRC'; but as the size ofthe network grew, disagreements began to form. IRC was a pretty chaotic medium with netsplits, nickcollisions, and channel takeovers all commonplace; and it was inevitable that at some stage users would splitoff to form their own networks.

One of the first major splits was in 1992, when Wildthang created the Undernet network. Originally intendedas a test network, Undernet quickly grew, gaining a reputation as a friendly network due to it's introduction ofservices to protect users and channels.

Two years later, Undernet itself forked, the new networking becoming DALnet. DALnet's founder, dalvenjah,took Undernet's concept of services to a new level, introducing support for nick registration, G−lines, and ahost of other features.

Meanwhile on IRCnet (as the original IRC network was now known), feelings where running high. IRCnetwas opposed to the concept of channel/nick 'ownership' which Undernet and DALnet had introduced, butclearly something had to be done about the constant channel takeovers that were occuring. Two alternativeideas were proposed: nick/channel delay, and timestamping (see http://www.irc−help.org for information), butthere was bitter dispute over which to implement.

In July of 1996, IRCnet split, with most of the North American servers leaving to form EFnet, leaving IRCnetas a mostly European network.

Since then, hundreds of other smaller networks have formed, most using modified versions of either DALnet,EFnet, IRCnet, or Undernet's ircd.

3. Brief History of IRC 4

4. Beginner's guide on using IRCThe standard IRC client is the original ircII. It's part of most Linux distributions, and most other text−basedIRC clients (notably BitchX and EPIC) are derived from it.

4.1. Running the ircII program

It's easy to use ircII. Let's say you want to connect to irc.freenode.net as mini−HOWTO.

At the command line, type:

$ irc mini−HOWTO irc.freenode.net

You can also export variables, so you won't need to use them at the command line. For bash and zsh users:

$ export IRCNICK=mini−HOWTO IRCSERVER=irc.freenode.net

For csh and tcsh users, replace export with setenv.

Add them to your shell profile (e.g. ~/.bash_profile or ~/.zprofile) when you're done.

Other common variables are IRCNAME and IRCUSER, to respectively set the ircname part of a /whois andusername as seen at the first line 'mini−HOWTO is ~username@hostname (ircname)'. Keep in mind thatIRCUSER won't work if you run an ident daemon (default on most distributions). If you still need to changeyour username (not recommended, and I hope you're not using IRC logged as root !), install oidentd fromhttp://ojnk.sourceforge.net/ . To configure, read the oidentd.conf man page. Finally run'/usr/local/sbin/oidentd −g nobody −u nobody'. Add this to your startup scripts (e.g. /etc/rc.d/rc.local) whenyou're done.

If not set, IRCNICK, IRCUSER, and IRCNAME will be retrieved from /etc/passwd .

4.2. Commands

Use /help to get a list on all available commands (/help help is a good start). Replace nick by any IRCNICK.

First, /set NOVICE off• /nick IRC−mini−HOWTO changes your IRCNICK to IRC−mini−HOWTO• /set realname The Linux IRC mini−HOWTO changes your IRCNAME to The Linux IRCmini−HOWTO (doesn't change on the same connection)

/j #mini−HOWTO joins channel #mini−HOWTO• /j #unmaintained−HOWTO joins channel#unmaintained−HOWTO• /j #mini−HOWTO changes the active current channel to #mini−HOWTO• /msg nick Hi. sends a private message to nick containing Hi.• /notice nick (or #mini−HOWTO) Hi. sends a notice to nick (or #mini−HOWTO) containing Hi.• /query nick starts a private conversation with nick. /query ends the private conversation• /me uses Linux. sends an action to the current channel or query containing IRC−mini−HOWTO lovesLinux.

/dcc chat nick starts a chat with nick. Use /msg =nick (notice the =) to send messages over the chat•

4. Beginner's guide on using IRC 5

/dcc send nick /etc/HOSTNAME sends the given file to nick• /dcc get nick receives the file offered by nick• /part leaves the active current channel• /part #unmaintained−HOWTO leaves channel #unmaintained−HOWTO• /discon disconnects from current IRCSERVER• /server irc.oftc.net connects to IRCSERVER irc.oftc.net• /quit Bye. quits your IRC session with a reason Bye.•

Most of the above commands (including the use of environmental variables) will also work in otherconsole−based clients.

4.3. IRC Etiquette

WARNING WARNING WARNING WARNING WARNING

Never use IRC logged as root or any user with excessive privileges. Bad things may happen sooner orlater. You were warned. It's highly recommended you create an user only to use IRC.

$ man adduser

On Linux channels you shouldn't:

Act as an idiot. If you want to be respected, then first respect each other.• Use colors (^C). Most Linux users don't tolerate such mIRC crazes, and ircII doesn't really supportthem. The same should apply for ANSI.

Use full CAPS, bold (^B), reverse (^V), underline (^_), blink (^F), and bell (^G). The first 4 are hereto emphasize words, not the whole text. The last 2 are just very annoying.

Ask if you can ask a question. Just ask, but first read all documentation available on the subject. Startlooking at /usr/doc/ (on some systems it may be /usr/doc/, otherwise go tohttp://www.tldp.org/ or http://www.ibiblio.org/pub/Linux/docs/ . And don'trepeat your question immediately. Wait at least 10 minutes. If you don't get any answer it's becausenobody knows or wants to help. Respect their choice, they're not your personal assistant. Also neversend mass private messages. It's like spam.

Linux IRC mini−HOWTO

4. Beginner's guide on using IRC 6

5. Console IRC Clients

5.1. ircII

Maintainer: ircII project

IRC Channel: #ircII (official channel ?) on EFNet http://www.efnet.org/?module=servers

Originally written by Michael Sandrof, ircII comes with most Linux distributions. It uses termcap andshouldn't be a choice for most users, but is a standard. Mathusalem and other gurus will use it. Less venturedwill regret to have it installed.

You can get the latest version of ircII from ftp://ircii.warped.com/pub/ircII/ . Homepage athttp://www.eterna.com.au/ircii/

5.2. EPIC

Maintainer: EPIC Software Labs

IRC Channel: #EPIC on EFNet

Based on ircII, EPIC (Enhanced Programmable ircII Client) is meant for real scripters and users searchingfreedom. When you start it for the first time you'll notice that you should really learn the basics of scripting.

You can get the latest version of EPIC from http://prbh.org/?page=ftp . Homepage athttp://www.epicsol.org/

5.3. BitchX

Maintainer: Colten Edwards

IRC Channel: #BitchX on EFNet

Originally a script for ircII, BitchX is a popular client intended to reduce the need for scripting by including ahuge array of features in the client itself (too many features for even experienced users to remember). Manyconsider BitchX bloatware (not necessarily a bad thing), but it is very popular amongst users and opers alike.

You can get the latest version of BitchX from http://www.bitchx.org/download.php . Homepageat http://www.bitchx.org/

5.4. irssi

Maintainer: Timo Sirainen

IRC Channel: #irssi on freenode − http://freenode.net/irc_servers.shtml and IRCnet −http://www.ircnet.org/

5. Console IRC Clients 7

Timo released yagIRC in 1997. It was a GUI client using the GTK+ toolkit. The army called on him a yearlater, and the new maintainers wouldn't do the job. yagIRC passed away and he started irssi as a replacement.It used GTK+. GNOME and curses versions would appear later. As of 0.7.90 it's only a modular text modeclient. Supports Perl scripting.

You can get the latest version of irssi from http://irssi.org/?page=download . Homepage athttp://irssi.org/

5.5. Other Console IRC Clients

There are a few others ircII based clients.

Blackened − ftp://ftp.blackened.com/pub/irc/blackened/

Ninja − ftp://qoop.org/ninja/

ScrollZ − http://www.scrollz.com/

Linux IRC mini−HOWTO

5. Console IRC Clients 8

6. X Window IRC Clients

6.1. Zircon

Maintainer: Lindsay F. Marshall

IRC Channel: None ?

Written in Tcl/Tk, uses the native network communications of Tcl.

You can get the latest version of Zircon from ftp://catless.ncl.ac.uk/pub/ . Homepage athttp://catless.ncl.ac.uk/Programs/Zircon/

6.2. KVIrc

Maintainer: Szymon Stefanek

IRC Channel: #KVIrc on freenode

Also written with the Qt toolkit, KVIrc is a beast. Supports DCC Voice, built−in scripting language, andplugins.

You can get the latest version of KVIrc from http://www.kvirc.net/?id=download . Homepage athttp://www.kvirc.net/

6.3. X−Chat

Maintainer: Peter Zelezny

IRC Channel: #Linux on ChatJunkies − http://www.chatjunkies.org/servers.php

Using GTK+ and optionally GNOME, supports Perl and Python scripting.

You can get the latest version of X−Chat from http://xchat.org/download/ . Homepage athttp://xchat.org/

6.4. QuIRC

Maintainer: Patrick Earl

IRC Channel: #QuIRC on DALnet − http://www.dal.net/servers/index.php3

Using Tk, supports Tcl for scripting.

You can get the latest version of QuIRC from his Homepage at http://quirc.org/

6. X Window IRC Clients 9

7. IRC Servers

7.1. IRCD

Maintainer: ircd developers

IRC Channel: #ircd on IRCnet

The original IRC daemon, mainly used by IRCnet. Recent versions have attempted to improve on channelsecurity through the introduction of additional channel types (eg !linux), and channel modes.

You can get the latest version of IRCD from ftp://ftp.irc.org/irc/server/. Homepage athttp://www.irc.org/

7.2. IRCD−Hybrid

Maintainer:

IRC Channel: None ?

Mainly used by EFNet. Hybrid's focus is on speed and efficiency, since it lacks many of the services offeredby other networks. In keeping with EFnet's ethos that opers should not be concerned with channel matters,Hybrid doesn't allow opers to set modes on channels, or join channels from which they are banned. It is onlyrelatively recently that Hybrid offered the ability for a service bot to reop an opless channel.

You can get the latest version of IRCD−Hybrid fromhttp://ftp1.sourceforge.net/ircd−hybrid/ . Homepage athttp://www.ircd−hybrid.org/

7.3. ircu

Maintainer: Undernet Coder Committee

IRC Channel: #ircu on Undernet − http://www.undernet.org/servers.php

Mainly used by Undernet. Following a series of DDoS attacks in 2001/2002, ircu has offered the ability forusers and servers to hide their addresses. Many of the /stats commands have also (sadly) been removed fromUndernet.

You can get the latest version of ircu from http://ftp1.sourceforge.net/undernet−ircu/ .Homepage at http://coder−com.undernet.org/

7.4. Bahamut

Maintainer: DALnet Coding Team

IRC Channel: #Bahamut on DALnet

7. IRC Servers 10

Based on DreamForge and Hybrid, Bahamut is the DALnet server. Features include channel and nickregistration, support for nicknames up to 15(?) characters, and a memo service.

You can get the latest version of Bahamut from http://bahamut.dal.net/download.php .Homepage at http://bahamut.dal.net/

Linux IRC mini−HOWTO

7. IRC Servers 11

8. IRC Bots

8.1. Eggdrop

Maintainer:

IRC Channel: #eggdrop on Undernet

Generally considered to be the IRC bot, Eggdrop offers robust channel protection, and is highly customisablethrough the use of Tcl scripting.

Multiple eggdrops can be linked together forming a botnet which can span multiple channels, or evennetworks. On networks without channel registration services, eggdrops are common feature in almost all largechannels.

You can get the latest version of eggdrop from http://www.eggheads.org/downloads/ .Homepage at http://www.eggheads.org/

8.2. EnergyMech

Maintainer: Proton

IRC Channel: None

Early versions of EnergyMech (or emech as it is frequently called), earned a reputation as something of ascript kiddie's bot, through it's ability to run multiple bots from a single process (thus allowing less desirableusers to load up hundreds of vhosted clones from a shell account). This is a reputation emech does notdeserve, since it is really a rather good channel protection bot, and recent versions of emech have restrictedthis capacity (to max 4 bots). A popular alternative to Eggdrop.

You can get the latest version of EnergyMech from http://www.energymech.net/download.html. Homepage at http://www.energymech.net/

8. IRC Bots 12

9. IRC Bouncers (IRC Proxy)

9.1. bnc

Maintainer: James Seter

IRC Channel: None ?

bnc is the original bouncer.

You can get the latest version of bnc from http://gotbnc.com/download.html . Homepage athttp://gotbnc.com/

9.2. muh

Maintainer: Sebastian Kienzl

IRC Channel: None ?

muh is a smart and versatile irc−bouncing tool that will also go on IRC as soon as it's launched, guarding orattempting to get your nick.

You can get the latest version of muh from http://ftp1.sourceforge.net/muh/ . Homepage athttp://seb.riot.org/muh/

9.3. ezbounce

Maintainer: Murat Deligönül

IRC Channel: None ?

ezbounce's basic features include password protection, remote administration, logging and listening onmultiple ports.

You can get the latest version of ezbounce from his Homepage athttp://druglord.freelsd.org/ezbounce/

9. IRC Bouncers (IRC Proxy) 13

10. Installation

10.1. Clients

All popular clients use GNU Autoconf and GNU Automake, thus come with a configure script. Read theinstallation instructions after you unpack the sources. Be sure you have the required libraries in order tocompile. Doing cd name_of_the_created_directory; ./configure −−help; ./configure your_options_here; make;make install > ~/sources_install.log is the right procedure. Also note that for ircII, EPIC, and BitchX youshould really edit include/config.h to suit your needs.

10.2. Servers

Do you really need help to set up a server ?

~$ touch ircd.conf

10. Installation 14

11. But what's already included in my distribution? (Linux on x86)

11.1. Debian

IRC Channel: #Debian on freenode (irc.debian.org −> irc.freenode.net)

Debian − http://www.debian.org/ includes too many IRC tools to list. You can find them at thefollowing places:

Debian stable −http://ftp.debian.org/debian/dists/stable/main/binary−i386/

Debian unstable (didn't receive enough testing)http://ftp.debian.org/debian/dists/unstable/main/binary−i386/

Also be sure to check the proposed updates −http://ftp.debian.org/debian/dists/proposed−updates/ . It may contain IRCclients as well.

11.2. Fedora (Red Hat)

IRC Channel: #RedHat on freenode (irc.redhat.com −> irc.freenode.net)

Fedora Core 3 includes the following clients:

EPIC4 1.0.1 −http://download.fedora.redhat.com/pub/fedora/linux/core/3/i386/os/Fedora/RPMS/epic−1.0.1−18.i386.rpm

KSirc from KDE Network 3.3.0 −http://download.fedora.redhat.com/pub/fedora/linux/core/3/i386/os/Fedora/RPMS/kdenetwork−3.3.0−5.i386.rpm

X−Chat 2.4.0 −http://download.fedora.redhat.com/pub/fedora/linux/core/3/i386/os/Fedora/RPMS/xchat−2.4.0−3.i386.rpm

Rawhide (current development)• http://download.fedora.redhat.com/pub/fedora/linux/core/development/. Use at your own risk.

11.3. Slackware

IRC Channel: #Slackware on freenode and OFTC − http://www.oftc.net/

Slackware − http://www.slackware.com/ 10.0 includes the following clients:

BitchX 1.1 −ftp://ftp.slackware.com/pub/slackware/slackware−10.0/slackware/n/bitchx−1.1−i486−1.tgz

EPIC4 2.0 −ftp://ftp.slackware.com/pub/slackware/slackware−10.0/slackware/n/epic4−2.0−i486−1.tgz

irssi 0.8.9 −ftp://ftp.slackware.com/pub/slackware/slackware−10.0/slackware/n/irssi−0.8.9−i486−3.tgz

11. But what's already included in my distribution ? (Linux on x86) 15

KSirc from KDE Network 3.2.3 −ftp://ftp.slackware.com/pub/slackware/slackware−10.0/slackware/kde/kdenetwork−3.2.3−i486−1.tgz

X−Chat 2.0.9 −ftp://ftp.slackware.com/pub/slackware/slackware−10.0/slackware/gnome/xchat−2.0.9−i486−1.tgz

Slackware −current (current development)• ftp://ftp.slackware.com/pub/slackware/slackware−current/ . Use at your ownrisk.

Linux IRC mini−HOWTO

11. But what's already included in my distribution ? (Linux on x86) 16

12. Hell and Paradise

12.1. Gods (developers)

Thanks to all authors. Without their hard and volunteer work I'd never write it, and we'd never get ourhands on Linux nor IRC.

12.2. Saints (contributors)

See http://www.pervalidus.net/documentation/IRC−mini−HOWTO/•

12.3. Angels (feedback)

See above.•

12.4. Devils

Khaled Mardam−Bey must be stopped :−)• 'If idiots could fly, IRC would be an airport'. I don't know who wrote that, but it makes sense. Forthose of you using IRC to annoy people I ordered a /kill.

12. Hell and Paradise 17

13. Revision History20050107 − v0.4, fifth draft•

13. Revision History 18