Skip to content

[Sync] migrate octobot_sync to Starfish 3.0.0a18 cap-cert auth#3480

Open
Herklos wants to merge 1 commit into
devfrom
feature/bump-starfish
Open

[Sync] migrate octobot_sync to Starfish 3.0.0a18 cap-cert auth#3480
Herklos wants to merge 1 commit into
devfrom
feature/bump-starfish

Conversation

@Herklos
Copy link
Copy Markdown
Contributor

@Herklos Herklos commented Jun 1, 2026

Replace the custom EIP-191 wallet auth with Starfish v3 capability certificates. The EVM wallet derives a stable Ed25519/X25519 Starfish identity via the new derive_root_identity_from_evm_signature (a18, challenge "octobot:sync-bootstrap"); the client signs every request with a self-minted device cap and the server authenticates with create_cap_cert_role_resolver + identities_server_plugin.

  • client: WalletCapProvider (cap_provider=); create_sync_client returns (client, user_id); drop sign_data; share encryption via crypto.SecretEncryptor.
  • server: cap-cert resolver (max_body_bytes raised to 10MB so per-collection limits govern); storage identity is now the Starfish user_id; the bridge resolves the local wallet by re-deriving each wallet's user_id; userId-keyed allowlist; server-held encryption secret removed. EIP-191 modules removed (canonical/nonce/storage/role_resolver); SignedPathMiddleware normalizes the mounted /sync path so cap-signed paths match regardless of mount.
  • deps: pin starfish-sdk/server/identities/protocol/keyring ==3.0.0a18 (pre-releases must be pinned explicitly or pip resolves the latest stable).
  • temporary: append-only by_timestamp "user-signals" collection (to be removed).

@Herklos Herklos self-assigned this Jun 1, 2026
@Herklos Herklos requested a review from GuillaumeDSM as a code owner June 1, 2026 04:27
Replace the custom EIP-191 wallet auth with Starfish v3 capability
certificates. The EVM wallet derives a stable Ed25519/X25519 Starfish
identity via the new derive_root_identity_from_evm_signature (a18,
challenge "octobot:sync-bootstrap"); the client signs every request with a
self-minted device cap and the server authenticates with
create_cap_cert_role_resolver + identities_server_plugin.

- client: WalletCapProvider (cap_provider=); create_sync_client returns
  (client, user_id); drop sign_data; share encryption via crypto.SecretEncryptor.
- server: cap-cert resolver (max_body_bytes raised to 10MB so per-collection
  limits govern); storage identity is now the Starfish user_id; the bridge
  resolves the local wallet by re-deriving each wallet's user_id; userId-keyed
  allowlist; server-held encryption secret removed. EIP-191 modules removed
  (canonical/nonce/storage/role_resolver); SignedPathMiddleware normalizes the
  mounted /sync path so cap-signed paths match regardless of mount.
- deps: pin starfish-sdk/server/identities/protocol/keyring ==3.0.0a18
  (pre-releases must be pinned explicitly or pip resolves the latest stable).
- temporary: product-scoped append-only by_timestamp "product-signals"
  collection (products/{product_id}/{version}/signals, authorized via the root
  device cap; to be removed).

Verified: packages/sync tests green (165 passed, 1 S3-gated skip) incl. a real
cap-signed round-trip through create_app with a >64KB body and the product-scoped
append-only collection. NOT exercised in this minimal env (compile-checked,
mechanical edits): octobot/community/{authentication,errors_upload/error_sharing}.py,
the flow trading_signals_repository, and the node_api_interface allowlist lambda.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Herklos Herklos force-pushed the feature/bump-starfish branch from c6a6436 to 7f817e7 Compare June 1, 2026 04:34
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.

1 participant