Hi,
I am not sure if this was mentionned before but I did a quick search and couldn't find anything on it.
I was looking for a way to encrypt the text being sent and received between chats.
Since I liked the idea of what you see on screen private between the participants and not having to worry about sniffing on the network, I was looking for a way to implement this.
I basically played with the source code a bit and with help of added functions I was able to come up with a temp solution which seems to work.
It doesn't encrypt everything but the chat itself seems secure enough.
What it is basically doing is this:
- When you type in the text input, the client encrypts the data using javascript with a cypher key, converts it to hex and base 64 encode it, then sends the msg to the server.
- The server decodes it, converts the hex and then decrypts it using the same cypher key.
- It does what it does to the msg like convert urls etc.
- It re-encrypts the msg and sends it back.
- The clients read the new msg and decrypt it using javascript on screen.
If i look at the chat logs, everything that is said between participants is encrypted therefore not readable.
For me this solution works, but im thinking that it would be a great feature to add to this project for anyone who would prefer to have their chat private.
What do you guys think?