Repository navigation
feat(evm): add identity registry, restricted bond and HTLC - #8
Merged
MukulKolpe merged 1 commit intoOct 26, 2026
Merged
Conversation
Signed-off-by: Mukul Kolpe <mukulkolpe45@gmail.com>
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
Adds the asset leg of Flow A as Solidity contracts for Sepolia: a hash-only identity registry, a restricted bond in the ERC-3643 placement, and a SHA-256 HTLC. Denials revert with
OTASDenied(code), so the OTAS reason code travels in the revert data.Type of change
live/evm)live/sui)live/runner)Related issues
Closes #7
Details
OTASIdentityRegistry: credential hashes and a revoked flag per claim topic.check()returns codes in a fixed order (paused, frozen, sender, receiver), which the Sui leg will mirror. Settlement escrows are registered as system accounts so they can hold restricted units.OTASBond: ERC-20-compatible, with Restricted, Freezable, ForceTransferable and AtomicLeg behaviours.otasCanTransferis the OTAS interface convention, not the ERC-3643 function of a similar name.returnFromEscrowlets an escrow return a sender's own units without an eligibility check, so a credential that lapses while units are in escrow can't strand them.OTASHTLC: SHA-256 hashlock, because Sui exposes the same function, so one preimage opens both legs. A leg locks only if delivery would be allowed now. Claiming is permissionless but delivers only to the receiver fixed at lock time, and re-checks that receiver's eligibility. Refunds go to the sender after the timelock.For schema and contract changes
OTASReasonsmirrorsreasons-v1.json)forge test)live/scripts/build-artifacts.shand committedChecklist
git commit -s)gitname/email match my sign-off and GitHub accountmain.keys/files or other secrets are includedNotes for reviewers