Skip to content

A lightweight chat server that supports multiple concurrent users with private messaging, broadcasts, and random message sending. Uses TCP sockets, POSIX threads, and simple command parsing to handle users asynchronously. Includes dynamic port binding and notifications when users join or leave.

Notifications You must be signed in to change notification settings

kushalchaka/ClientServerMessageRoom

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

ClientServerMessageRoom

A lightweight chat server that supports multiple concurrent users with private messaging, broadcasts, and random message sending. Uses TCP sockets, POSIX threads, and simple command parsing to handle users asynchronously. Includes dynamic port binding and notifications when users join or leave.

To use, compile the server program and run it. It should output a port number that can be used by clients to connect.

For clients to connect, they need to enter the following command

ncat <hostname> <port#>

The hostname can be found with the hostname command, and the port number is provided by the server upon running

Clients can type 'list' to see all connected users, 'send <username>' to send a private user, 'broadcast' to send a message to all connected users, and 'random' to send a message to a random connected user

About

A lightweight chat server that supports multiple concurrent users with private messaging, broadcasts, and random message sending. Uses TCP sockets, POSIX threads, and simple command parsing to handle users asynchronously. Includes dynamic port binding and notifications when users join or leave.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages