https://github.com/rumkin/cha-cha-chat
Example of ChaCha20 encrypted chat with ECDH key exchange
https://github.com/rumkin/cha-cha-chat
Last synced: 11 months ago
JSON representation
Example of ChaCha20 encrypted chat with ECDH key exchange
- Host: GitHub
- URL: https://github.com/rumkin/cha-cha-chat
- Owner: rumkin
- License: mit
- Created: 2017-07-17T00:26:55.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2018-02-13T10:30:15.000Z (over 8 years ago)
- Last Synced: 2025-01-30T03:26:28.433Z (over 1 year ago)
- Language: JavaScript
- Size: 4.88 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Chat with ChaCha20 encryption
This is a simple realtime only chat with end-to-end encryption. This repository
is just an example and should not be used as complete solution for information
security system without addintional server configuration. Also it doesn't protect
members from MITM attack without some security additions (you can use
SSL-certificate for it).
## Cryptography
This chat use ECDH (Diffie-Hellman) algorythm to safely exchange encryption keys
using central server. Chat uses ChaCha20 algorythm to encrypt message content.
ChaCha20 is [recommended by Google](https://tools.ietf.org/html/draft-ietf-tls-chacha20-poly1305-04) as TLS protocol.
## Example
Run server
```shell
node server.js
```
In another two terminals run clients. Client usage is:
`node client.js `:
```shell
# Client 1
node client.js my-secret-room-id "Hello client 2"
```
```shell
# Client 2
node client.js my-secret-room-id "Hello client 1"
```
After calling this both clients should be terminated.
## License
MIT.