Skip to content

Offline transaction verifier for Safe multisig wallets with ERC-7730 clear signing support

Notifications You must be signed in to change notification settings

Th0rgal/SafeLens

Repository files navigation

SafeLens

SafeLens

Offline transaction verifier for Safe multisig wallets with ERC-7730 clear signing.

Generator · Desktop App · CLI

SafeLens verifying a CoW TWAP order with clear signing

What it does

SafeLens generates and verifies evidence packages for Gnosis Safe multisig transactions. Paste a Safe transaction URL into the generator, download the evidence.json, then verify signatures and hashes offline using the desktop app or CLI.

  • Generate an evidence.json package from any Safe transaction URL
  • Verify signatures, hashes, and decoded calldata locally with zero network access
  • Clear signing via built-in and ERC-7730 interpreters for human-readable transaction details

Trust model

The desktop verifier ships with connect-src 'none' CSP and no shell-open capability, it cannot make network requests during verification. All crypto runs locally using bundled libraries. See TRUST_ASSUMPTIONS.md for the full model.

Quick start

Generate an evidence package at safelens.lfg.rs, or via CLI:

bun --cwd packages/cli dev analyze "https://app.safe.global/transactions/tx?..." --out evidence.json

Verify offline:

bun --cwd packages/cli dev verify --file evidence.json

Screenshots

Desktop App

Transaction Details

Transaction details with decoded calls

ERC-7730 Clear Signing Interpreters

ERC-7730 clear signing interpreter management
CLI

Transaction Interpretation

CLI transaction interpretation with clear signing

Verification

CLI verification output with signatures and warnings
Generator

Evidence Package

Generator web app with evidence package ready to download

Development

Project structure, setup, and build instructions

Structure

Path Description
apps/generator Next.js webapp, creates and exports evidence.json
apps/desktop Tauri + Vite desktop app, verifies evidence offline
packages/core Shared validation, hashing, signature verification, warnings
packages/cli CLI wrapper over core logic

Setup

Requires Bun.

bun install

Run

bun run dev          # generator at localhost:3000
bun run dev:tauri    # desktop app (full Tauri shell)
bun run dev:desktop  # desktop frontend only (no Tauri)

Build

bun run build        # generator + desktop frontend assets
bun run build:tauri  # full desktop distributable

Settings

Settings are JSON (address book and contract registry).

  • CLI: ~/.safelens/settings.json
  • Desktop: app data folder
bun --cwd packages/cli dev settings init   # initialize settings
bun --cwd packages/cli dev sources         # show verification sources

Cleanup

rm -rf apps/generator/.next apps/desktop/src-tauri/target apps/desktop/src-tauri/.tauri apps/desktop/src-tauri/Cargo.lock .opencode