CSIS 440 chat client/server project.


   |                   d8b              d8888      d8888   .d8888b.  |
   |                   Y8P             d8P888     d8P888  d88P  Y88b |
   |                                  d8P 888    d8P 888  888    888 |
   |  .d8888b .d8888b  888 .d8888b   d8P  888   d8P  888  888    888 |
   | d88P"    88K      888 88K      d88   888  d88   888  888    888 |
   | 888      "Y8888b. 888 "Y8888b. 8888888888 8888888888 888    888 |
   | Y88b.         X88 888      X88       888        888  Y88b  d88P |
   |  "Y8888P  88888P' 888  88888P'       888        888   "Y8888P"  |

Filename: README
Author: Matt Kava
Class: CSIS 440, Spring 2010
Asmt: Asmt 6 - IRC-Like Client and Server using SimpleIRC Protocol

 * Table of Contents
    * Purpose / Description
    * File List
    * Compiling/Making
    * How to execute each binary
    * Known Bugs / Caveats
    * Additional Information / Comments

 * Purpose / Description
    This package is an implementation of the SimpleIRC IRC-like protocol
    agreed upon by the Spring 2010 CSIS 440 students and Dr. Rick Walker.
    It contains a working single-thread single-process server and a
    text-based Curses-based client that can connect and communication
    with the provided server.
    An example of the specification of the SimpleIRC protocol is included
    for reference purposes only. It is not the finalized version of the
    protocol that was used for the class.
        * Changes
            = Clients do not send any commands. A client can only send
              messages. The first message to a SimpleIRC server is the
              nickname for the client and all data sent after is a
              message that the server may relay.
            = A server only has to handle sending QUIT and JOIN messages
              to clients. A JOIN is sent to all connected clients when
              a new client connects, and a JOIN list is sent to the newly
              connected client detailing all previously connected clients.
              A QUIT is sent to all connected clients, excluding the
              disconnecting client, when a client is disconnecting.

 * File List
    = README                - This file
    = Makefile              - Makefile that compiles each binary
    = client.cpp            - Basic implementation of SircClient
    = server.cpp            - Implementation of SircServer
    = SircClient.cpp        - Implementation of a text-based SimpleIRC client.
    = SircClient.h          - Header file
    = SircServer.cpp        - Single-thread single-process implementation of
                              SimpleIRC protocol.
    = SircServer.h          - Header file
    = User.cpp              - Multi-purpose User class for holding information
                              related to a User and for the server to handle
                              communication with a connected client.
    = User.h                - Header file
    = constants.h           - Header file that declares constants usable for
                              both SircServer and SircClient to use.
    = SimpleIRC.txt         - An example specification of SimpleIRC
                              (Reasoning for including explained above)

 * Compiling/Making
    = Simply run 'make' in the same directory as the Makefile and both
      the server and client binaries will be compiled with the default
      names, as shown below.
    + Each binary can be compiled separately with no special treatment.
    = Default binary names using Makefile
        + client.cpp -> client
        + server.cpp -> server
    = The Makefile provides functionality to remove all binaries and
      object (.o) files.

 * How to execute each binary
    = Client
        + Takes 2 parameters.
            - Hostname 
                -- The name of the host to connect to (IP or Fully
                   Qualified Domain)
            - Port number (optional)
              This defaults to DEFAULT_WKS_PORT on the Sirc Constants
              file, constants.h 
                -- The port number to connect to.
    = Server
        + Takes 1 parameter.
            - Server port
               -- Port to accept connections on.

 * Known Bugs / Caveats
    = The server accepts input from stdin. If a control character is used,
      the results may vary. In this package, it only accepts 'die' and 'DIE'
      as means of gracefully shutting down the server. Known characters that
      break execution are Ctrl+D (^D or End-of-transmission character). The
      server will keep coming off of the select(...) function as it appears
      that the stdin is busy. Otherwise, the server will continue to operate.
      It will just keep grinding away and flooding stderr/stdout with text...

    = Client cannot send a single character to the server. This is proven to
      be a client issue (SircClient) as using telnet, it is possible to send
      a single byte of data and the server acts upon it appropriately.

 * Additional Information / Comments
    = Makefile allows for creation of individual binaries by using the
      default binary name, as provided above.

    = Hardware/OS: All of this was coded on a dual-core processer box (x86),
      running Fedora 12 using the kernel version
      from Dec 21, 2009.