This app scans HaLo NFC chip. A HaLo is a "hardware locked" cryptographic asset such as a print, collectable or merchandise. HaLo chips can be scanned via NFC to authenticate the asset as well as make any claims for fungible or non-fungbile assets if available.
To test locally, you should first set up your environment variables by creating a .env
file including the following
REACT_APP_INFURA_PROJECT_ID
: the project ID from an active Infura API key.REACT_APP_BRIDGE_NODE
: the URL of a KONG bridge node that is used to create HaLo off-chain records (the default ishttps://bridge.cryptocash.dev
, no API key required).REACT_APP_ARWEAVE_NODE
: the URL of an Arweave node (the default ishttps://arweave.net
, no API key required).REACT_APP_TAG_DOMAIN
: the domain resolving to the HaLo scanner. The default iseth.vrfy.ch
, however, this will fail unless the tag is being scanned at this domain.
For local testing we recommend exposing the app (from localhost:3000
) using something like localtunnel.
Note: HaLo scanning functionality will only work through an HTTPS connection.
npm i
npm install -g localtunnel
lt --port 3000
- Edit the
REACT_APP_TAG_DOMAIN
variable in.env
to match the domain given by localtunnel, e.g.https://little-bobcat-81.loca.lt
npm start
- On your smartphone, navigate to the localtunnel domain
With the app loaded on your NFC-enabled smartphone, tap Initiate Scan
and hold the chip to your phone's NFC antenna. On iPhones the antenna is located at the top of the phone. On Androids location can vary significantly and some trial and error may be required.
If you have an unassociated HaLo chip, the app will allow you to "mint" an image, name and description to the chip. This feature is currently in alpha; it creates records on Arweave via the KONG bridge that are cross pinned on IPFS.
Minting does not require gas as no contract calls are made. The minting process is off-chain and generates a signature that could be used in a future contract to generate an on-chain asset (e.g. an NFT). It consists of the following steps:
- Connect to the wallet of the
minter
. - Scan the chip to collect identifying public key information (
device_id
). - Select an image (
media
), add aname
anddescription
. - Sign a recent block hash from the selected chain using the chip (default is Ethereum
mainnet
). - From the
minter
wallet, generate an EIP-712 signature of several parameters: including the pre-calculated IPFS hash of themedia
along with thename
,description
,device_id
, the signature generated by the device and block hash used to generate the signature and the address of theminter
wallet. POST
this data to the KONG bridge server which will add themedia
and tag it will the information from the previous step on Arweave.
Minting is a one time process per chain and is non-reversible.
If you have a previously associated HaLo chip, the app will retrieve any record information about the chip directly from Arweave. Loading content from Arweave may take a moment.
If you would like to first test mint with a chip, we recommend first connecting a wallet to a testnet (e.g. Ropsten), then refreshing the app and continuing through the minting flow. These records will only be revealed by a wallet connected to the testnet.
Note: You must have a HaLo chip in order to scan via this app. This app will not scan KONG Cash or SiLo chips.
- Allow assets to be created across various
chainId
's. - Show the
chainId
in a human-readable fashion, e.g.Ropsten
. - Render a spinner for assets that slowly load from Arweave.
- Add and render video content.
- Add and render 3D content.
- Link to existing Arweave/IPFS resource rather than upload.
- WebNFC for Androids.
- ERS verification and asset retrieval.