Skip to content

This is a realtime chat that uses WIN/LINUX api to manage sockets and create tcp connection between server and client. Also implements a caching system that save the messages between two peers.

License

Notifications You must be signed in to change notification settings

Peppo10/SocketFalco

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

77 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SocketFalco

This is a realtime chat that uses Win/Linux api to manage sockets and create tcp connection between server and client. Also implements a caching system that save the messages between two peers.

You have the possibility also to write message in offline mode when client or server quit the session. When the connection is re-established the peers will send the new messages each other.

Every chat is unique and depends on the uuid of the device connected to. Does not matter who is the server or the client, the chat will be the same.

Every device at first start-up will generate his uuid4, which will be used for the authentication.

Usage

SocketFalco -h   
Usage: SocketFalco [options] <arguments>

Options:
-l, -listen                   Start the server. Use -t for temporary session.
                              Example: SocketFalco -l
                                       SocketFalco -l -t

-ls, -list                    List available chat sessions.
                              Example: SocketFalco -ls

-c, -connect <address>        Connect to a specified server address. Use -t for temporary session.
                              Example: SocketFalco -c 192.168.1.1
                                       SocketFalco -c -t 192.168.1.1

-eN, -editName <name>         Edit the current user name.
                              Example: SocketFalco -eN NewName

-eC, -editChat <ChatUUID>     Open the specific chat
                              Example: SocketFalco -eC chatUUID

-h, -help                     Show this help message and exit.

Examples:
SocketFalco -listen                   Start the server.
SocketFalco -listen -t                Start the server in temporary mode.
SocketFalco -connect 192.168.0.1      Connect to the server at 192.168.0.1.
SocketFalco -connect -t 192.168.0.1   Connect to the server at 192.168.0.1 in temporary mode.
SocketFalco -list                     List all chat sessions.
SocketFalco -editName Alice           Change the username to "Alice".
SocketFalco -editChat 97b8b...        Open the specific chat and let the user to add new messages.

Note

  • If you want to save the chat you MUST exit by typing "quit" on the console.
  • Server can support localhost connection, you're just caching the same files, you can encounter a particular behaviour when a peer is sending new messages(they became duplicated).

Diagram

Diagram

Data Message Format

socket-realtime-cache-datagram drawio

About

This is a realtime chat that uses WIN/LINUX api to manage sockets and create tcp connection between server and client. Also implements a caching system that save the messages between two peers.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published