Skip to content

feat: Attested Signatures + UCAN Principal Clarification#1

Merged
Peeja merged 2 commits into
mainfrom
claude/ucantone-pr-rollout-hdbgac
Jul 2, 2026
Merged

feat: Attested Signatures + UCAN Principal Clarification#1
Peeja merged 2 commits into
mainfrom
claude/ucantone-pr-rollout-hdbgac

Conversation

@Peeja

@Peeja Peeja commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Picks up the coordinated "Attested Signatures + UCAN Principal Clarification" rollout, which merged in ucantone and the sibling repos but never got a PR here.

Dependency bumps

  • github.com/fil-forge/ucantonev0.0.0-20260702175651-12732483947f
  • github.com/fil-forge/libforgev0.0.0-20260701162346-f0706e1641a3

Code adaptation (main.go)

Under PR #30 a ucan.Signer is no longer a Principal (no .DID()); the "signer bound to a Principal" role is now ucan.Issuer, and the key packages moved from ucantone/principal/* to ucantone/multikey/*. generateSigner now returns a ucan.Issuer built via each multikey package's GenerateIssuer() helper (the pattern used across the migrated siblings — e.g. guppy's cmd/space/generate.go):

func generateSigner(name string) (ucan.Issuer, error) {
	switch name {
	case "mldsa44":
		return mldsa44.GenerateIssuer()
	case "secp256k1":
		return secp256k1.GenerateIssuer()
	}
	return ed25519.GenerateIssuer()
}

All call sites are unchanged — .DID() and passing the value as the ucan.Issuer first arg to contentcmds.Retrieve.Delegate(...) / .Invoke(...).

mldsa44 (post-quantum ML-DSA-44) is retained

ML-DSA-44 was never on ucantone main — it lived only in the unmerged PR #32 (old principal/mldsa44 layout), which is the exact ucantone commit this repo had originally pinned. Rather than drop it, it has been re-ported onto the new multikey layout in fil-forge/ucantone#37, and this PR keeps the mldsa44 branch using the new multikey/mldsa44 package.

⚠️ Pinning note: ucantone#37 is not yet merged, so this pins ucantone at that PR's unmerged commit (12732483947f) — the same kind of unmerged-commit pin this repo used before, just pointing at the new branch instead of the old one. Re-pin to a merged ucantone once #37 lands.

Verified: GOWORK=off go build ./... && go vet ./... clean; go run . emits the X-UCAN-Container blocks without panicking for both the default ed25519 path (769 B container) and the mldsa44 path (~11 kB container, consistent with ML-DSA's large signatures).

Opened as a draft for review.

🤖 Generated with Claude Code

https://claude.ai/code/session_014dZyvL474aA43c1C7E6ZpV

claude added 2 commits July 2, 2026 15:20
Adapt to the ucantone PR #30 principal/signing refactor. A ucan.Signer is
no longer a Principal and has no DID; the "signer bound to a Principal" role
is now ucan.Issuer. The principal/* key packages moved to multikey/*.

generateSigner now returns a ucan.Issuer built via each multikey package's
GenerateIssuer helper (ed25519.GenerateIssuer / secp256k1.GenerateIssuer),
so callers can still .DID() it and pass it to .Delegate/.Invoke. The mldsa44
branch is dropped because that key type is no longer provided by ucantone.

Bumps ucantone and libforge to the refactored versions.

See fil-forge/ucantone#30

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014dZyvL474aA43c1C7E6ZpV
The earlier attested-signatures migration had to drop the mldsa44 (post-quantum
ML-DSA-44) key branch because that key type did not exist on ucantone main after
the principal/* -> multikey/* refactor. It has now been reinstated on the new
layout in fil-forge/ucantone#37, so this restores the mldsa44 case using
multikey/mldsa44.GenerateIssuer() and re-pins ucantone at that commit.

Because ucantone#37 is not yet merged, this points at that unmerged commit (the
new multikey/mldsa44 branch) rather than the old unmerged principal/mldsa44
commit it referenced before. Re-pin to a merged ucantone once #37 lands.

See fil-forge/ucantone#30

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014dZyvL474aA43c1C7E6ZpV
@Peeja
Peeja marked this pull request as ready for review July 2, 2026 19:59
@Peeja
Peeja merged commit 47f38de into main Jul 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants