TLDR;

  1. If you had a GitHub account with more than 15 followers in 2019 February
  2. A crypto team dropped you ~4200 HNS coins worth about $2000

full

Claim Free Handshake tokens

Launching a blockchain / cryptocurrency is usually done via an ICO (initial coin offering) to gain some market value and reward early stage investors.

The Handshake Protocol founders decided to screw that and they picked something else. The idea was to seed their initial community via "airdropping" a few thousand coins to open source developers as gifts. Brilliant move since these people are the target audience of the distributed DNS they were building.

In order to do this seeding, they decided to scrape GitHub in 2019 February and gave anyone with more than 15 followers ~4200 HNS coins. This is worth roughly $2000 USD as I write this.

Let me repeat. If you had more than 15 followers in 2019 February and you had a public SSH or GPG key associated with your account, you are likely to have the above deposit waiting for you to grab.

This tutorial will explain all the steps.

Digging deeper

Let's look at this project a little. It's worth taking some research before using your private SSH keys to sign a blockchain transaction. That might sound a bit dodgy, but this tutorial offers a way to do it with reasonable securely in an air-gapped environment.

The following steps will cover using the protocol's own libraries and solutions:

What you'll need:

The plan

right

  1. In order to pull this off we will try do it as securely as possible. That's where Docker comes into play, we will use it an a virtual air-gapped machine. You'll need to copy your private keys to the Docker image and generate a transaction that the blokchain can process later.

    • Alternatively, you can just delete your public key from GitHub, this way even with a leak, nobody would be able to do anything with it.
  2. I know, copying your private keys to a random docker image sounds phishy as hell, but read on and see for yourself that security is ensured. We will also turn off the network in the Docker container so it will be virtually air-gapped.

  3. Once we have the transaction generated, we will launch a local node for the Handshake network and submit the transaction to "airdrop" the deposited coins to your newly generated address on Gate.io

Sounds good? Let's set everything up

STEP 1: Create a HNS wallet to transfer your coins to

  1. Create an account on Gate.io: https://www.gate.io/5158591

    1. The verification process is optional but you can't withdraw the funds as fiat currency otherwise
  2. Visit https://www.gate.io/myaccount/deposit/HNS

  3. Copy the deposit address starting with hs1 and save it somewhere. <YOUR_WALLET_ADDRESS> from now on.

STEP 2: Signing and creating a transaction

Create an airgapped Docker container to run things on (instructions adapted from this GH issue):

First, create this Dockerfile in an empty directory:

FROM node

RUN git clone https://github.com/handshake-org/hs-airdrop.git /hs-airdrop
WORKDIR /hs-airdrop
RUN yarn

RUN git clone --depth 1 https://github.com/handshake-org/hs-tree-data.git /root/.hs-tree-data

In that directory, run the following commands:

# Copy your private SSH keys:
mkdir keys
cp ~/.ssh/id_rsa ~/.ssh/id_rsa.pub keys

# Change the password on your SSH key if you had any (optinal, for added security)
ssh-keygen -p -f keys/id_rsa

Let's build a Docker container

docker build -t hs-airdrop .

Run the container without network connection

docker run --rm -it --network none --name no-net --volume=$(pwd)/keys:/ssh hs-airdrop bash

You are now running a non-networked container. Inside the container you can check there's no network connectivity:

# Should give an error - it's reassuring to know there's no internet
ping x.com

Let's find out if you have the right keys to recover the airdropped coins. Run the airdrop command:

./bin/hs-airdrop --bare /ssh/id_rsa <YOUR_WALLET_ADDRESS> 0.010

If successful, you should see the following:

full

Further down the console, get copy the long-ass base64 string. That's a transaction instruction for the blockchain to airdrop the coins to your account.

full

STEP 3: Broadcasting the transaction

On a networked enabled machine, you need to install the HSD daemon to broadcast the transaction on the network. You will need to keep two terminals open. One to run the daemon and one that connects to it and sends the transaction.

Mac

brew install hsd

# Terminal #1
hsd --log-level info

# Terminal #2
hsd-cli rpc sendrawairdrop <BASE64_STRING>

Linux or Windows

We will install manually the HSD client and run the above two commands with Node.js. The result is the same.

git clone https://github.com/handshake-org/hsd.git
cd hsd
npm i --production

# Terminal #1
node ./bin/hsd --log-level info

# Terminal #2
node ./bin/hsd-cli rpc sendrawairdrop <BASE64_STRING>

You should see a hex code response.

STEP 4: Keep checking the transaction status

Go to https://e.hnsfans.com/address/<YOUR_WALLET_ADDRESS>. It can take from 5 minutes to 20-30 minutes to see your transaction to appear, be patient.

After Confirmations reach at least 8 you are good to go.

You should see HNS balance in your account: https://www.gate.io/myaccount/deposit/HNS.

full

STEP 5: Profit!

Now it's up to you to sell those coins for USDT and withdraw them to your bank account or trade them to another crypto of just, you know, HODL: HNS might become big.