OpenGhostVault
The commit and reveal orchestrator for the Open Protocol. Functions similarly to CommitRevealVault but for public data commitments.
Address: 0x45B022fEB169AF906CaBa8086c977AA7b15faAf1
Key differences from CommitRevealVault
| Feature | CommitRevealVault | OpenGhostVault |
|---|---|---|
| Privacy | Unlinkable commits and reveals | Public reveals |
| Token operations | Burns and mints tokens | Data commitments (no token movement) |
| Merkle tree | CommitmentTree | OpenCommitmentTree |
| Nullifier registry | NullifierRegistry | OpenNullifierRegistry |
| Root updater | ghost-root-updater | open-ghost-root-updater |
Usage
The OpenGhostVault is used for data commitments where the data itself will be revealed publicly. The Merkle tree provides:
- Ordering — commitments have a verifiable insertion order
- Integrity — the root proves the complete set of commitments
- Existence proofs — prove a specific commitment exists without revealing all data
Example: query the open tree
# Get current root of the open commitment tree
cast call 0xE2b33dB178d6201EDd854ED9163B30dcfECC0c48 \
"getLastRoot()(bytes32)" \
--rpc-url https://testnet.specterchain.com
# Get number of open commitments
cast call 0xE2b33dB178d6201EDd854ED9163B30dcfECC0c48 \
"nextIndex()(uint256)" \
--rpc-url https://testnet.specterchain.com