Giter VIP home page Giter VIP logo

42-ft_irc's Introduction

42-ft_irc's People

Contributors

kny-i avatar nihkck avatar shuta-syd avatar

Watchers

 avatar

Forkers

kny-i

42-ft_irc's Issues

TODO

  • SIGKILLされた時などにuser実態を削除する
  • SIGQUIT(ctrl+z)のときhang upしないで処理継続するようにする

エラー

- NICK()時にseverにあるchannelのメンバーのClientには反映されていない
- NICKの後のPRIVMSGでメッセージが2回送られる
- mapの要素、vectorの要素をポインタにしたらQUITでセグフォする
- QUITしてもまだNICKの再利用できない
-> nick_to_fdだけeraseされてないのが問題

- 同じ名前で入ってしまってからもう一同違うNickで接続するとfdが0になる
- KICK, PARTでMode +oで権限付与したoper権限消えていない

Subjects

Notes

  • Your program should not crash in any circumstances (even when it runs out of memory)
  • Any external library and Boost libraries are forbidden.

Requirements

  • Your Makefile must at least contain the rules: $(NAME), all, clean, fclean and re.

  • Compile your code with c++ and the flags -Wall -Wextra -Werror

  • Your code must comply with the C++ 98 standard. Then, it should still compile if you add the flag -std=c++98.

  • The server must be capable of handling multiple clients at the same time and never hang.

  • Forking is not allowed. All I/O operations must be non-blocking.

  • Only 1 poll() (or equivalent) can be used for handling all these operations (read, write, but also listen, and so forth).

  • Your reference client must be able to connect to your server without encountering any error.

  • Communication between client and server has to be done via TCP/IP (v4 or v6).

  • Using your reference client with your server must be similar to using it with any official IRC server. However, you only have to implement the following features:

  • You must be able to authenticate, set a nickname, a username, join a channel, send and receive private messages using your reference client.

  • All the messages sent from one client to a channel have to be forwarded to every other client that joined the channel.

  • You must have operators and regular users

  • Then, you have to implement the commands that are specific to operators.

  • Verify absolutely every possible error and issue (receiving partial data, low bandwidth, and so forth).

  • To ensure that your server correctly processes everything that you send to it, the following simple test using nc can be done:

subject

Instructions

  • Your executable will be run as follows:
    ./ircserv <port> <password>
  • port: The port number on which your IRC server will be listening to for incoming IRC connections.
  • password: The connection password. It will be needed by any IRC client that tries to connect to your server.
  • Even if poll() is mentionned in the subject and the evaluation scale, you can use any equivalent such as select(), kqueue(), or epoll().
  • if you try to read/recv or write/send in any file descriptor without using poll() (or equivalent), your grade will be 0.
  • Several IRC clients exist. You have to choose one of them as a reference. Your reference client will be used during the evaluation process .
  • Since MacOS doesn’t implement write() the same way as other Unix OSes, you are allowed to use fcntl(). You must use file descriptors in non-blocking mode in order to get a behavior similar to the one of other Unix OSes.
  • However, you are allowed to use fcntl() only as follows: fcntl(fd, F_SETFL, O_NONBLOCK); Any other flag is forbidden.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.