This repository demonstrates how the socket.io can be implemented with the client side encryption in a spiky fashion.
npm install
node index.js
Now you should able to go to the port and have a chat (with yourself, unless you host the chat server somewhere like Heroku). Only when the cipher key and decipher key matches you are able to view what the messages are.