Learn more by joining the Handshake Discord Community
applause is a platform I built using centralized web technologies in combination with decentralized identity blockchain. The result is a website that requires no login or signup of any kind, and instead, lets users participate by authenticating their actions against the key associated with their name on the Handshake blockchain.
You can see this live at https://applause.chat/.
I was browsing some of the Handshake related projects on Github and saw a recent pull request on Kyokan's Bob Wallet Extension. Highly interested, I downloaded and built the branch and started building this site.
There are several use cases:
- Authenticated paste bin
- Easy blogging
- Petition
- Transparent voting
- and more!
You can embed images by using the data-url with markdown image syntax.
A lot of Web3 projects are geared around making money. I'm more interested in decentralization and sovereign data ownership, so I'm exploring how we can use these technologies for better purposes.
- nodeJS + Express + Session + CSRF + moment
- mySQL
- Handshake
- Linux
- Clone
git clone https://github.com/publiusfederalist/applause
- Install npm packages
cd applause
npm install mysql csurf express express-session hs-client hsd moment
-
Setup and install mysql
-
Setup an 'applause' db and a mysql user with access to the 'applause' db and setup these tables:
CREATE TABLE POSTS (
id INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
user VARCHAR(253) NOT NULL,
message LONGTEXT NOT NULL,
signature VARCHAR(89) NOT NULL UNIQUE,
timestamp INT NOT NULL
);
CREATE TABLE APPLAUSE (
aid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
tid INT NOT NULL,
user VARCHAR(253) NOT NULL,
signature VARCHAR(89) NOT NULL UNIQUE,
timestamp INT NOT NULL
);
- Setup iptables forwards
#!/bin/sh
iptables -t nat -F
iptables -F
echo 1 | sudo tee /proc/sys/net/ipv4/ip_forward
iptables -t nat -I PREROUTING --src 0/0 --dst x.x.x.x -p tcp --dport 80 -j REDIRECT --to-ports 8080
iptables -t nat -I PREROUTING --src 0/0 --dst x.x.x.x -p tcp --dport 443 -j REDIRECT --to-ports 8443
-
Get let's encrypt certs and place in the ssl folder
-
Setup secrets files
db.secret
for the database password,hsd.key
for the hsd api, andsession.password
for the http session. -
Setup a fullnode Handshake daemon
-
Run
node server.js
MIT Licensed