IRC (Internet Relay Chat) Tutorial

From distributed.net
Jump to navigationJump to search

Introduction

IRC (Internet Relay Chat) is a way of communicating in real time with people all over the world. IRC is similar to instant-messaging tools except that it is focused on group conversations instead of person-to-person messaging. distributed.net owes its existence to IRC, and IRC is likely to always be the most effective way of getting help using dnetc if the FAQ doesn't have the answer to your question.

The channel #distributed normally has quite a few people in it and ranges in activity from hectic to very quiet. You will be able to chat with whoever is in the channel at the time. Although it's the official distributed.net channel, the discussion can frequently stray to other topics.

distributed.net uses the Libera Chat IRC network which is the home of all the official distributed.net channels, in addition to a variety of channels supporting projects unrelated to distributed.net. You may access the network by connecting to alias irc.libera.chat which will connect you to one of the public servers at random.

Libera.Chat supports secure and encrypted access to its IRC network. You can connect to any of the public servers on ports 6697, 7000, and 7070 with an SSL-enabled connection and enjoy the benefits of truly private communications to the network. Today, several IRC clients include native support for SSL encryption, but if yours does not, please read the rest of this document for more details on enabling irc-ssl in your environment. For up-to-date information, please visit Connecting to Libera.Chat.

There are some rules designed to limit inappropriate behaviour on our IRC channel which can be found in our policies document.

Popular IRC Client Software

In order to use IRC (Internet Relay Chat), you will first need to download an IRC Client if you have not already done so. Popular IRC clients for major platforms are:

Windows: mIRC
MacOS Textual
Unix X GUI: xchat
Unix Console: EPIC or irssi
Web browser based: Mibbit AJAX client or Chatzilla or Libera.Chat webchat

In addition to the above suggestions, there are many other options available.

Once you have downloaded a client, you will need to configure the software. Use the documentation provided with the software to do this.

The two main settings that need to be configured are a nick name you are going to be identified by and selection of one or more IRC servers you will use to connect to the IRC network.

IRC Basics

The people on #distributed normally include DCTI staff and experienced users of the client from around the world, so it's more than likely that someone will be able to help if you have a question concerning any aspect of distributed.net. A number of the DCTI staff are Channel Operators (Ops). Ops can be identified by a @ before their nick in /names listings and generally highlighted in some way in the user lists in GUI IRC clients. Channel Operators monitor the channel, and will kick (remove) anyone whose behaviour is not acceptable. When you join the channel, until you get used to using IRC, it is a good idea just to watch for a few minutes and see what's going on, also known as "lurk".

For a more detailed primer on IRC usage and information, try http://www.irchelp.org/.

Advanced Usage: irc-ssl

Although many channels, such as #distributed are public and don't require encryption to protect the discussions that take place within them, being able to secure your connection to the IRC network is valuable for protecting the privacy of private messages to other users or services bots as well as protecting the communications in any non-public channels you may join. All Libera.chat IRC servers support secure SSL connections on ports 6697, 7000, and 7070 to enable this.

Secure IRC is fairly well-supported today. The Unix client xchat and Windows client mIRC have built in support. If you prefer a console client, we recommend irssi which also supports ssl natively. Even if your client still doesn't support ssl natively, it's possible to use a great package called stunnel to wrap around any normal irc client in both Windows and Unix to enable an irc-ssl connection.

For Unix, the procedure depends on whether you have the current or an older version of stunnel. For the current version (5.x) you will need to create a configuration file called stunnel.conf in your home directory with the following:

 client = yes
 verify = 0
 delay = yes
 [dnet]
 accept = 6667
 connect = irc.libera.chat:7000
 TIMEOUTclose = 0

Then run the following commands in your home directory, after substituting the name of your irc client and your nick:

  $ stunnel stunnel.conf
  $ ircii MyNick www.distributed.net

For older versions of stunnel (3.x or earlier), you'll want to do something along the lines of the following, after substituting the name of your irc client and your nick:

  $ stunnel -c -d www.distributed.net:6667 -r irc.libera.chat:7000 &
  $ ircii MyNick www.distributed.net

This runs stunnel as a daemon, encrypting your local port 6667 to the Libera.Chat IRC network. Then you're simply running your normal IRC client and connecting to "www.distributed.net" instead of the remote server.

Windows usage is very similar:

  1. Download and install stunnel
  2. Create a file stunnel.conf in the same location as the stunnel executable with the same content as the Unix description above.
  3. Start | Run the following command (changing the path to where you installed the executable if not "Program Files" directory)
    C:\Program Files\irc-stunnel\stunnelw.exe
    You should see a little white SSL box appear in your system tray.
  4. You may wish to consider adding that command to your Startup folder.
  5. Run your IRC client and configure it to connect to "www.distributed.net" instead of a remote server. In mIRC, this is simply a matter of typing "/server localhost" in your mIRC window.

