Sign inSign up

pantherprotocol/escrow-decryptor

By pantherprotocol

•Updated over 1 year ago

A secure CLI for decrypting data stored in the DataEscrow system of Panther Protocol

Image
0

746

pantherprotocol/escrow-decryptor repository overview

⁠DataEscrow CLI Decryption Tool

A secure and user-friendly command-line interface for decrypting data stored in the DataEscrow system of Panther Protocol.

⁠Overview

The DataEscrow CLI Decryption Tool provides decryption capabilities for three escrow types:

  • DAO Escrow
  • Zone Escrow
  • Safe Escrow

It offers robust security features, optimized performance, and a straightforward user experience.

⁠Key Features

  • Secure decryption for all escrow types
  • Transaction data parsing and validation
  • Ephemeral key management
  • HMAC verification
  • Comprehensive error handling and logging
  • Docker container for easy deployment

⁠Getting Started

⁠Basic Usage

For DAO Escrow:

bun run decrypt:escrow \
  --txHash=0x1234...abcd \
  --escrowType=dao \
  --escrowPrivateKey=0x1234...abcd \
  --network=polygon \
  --outputFile=out/dao.json

For Safe Escrow (requires ephemeral public key):

bun run decrypt:escrow \
  --txHash=0x1234...abcd \
  --escrowType=safe \
  --escrowPrivateKey=0x1234...abcd \
  --network=amoy \
  --outputFile=out/safe.json \
  --ephemeralPublicKeyX=123...789
⁠Command Options
  • --txHash: Transaction hash (required)
  • --escrowType: Type of escrow (dao | safe | zone)
  • --escrowPrivateKey: Private key for decryption
  • --network: Network to use (amoy | polygon)
  • --outputFile: Path for the decrypted output
  • --ephemeralPublicKeyX: Required for safe escrow type
⁠Decryption Process

The tool follows a secure decryption workflow:

  1. Parse and validate transaction data
  2. Extract escrow-specific encrypted messages
  3. Compute shared keys using ephemeral keys
  4. Verify HMAC for data integrity
  5. Decrypt messages and format output

⁠Detailed Usage Guide

⁠Transaction Types

Currently supported transaction types:

  • Main transaction
  • SwapZAsset transaction
⁠Escrow Types

Each escrow type has specific data handling:

  • DAO Escrow: Uses derived ephemeral keys
  • Zone Escrow: Uses derived ephemeral keys
  • Safe Escrow: Uses provided ephemeral public key

⁠Contributing

We welcome contributions! Please check our contribution guidelines⁠ before submitting issues or pull requests.

⁠License

BUSL-1.1 - See LICENSE⁠ for details.

⁠Support

Need help?

Tag summary

Content type

Image

Digest

sha256:3a3be8188…

Size

176.7 MB

Last updated

over 1 year ago

docker pull pantherprotocol/escrow-decryptor