project screenshot 1
project screenshot 2
project screenshot 3

GhostNFTs

GhostNFTs - Enabling multichain NFTs - Typically for services like ENS, PFP or Token Gating

GhostNFTs

Created At

Superhack

Project Description

This description is available here as PDF


marp: true theme: default backgroundColor: #fff paginate: true footer: "Ghost NFTs - ETHGlobal SuperHack 2023"

ETHGlobal SuperHack 2023

Ghost NFTs

Enabling multichain NFTs


Summary

1- Solo / Team 2 - Vision 3 - Ghost NFTs 4 - SmartContract 5 - Future 6 - Contact


Solo / Team

  • Zapaz :
    • co-founder and lead dev @Kredeum
    • ETHGlobal finalist early 2021 with Best AAVE FlashLoan Project
    • currently Formal Verification Audits contests with Certora for AAVE, GMX
  • Kredeum :
    • team of 5 Web2 entrepreneurs passionate about Web3
    • Kredeum NFT Factory : existing Open Source platform with multichain NFTs (BUT only for Soulbound NFT)
    • Grants via GitCoin, Polygon, Swarm and The Graph

Vision

NFTs should be multichain: you own an NFT on one chain, you should be able to own it on any other chains.

Typically for services like ENS, PFP or Token Gating

But exchanging these multichain NFTs is challenging! After a transfer, how to ensure same owner on every chain ?


Ghost NFTs - Registry

GhostNFTs is a registery of NFTs (quite similar to ERC6551 registry), available on any chain at a deterministic address.

It registers Ghost NFTs: a lite copy of the original NFT with Ghost Data that includes owner, tokenURI and the timestamp of the snapshot.

With Ghost Data, most of NFT service like ENS, PFP or Token Gating can be use on any other chain


Ghost NFTs - Syncing

Ghost NFTs are synced threw different networks with the help of inter-blockchain messages, containing Ghost Data, with service like: LayerZero, Hyperlane or CCIP

For simplicity, only one type of message is exchanged between GhostRegistry of different chains : the ghostSync message that only includes this Ghost Data :

    struct GhostData {
        uint256 ghostId;
        uint256 chainId;
        address collection;
        uint256 tokenId;
        address owner;
        string uri;
        uint256 timestamp;
    }

Ghost NFTs - Basic rules

To ensure coherent syncing of ownership and metadata over chains, 3 basic rules are defined for a GhostRegistry receving a ghostSync message:

1/ when received by the original chain of the NFT: Ghost Data is updated with current onchain NFT data: owher, tokenURI and timestamp, then replied back to sender

2/ when received on another chain

2.1/ and received timestamp is less recent than registered one, nothing is updated localy, but more recent local Ghost Data is sent back to sender

2.2/ and received timestamp is more recent than registered one, Ghost Data received is registered, with no reply to sender


SmartContract

  • A reference smartcontract implementation in solidity is available here : GhostNFTs.sol

  • Local demo via foundry tests can be run on GhostNFTs repo.

  • Inter-chain communication with LayerZero is still under devlopment


Future 1/2

  • Continue testing and development multichain
  • Implement ENS specific feature (as ENS is not an ERC721 metadata collection)
  • Full implemention with at least one communication layer
  • Propose Ghost NFTs as an EIP
  • GhostNFTs could be combined with ERC6551 registry...
  • enhance multichain transfer

Future 2/2

  • propose UI requirement : Ghost NFT could be forced to be « grey », with no color
  • Implement in Kredeum Factory
  • develop transferEverywere function inside ERC6551 Bound Accounts
  • Implement specific feature to any specific NFT collection

Contact

Ξ zapaz.eth @ [email protected] X @papaz

How it's Made

Ghost NFTs (1/3)

GhostNFTs is a registery of NFTs with these properties :

  • GhostNFTs is an ERC721 Metadata NFT collection
  • one GhostNFTs singleton may exists on each evm chain with same deterministic address
  • ghost NFT can be registered on same or another evm chain than original NFT
  • ghost NFT owner is synced to NFT owner AT a specific timestamp of original chain
  • ghost NFT tokenId (also named ghostId) is a hash of chainId, collection address and tokenId of original NFT

Ghost NFTs (2/3)

  • when original NFT collection is ERC721Metadata : ghost NFT tokenURI is original NFT tokenURI
  • GhostNFTs communicates from any chain to the chain of the original NFT with the help of inter-blockchain communication service like: LayerZero, Hyperlane or Chainlink CCIP
  • GhostNFTs only communication function is ghostSync, that enable to propagate NFT metadata (or ghostData) threw chains
  • ghostData is only synced / updated when timespamp is bigger thant last one
  • Only orginal NFT chain can update ghostData timestamp, with online NFT data and snapshot timestamp

Ghost NFTs (3/3)

  • GhostData have fixed fields : chainId, collection address, tokenId and ghostId (a combination of 3 previous ones)
  • GhostData, for this first version, has 3 snapshops data fields : owner, uri and timestamp (i.e. last timestamp of the snapshot data on the original chain)
background image mobile

Join the mailing list

Get the latest news and updates