Difference between revisions of "ICP staking with seed phrase and air-gapped computer"

From Internet Computer Wiki
Jump to: navigation, search
Line 52: Line 52:
 
</pre>
 
</pre>
  
====Bridge the air gap: Send the message to the Internet Computer using a QR code====
+
====Step 2b: Bridge the air gap: Send the message to the Internet Computer using a QR code====
  
 
Since your air-gapped computer is not connected to the internet, we will use a QR app to send the message generated in 4.2.1 to the Internet Computer. We will use IC Transaction Scanner which lives in a canister (and whose code is visible here: https://github.com/ninegua/ic-qr-scanner)
 
Since your air-gapped computer is not connected to the internet, we will use a QR app to send the message generated in 4.2.1 to the Internet Computer. We will use IC Transaction Scanner which lives in a canister (and whose code is visible here: https://github.com/ninegua/ic-qr-scanner)

Revision as of 22:54, 12 November 2021

Requirements

You can only stake with seed phrase and air-gapped computer if you are already doing ICP custody with seed phrase and air-gapped machine. This page assumes you are successfully doing self-custody of ICP as in that page.

This section assumes you successfully installed the QR tools on your air-gapped computer from ICP custody with seed phrase and air-gapped machine.

In this section, we need to “bridge the air gap.” This means that we will continue to perform the sensitive operations within the air-gapped computer, but we will use a networked smartphone’s QR code scanner to send the messages from the air-gapped computer to the Internet Computer.

bridging air gap

Terminology

To “stake ICP” and to “create a neuron” are the same activity so they are used interchangeably.

Basic steps

Summary of steps

  1. Send ICP to your ledger account number
  2. Create a neuron
  3. Set dissolve delay of neuron

Step 1: Send ICP to your ledger account number

This account number lives in the Ledger canister that maintains the ICP addresses for the entire network. This account number is analogous to “addresses” in other blockchains. You need to send the ICP you want to stake to the ledger account number. In the example case, the ledger account

77b5eb9a465f4ce6f4da494ee2bfedeefe0b52d106e0272556c1ad991f99e3da

so that is the address we will use.

To create a neuron, you need to stake a minimum of 1 ICP. Anything less will not create a neuron.

If you cannot send ICP to your ledger account number, do not continue. Try again, check out support, or submit a question to support.

Step 2: Create a neuron

Step 2a: Generate a signed message to “create a neuron” using quill

On the air-gapped computer:

/ This is just the structure, copy/pasting WILL NOT work. See below for working command
$ target/release/quill --pem-file private.pem neuron-stake --name $NAME --amount $AMOUNT

For this command, the $NAME is an arbitrary string, up to 8 characters, that you can use to identify your neuron for the purposes of topping up later with quill. For example, if you intend to have only one eight-year neuron, you could use the name 8yneuron. This string has no meaning otherwise, and will not be visible anywhere else. You can store the string on your air-gapped computer. It can in theory be recovered if lost but there is currently no tooling for recovery, so we recommend you also write the string down.

The $AMOUNT should not include the transaction fee, but remember that it will still be deducted from your account, so if you wish to stake everything you’ve got, stake your balance minus the 0.0001 ICP fee.

Here is the same command with the fields $NAME (“neuron3”) and $AMOUNT (1.01) filled out, but you should choose your own fields.

On the air-gapped computer:

// Create the message that tells IC "create the neuron" and save it in  "message.json"
$ target/release/quill --pem-file private.pem neuron-stake --name neuron3 --amount 1.01 > message.json

Step 2b: Bridge the air gap: Send the message to the Internet Computer using a QR code

Since your air-gapped computer is not connected to the internet, we will use a QR app to send the message generated in 4.2.1 to the Internet Computer. We will use IC Transaction Scanner which lives in a canister (and whose code is visible here: https://github.com/ninegua/ic-qr-scanner)

Step 3: Set dissolve delay of neuron

Related topics