Advanced Usage: Services

The Libera.Chat IRC network runs a comprehensive suite of services bots which are responsible for maintaining the sanity and integrity of the users and channels on the IRC network. Regular users of the network are encouraged to utilize these bots to make their IRC experience more useful.

NickServ allows you to register your nick with the network and protect it with a password to prevent people other than you from using your nick when you are not connected to IRC. Registering your nick is also the foundation required in order to use most of the other services on the network.

Once you've connected using the nick you wish to register, simply send a message to NickServ in the form of:

  /msg NickServ register <password> <email address>

This will register the nickname to you, and protect it with a password. See Nickname Registration for more details.

After having registered your nick, you'll want to automate the registration process in your IRC client. Many clients support authenticating with Nickserv, while some require a script to perform the action.

As with all the bots, you can /msg NickServ help for detailed help.

ChanServ allows you to register channels on the network and control who can join them and set other permanent attributes for it. Most users will not need to use ChanServ services.

MemoServ allows you to leave messages for other registered nicks, even if that person is not currently online. Other users can use MemoServ to send messages to you, as well. Sample usage:

  /msg MemoServ send Nugget Cows are cool!
  /msg MemoServ list

Advanced Usage: Non-standard Stuff

The following is a list of user mode flags and their meanings:

User mode Meaning
o Global IRC Operator
O Local IRC Operator
i Invisible (Not shown in /WHO searches)
w Can listen to Wallop messages
g Can read & send to GlobOps, and LocOps
h Available for Help (Help Operator)
s Can listen to Server notices
k Sees all the /KILLs which were executed
S For Services only. (Protects them)
a Is a Services Administrator
A Is a Server Administrator
N Is a Network Administrator
T Is a Technical Administrator
C Is a Co Administrator
c Sees all Connects/Disconnects on local server
f Listen to Flood Alerts from server
r Identifies the nick as being Registered
x Gives the user Hidden Hostname
e Can listen to Server messages sent to +e users (Eyes)
b Can read & send to ChatOps
W Lets you see when people do a /WHOIS on you (IRC Operators only)
q Only U:lines can kick you (Services Admins only)
B Marks you as being a Bot
F Lets you receive Far and Local connect notices
I Invisible Join/Part. Allows you to be hidden in channels
H Hide IRCop status in /WHO and /WHOIS. (IRC Operators only)
d Stops you receiving channel PRIVMSGs (Deaf)
v Receive infected DCC send rejection notices
t Says that you are using a /VHOST
G Filters out all Bad words in your messages with <censored>.
z Marks the client as being on a Secure Connection (SSL)

The following is a list of channel mode flags and their meanings:

Channel mode Meaning
p Private channel
s Secret channel
i Invite-only allowed
m Moderated channel, Only users with mode +voh can speak.
n No messages from outside channel
t Only Channel Operators may set the topic
r Channel is Registered
R Requires a Registered nickname to join the channel
c Blocks messages with ANSI colour (ColourBlock).
q Channel owner
Q No kicks able in channel unless by U:Lines
O IRC Operator only channel (Settable by IRCops)
A Server/Net/Tech Admin only channel (Settable by Admins)
K /KNOCK is not allowed
V /INVITE is not allowed
S Strip all incoming colours away
l <number of max users> Channel may hold at most <number> of users
b <nick!user@host> Bans the nick!user@host from the channel
k <key> Needs the Channel Key to join the channel
o <nickname> Gives Operator status to the user
v <nickname> Gives Voice to the user (May talk if chan is +m)
L <chan2> If +l is full, the next user will auto-join <chan2>
a <nickname> Gives protection to the user (No kick/drop)
e <nick!user@host> Exception ban - If someone matches it they can join even if a ban matches them
h <nickname> Gives HalfOp status to the user
f [*]<lines>:<seconds> align="center"banned
H No +I users may join (Settable by Admins)
N No Nickname changes are permitted in the channel.
G Makes the channel G Rated. Any badwords are replaced with <censored> in channel messages (badwords.channel.conf).
u "Auditorium". Makes /NAMES and /WHO #channel only show Operators.
C No CTCPs allowed in the channel.
z Only Clients on a Secure Connection (SSL) can join.

Services Script for irssi

With perl-based scripting, it's possible to do some really fancy things in irssi. There's a robust and featureful nickserv script available which was originally written by Sami Haahtinen. Nugget added on support for deferred channel joins and has published his copy at https://github.com/nugget/irssi-nickserv