feat(soroban): add application compliance contract (Predicate Registry)#60
Merged
alex-predicate merged 8 commits intomainfrom Apr 3, 2026
Merged
Conversation
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Implement Ed25519 signature verification over SHA-256 hashed statements with UUID replay protection in the Predicate Registry contract. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Adds a reusable rlib crate that wraps the PredicateRegistry cross-contract call behind an authorize_transaction() helper, mirroring the EVM PredicateClient mixin pattern. Also adds rlib output to predicate-registry so its types can be re-exported by the client crate. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
There was a problem hiding this comment.
Code review is billed via overage credits. To resume reviews, an organization admin can raise the monthly limit at claude.ai/admin-settings/claude-code.
Once credits are available, reopen this pull request to trigger a review.
…fe, TTLs, events, owner transfer - Add msg_value (i128) to Statement; change encoded_sig_and_args from BytesN<32> to Bytes - Add caller-bound hash verification (hashStatementSafe) to prevent cross-contract replay - Add TTL management (PERSISTENT_TTL_THRESHOLD/EXTEND ~30d) for all persistent storage writes - Suppress deprecated events().publish() warnings with #[allow(deprecated)] + TODO for contractevent - Add transfer_ownership with owner-only guard - Add test_validate_invalid_signature (wrong-key signing detection) - Update predicate-client: new params (msg_value, Bytes, caller), improved doc comments Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… two-step ownership - Add caller.require_auth() in validate_attestation to prevent UUID burning - Move attester registration check before ed25519_verify for early short-circuit - Implement two-step ownership transfer (propose + accept) with events - Centralize TTL constants in types.rs - Use storage.remove() instead of set(false) on attester deregistration - Enrich validation event with attester and caller fields - Add predicate-client end-to-end integration test - Document attesters Vec scaling assumption (<50 entries) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
penDerGraft
reviewed
Apr 2, 2026
penDerGraft
approved these changes
Apr 3, 2026
Contributor
penDerGraft
left a comment
There was a problem hiding this comment.
I'm okay with this but admittedly don't have a super clear idea how it all works. The biggest takeaway for me is that we need to thoroughly test these contracts end-to-end and ensure they behave the same as their EVM counterparts.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
predicate-registrySoroban smart contract — the Stellar equivalent of the EVMPredicateRegistry.solfor application compliance (Track 2 of Stellar Support PRD)predicate-clienthelper library for downstream contracts to validate attestationsDetails
predicate-registrycontractrequire_auth()for owner-gated operationsset_policy_id/get_policy_idper client addresspredicate-clientlibraryStatement,Attestation,RegistryError)authorize_transaction()helper — mirrors EVMPredicateClient._authorizeTransaction()Key Stellar/Soroban adaptations from EVM
keccak256(abi.encode(...))sha256(xdr(...))block.chainidmsg.senderrequire_auth()Test plan
cargo test --workspace)predicate_registry.wasm(27KB)🤖 Generated with Claude Code