Commit Graph

63 Commits

Author SHA1 Message Date
raul e3bd047d86 Fix Windows client not properly sending username 2024-05-27 10:40:59 +02:00
raul e48521b456 Merge pull request 'Security Update' (#6) from testing into main
Reviewed-on: #6
2024-05-17 08:00:12 +02:00
raul c837e78c7c Remove workflow file
The damn runner keeps making too many POST requests per minute to my
Gitea instance and flooding the entire access.log file, I'm gonna keep
using Goreleaser for easy binary releases but CI/CD unfortunately has to
go away
2024-05-17 07:59:04 +02:00
raul ff801f81d0 Final tweaks
Go audit / audit (pull_request) Has been cancelled Details
2024-05-16 08:10:19 +02:00
raul c7a34a7d93 Add option to render client UI in pure ASCII 2024-05-14 16:31:36 +02:00
raul b2f9ff5016 Small tweaks 2024-05-14 15:59:23 +02:00
raul 93c76f4242 Add chatbox text wrapping
How the hell did I manage to forget about this?
2024-05-14 15:42:03 +02:00
raul a21199a6e0 Optimize client RAM memory usage
The receiveMessage() function would regularly keep casting strings based
on a 2048 byte array, this didn't seemingly pose a problem until I
noticed the RAM usage go through the roof when the client had to be
populated with the chat history of a lengthy chat log by the server. To
fix this I am now creating a second array using the number of bytes
being returned by the Read() method and copying the 2048 byte array's
contents into it, setting the former array to nil afterwards.
2024-05-14 15:31:55 +02:00
raul 5bb37a53fe Add date formatting to messages
I also went ahead and removed adding the user's IP to each one of its
messages to retain the user's privacy and security.
2024-05-14 15:30:16 +02:00
raul e7aada9a2a Update README.md 2024-05-14 10:05:02 +02:00
raul 6d15f303b7 Fix extra newlines being appended by populateChat() on TLS based servers
For some reason, writing to a conn variable on a TLS connection
appends newlines by default, so new users will have their chat box
populated if the server is using --history/-r with messages that have
unnecessary newlines
2024-05-14 09:58:09 +02:00
raul 872523700b Minor formatting changes 2024-05-14 09:27:23 +02:00
raul 7493af68fc Implement choosing TLS/plaintext for client 2024-05-14 09:26:45 +02:00
raul afafb12663 Implement choosing TLS/plaintext for server 2024-05-14 09:11:22 +02:00
raul 51b0dd5258 Implement clientside TLS 2024-05-14 09:07:00 +02:00
raul 0f33d13d6a Implement serverside TLS 2024-05-14 09:06:45 +02:00
raul e3b681e904 Add gen-cert.sh 2024-05-14 09:06:24 +02:00
raul fde175401e Update .gitignore 2024-05-14 08:19:39 +02:00
raul cc3f4fbcd6 Update README.md 2024-05-13 13:08:37 +02:00
raul e0f9c63a54 Reduce latency time for synchronization 2024-05-13 13:04:45 +02:00
raul 940d1287ec Stop showing errors on client Ctrl+C 2024-05-13 12:04:20 +02:00
raul 015e1bb65f Handle passwords clientside 2024-05-13 12:02:32 +02:00
raul 99923c64b1 Handle passwords serverside 2024-05-13 12:02:21 +02:00
raul 8cb40303dc Add password parameter 2024-05-13 12:02:03 +02:00
raul a615cb9194 Fix windows version being unable to take input 2024-05-10 09:50:26 +02:00
raul b6e133c608 Clean up Cobra files 2024-05-10 07:58:12 +02:00
raul 2571936a48 Add shorthand parameters 2024-05-08 08:34:07 +02:00
raul 61e35fd758 Update README.md 2024-05-08 08:07:38 +02:00
raul bc8c852e4b Merge pull request 'Quality of Life update' from testing into main
Reviewed-on: #4
2024-05-08 08:04:44 +02:00
raul d821979b65 Only trigger CI/CD on PR
Go audit / audit (pull_request) Successful in 1m39s Details
2024-05-08 08:01:19 +02:00
raul cc96783a6c Update README.md
Go audit / audit (pull_request) Successful in 1m41s Details
2024-05-07 11:00:42 +02:00
raul 2ec372ad42 Add demo.gif 2024-05-07 10:48:54 +02:00
raul 158bf9373f Add history parameter to restore old chats 2024-05-07 10:48:16 +02:00
raul 9e1affdc6c Occupy rest of terminal space
After realizing what I'd have to go through to build a functional "Users
online:" view, I have decided to NOT do that, especially because this
entire thing still runs on raw TCP messages for commmunication and
trying to tell apart regular messages from join/disconnect messages in
the client to properly update the possible new view would be hell.
2024-05-07 09:49:34 +02:00
raul 370f217208 Add auto-scroll control 2024-05-06 14:09:47 +02:00
raul bcaa1c12af Add credits and current username to UI 2024-05-06 13:45:06 +02:00
raul f8332d102a Disable "Send it" button 2024-05-06 13:34:29 +02:00
raul c63028dea0 Add client TUI scrolling 2024-05-06 13:31:44 +02:00
raul 7eb991a4e4 Tweak chat dimensions 2024-04-27 21:46:00 +02:00
raul 3c79ebfbb4 Update README.md
Go audit / audit (push) Successful in 1m35s Details
2024-04-26 09:37:46 +02:00
raul 125502bab3 Merge pull request 'Refactored codebase' from testing into main
Go audit / audit (push) Successful in 1m37s Details
Reviewed-on: #2
2024-04-26 08:56:36 +02:00
raul 80da12cfcf Nuclear refactoring
Go audit / audit (pull_request) Successful in 1m48s Details
I've finally managed to properly rebuild the project, it's not extremely
clean, but compared to before, it's infinitely more functional and
expandable.
2024-04-26 08:48:48 +02:00
raul 3759701e22 Update README.md
Go audit / audit (push) Successful in 1m6s Details
2024-04-14 10:13:22 +02:00
raul 2a3bd788f8 Merge pull request 'Final PR' from testing into main
Go audit / audit (push) Successful in 1m7s Details
Reviewed-on: #1
2024-04-14 10:04:59 +02:00
raul cec33907b7 Removed currentUsers view
Go audit / audit (pull_request) Successful in 1m14s Details
I cannot handle this codebase anymore
2024-04-14 09:48:21 +02:00
raul c85fa5b031 Fixed catastrophic memory leak in client
Whenever a server would be stopped while the clients were connected to
it, the for loop handling the messages received by the server would
start a feedback loop as no more data could be read from "conn", thus
spawning an infinite number of byte arrays and crashing my laptop
2024-04-14 09:27:17 +02:00
raul ca10bc4284 Implement Gocui UI into mini-chat client 2024-04-13 13:11:36 +02:00
raul 75dac0ccef Attempt to clean up server codebase 2024-04-13 13:08:43 +02:00
raul 678244d289 Update dependencies 2024-04-13 13:08:02 +02:00
raul c4fb5606f6 Testing sending messages to server from client 2024-04-12 12:00:08 +02:00