Table of Contents
This is a simple IRC server based on the RFC 2812
and following the C++ 98 standard. Even though this project mainly follows the RFC, it was not necessary by the Subject PDF, so some behaviours might differentiate from the original protocol. This is the first big project during our 42 Core Curriculum that we had to write in C++. The Server follows the reactor
design pattern and therefore handles concurrent service requests from one or more inputs by dispatching them synchronously to the associated request handlers.
The Project was mainly tested on macOS.
To connect to the server, you need to use an IRC Client that terminates packages with \r\n
.
I used WeeChat
as a reference client.
brew install weechat
weechat
- Clone the repo
git clone https://github.com/42sin/ft_irc.git && cd ft_irc
- Compile the project
make
- Start the server
./ircserv <port> <password>
- Connect to the server inside of weechat
/server add <name> <IP-Address>/<port> -password=<password> /connect <name>
SHUTDOWN
Shuts down the server, behaves the same as DIE from the RFC 2812PING
Pings the server, this is done in intervals by WeeChatPASS
Sends the password to the server, WeeChat does this on your first time connecting
USER
Sets a UsernameNICK
Sets a NicknameOPER
Sets a new OperatorPRIVMSG
|NOTICE
Sends a private message
INVITE
Invite someone to a channelJOIN
Join or create a new channelMODE (t, i, o, k, l)
Changes the Channel Mode, see Subject PDF for more informationsKICK
Ejects a client from a channelTOPIC
View or change the channel topicPART
Leave a channel
Distributed under the MIT License. See LICENSE
for more information.