Stellar: smart accounts and access control update#139
Conversation
✅ Deploy Preview for openzeppelin-docs-v2 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
Pull request overview
Updates the Stellar smart accounts documentation to reflect the new authorization model based on explicit context rule selection (context_rule_ids) and the new AuthPayload shape, plus related updates to policies and access control examples.
Changes:
- Replace “rule iteration / precedence” narrative with explicit rule lookup via
context_rule_idsacross multiple docs. - Update signer/verifier docs and examples to use
AuthPayload { signers, context_rule_ids }and describe off-chain encoding/digest considerations. - Refresh policy and access control documentation to match updated interfaces/behavior (panic-based enforcement, ID-based removal, updated helper signatures).
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| content/stellar-contracts/accounts/smart-account.mdx | Updates the high-level authorization flow summary to explicit rule lookup. |
| content/stellar-contracts/accounts/signers-and-verifiers.mdx | Introduces AuthPayload, updates Rust/TS examples, and adds off-chain client guidance. |
| content/stellar-contracts/accounts/policies.mdx | Updates the policy model to a single enforce() method that validates + mutates and panics on failure. |
| content/stellar-contracts/accounts/context-rules.mdx | Updates context rule semantics/limits and matching description for explicit rule selection. |
| content/stellar-contracts/accounts/authorization-flow.mdx | Updates the detailed flow and examples to the explicit rule ID model. |
| content/stellar-contracts/access/access-control.mdx | Updates access control example calls to revised helper signatures / argument ordering. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Agent-Logs-Url: https://github.com/OpenZeppelin/docs/sessions/1cbe0b8d-1816-4e44-b637-714b416168f1 Co-authored-by: brozorec <9572072+brozorec@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…count context rule limit Agent-Logs-Url: https://github.com/OpenZeppelin/docs/sessions/91349b50-f0e5-4db1-9cf8-d9eb2cb1fca1 Co-authored-by: brozorec <9572072+brozorec@users.noreply.github.com>
…x and rwa.mdx Agent-Logs-Url: https://github.com/OpenZeppelin/docs/sessions/8e710b20-eb02-4301-8f1e-caa29f43322e Co-authored-by: brozorec <9572072+brozorec@users.noreply.github.com>
|
Mermaid diagram generated on the root Also found similar problems in other mermaid diagrams throughout the |
|
Not exactly related to the changes in this PR, but would be also good to update this part from previous documentation:
I recall we had a through discussion about this. Context Rules, are not defining the action itself, but the scope. Here is how we changed it in
Would you agree updating the docs here as well with respect to this who, what, how sections? |
|
@ozgunozerk I agree with the above points, plz review |
|
There is this one left: Other than that, LGTM, approving |
Documentation Pull Request
Summary
Updates Stellar smart accounts documentation to reflect the new authorization model based on explicit context rule selection (
context_rule_ids) and the newAuthPayloadshape, plus related updates to policies and access control examples. Also clarifies and corrects code examples for consistency with the updated model across multiple pages.Type of Change
Related Issues
Relates to #
Checklist
pnpm run buildpnpm run checkAdditional Notes
signAndSendTxTypeScript example insigners-and-verifiers.mdxnow includesruleId: numberas an explicit function parameter (with a comment explaining it is obtained from context rule creation/lookup), resolving the previously undefined variable.__check_authexample insigners-and-verifiers.mdxrenames the parameter fromsignaturestoauth_payload(with matching usage update) to accurately reflect that it carries the fullAuthPayloadstruct, not just signatures.authorization-flow.mdx, as this limit no longer exists in the framework.grant_role_no_authcall signatures insac-admin-wrapper.mdxandrwa.mdxto use the correct argument order(env, account, role, granting_admin), matching the updated signature documented inaccess-control.mdx.