Repository navigation
canton-rs v0.8.1
canton-rs v0.8.1
Summary:
v0.8.1is a DX and patch release that makes zero-config LocalNet boot work out of the box in any empty directory afterbrew installorinstall.sh, adds loopback-safe--dev-authauto-signing across management CLIs, and fixes built-insmoke-createscenario discovery.
🔒 Security & Integrity
- Loopback-Only
--dev-authAuto-Signing:daemon snapshot,daemon contracts,daemon tx, anddaemon scenarioautomatically sign short-lived (60-second TTL) HS256 JWTs from the local instance'sdev-jwt.keywhen targeting loopback addresses (127.0.0.1/localhost) with no explicit token configured. Auto-signing is strictly disabled for non-loopback--urltargets. - Explicit
--token-env/--token-fileAuth Override: Added consistent--token-env <VAR>and--token-file <PATH>flags todaemon snapshot,daemon contracts,daemon tx, anddaemon scenarioso caller-supplied bearer tokens always take precedence over local dev auto-signing. - Offline Embedded Sample DAR: The starter sample DAR (
sample-contract.dar) is embedded directly inside the checksum-verifiedcanton-rsbinary, eliminating unverified remote binary downloads and working fully offline. - Mid-Boot Failure Rollback: When a node fails before reaching readiness during
daemon up, previously started nodes (sequencer1,mediator1) are automatically stopped so failed launches do not leave orphaned background processes.
✨ New Features
- Zero-DAR Default Cluster Boot:
canton-rs daemon initnow emitsdars: []by default, enablingdaemon init→daemon doctor→daemon upto succeed in any empty directory outside the source repository. Participants start with an empty package store and accept dynamic DAR uploads via Ledger API v2 (POST /v2/packages) orcanton-rs dpm packages.canton-rs daemon init -o canton-daemon.yaml canton-rs daemon doctor -f canton-daemon.yaml --name dev canton-rs daemon up -f canton-daemon.yaml -d --name dev
- Offline Sample Contract Bootstrapping (
--with-sample-dar): Pass--with-sample-dartocanton-rs daemon initto extract the embeddedsample-contract.dar(AssetHolding:AssetHolding) next tocanton-daemon.yamland wire it intodars:for immediate contract creation and smoke testing.canton-rs daemon init -o canton-daemon.yaml --with-sample-dar canton-rs daemon up -f canton-daemon.yaml -d --name dev --dev-auth canton-rs daemon scenario run smoke-create --name dev
- Named Instance Support on
daemon scenario: Added--nametocanton-rs daemon scenario listandcanton-rs daemon scenario runso registered supervisor instances can be targeted by name without passing--state-dir.
🛠️ Fixes & Improvements
- Live Template Discovery in
daemon scenario run smoke-create: Fixed step 2 (submit_create) template resolution by inspecting liveGET /v2/packagesresponses on the running participant. Works with or without--dev-auth, matchesAssetHoldingand single-party creatable templates, and returns clear remediation diagnostics on zero-DAR stacks. - Normalized Relative Path Display: Removed duplicated
././prefixes from relative paths displayed bydaemon configanddaemon doctor. - Resilient
daemon remove --forceCleanup: Handled IPC EOF safely when force-removing partially failed or crashed instances instead of aborting removal. - CLI Documentation Alignment: Updated public
README.mdexamples to match exact CLI syntax (canton-rs daemon snapshot --name dev --out dev.tarandcanton-rs console attach --state-dir ...).
📦 Install & Upgrade
macOS & Linux (install.sh)
CANTON_RS_VERSION=v0.8.1 curl -fsSL https://getcantonrs.dev/install.sh | shHomebrew (macOS & Linux)
brew upgrade cantonrs/tap/canton-rsVerify Checksums
shasum -a 256 -c SHA256SUMS --ignore-missing
canton-rs --version
canton-rs localnet auditSupported Prebuilt Targets
| Target | Platform |
|---|---|
x86_64-unknown-linux-gnu |
Linux x86_64 (glibc 2.31+) |
aarch64-unknown-linux-gnu |
Linux ARM64 (glibc 2.31+) |
aarch64-apple-darwin |
macOS Apple Silicon |
x86_64-apple-darwin |
macOS Intel |
🧭 Upstream Compatibility & Scope
- Target Baseline: Independent Rust implementation oracle-tested against Canton
3.7.2(Protocol Versions36–37) · Daml-LF2.1–2.4(default2.3) · Splice0.10.1· PostgreSQL16 - Known Scope: Pre-1.0 preview intended for LocalNet development, CI testing, and read-only brownfield evaluation. Zero-side-effect transaction simulation (
canton-rs simulate) and parallel isolated script testing (canton-rs test) are scheduled for an upcomingv0.9.0release. MainNet/TestNet live state forking and automatic CC/USD fiat conversion are out of scope.
Full Changelog: v0.8.0...v0.8.1