Owner directive (2026-11-11): submit a single project to the NEAR Hackathon instead of two separate entries from the same person. Vendors Ration's NEAR audit-anchor work (github.com/caelum0x/ration, commit cff0ed3 + follow-ups) into ration-anchor/ as a first-class component: - contracts-near/audit_anchor (NEAR Rust contract, 5/5 cargo tests green, target/ deleted) - signer/ — a new, self-contained Go module (no dependency on Ration's other services or go.work) with the hand-rolled NEAR transaction signer + JSON-RPC client (cross-checked byte-for-byte against near-api-js) and the hash-chained audit ledger it anchors; 15/15 Go tests green (go test ./... -race) - docs/ and media/ — Ration's original pitch deck, demo recordings, and submission checklist Re-verified live via raw NEAR Testnet JSON-RPC this pass: ration-anchor-286ca315f1.testnet still deployed and queryable, the deliberate replay-rejection transaction still fails with nearcore's own "sequence must strictly advance" panic — no redeploy needed. Provenance notes added throughout (package doc comments, lib.rs header, README) crediting the origin repo. README.md and HACKATHON.md rewritten to tell one story: Cred402's SpendGuard enforces the protocol-level spending limit, the vendored Audit Anchor proves the tamper-evident spend history, both independently verifiable on NEAR Testnet. No mainnet claims anywhere (see prior overclaim fix 524f2dd). cred402's own build (npm run typecheck) and existing tests are untouched. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
20 lines
1.1 KiB
Go
20 lines
1.1 KiB
Go
// Package nearanchor originates from Ration (github.com/caelum0x/ration,
|
|
// commit cff0ed3, "feat(near-hackathon): anchor audit-log's hash-chain
|
|
// tip to NEAR Testnet"), where it was developed as a hand-rolled NEAR
|
|
// Protocol transaction signer and JSON-RPC client — no external NEAR
|
|
// SDK, no maintained Go NEAR SDK exists at all. It is vendored here,
|
|
// import-path-adjusted only, as Ration audit anchor, now part of
|
|
// Cred402: cred402's own SpendGuard spending-limit contract
|
|
// (../../contracts-near/spend_guard) enforces how much an agent may
|
|
// spend; this package anchors the hash-chained journal of *why* each
|
|
// spend happened to NEAR Testnet, so a counterparty can verify both the
|
|
// limit and the history on one chain. See ../README.md for the full
|
|
// provenance note and ../docs/RATION-HACKATHON.md for Ration's original
|
|
// judge-facing write-up.
|
|
//
|
|
// Every encoding/signing routine in this package is cross-checked
|
|
// against the real, official near-api-js reference implementation —
|
|
// see transaction_test.go and keys_test.go for the exact reference
|
|
// vectors and how they were generated.
|
|
package nearanchor
|