Skip to content

dsl: resolve self to the local imid in debug endorse input - #159

Merged
ejj merged 1 commit into
NetSys:mainfrom
ejj:pr-self
Jun 13, 2026
Merged

ejj merged 1 commit into
NetSys:mainfrom
ejj:pr-self

Conversation

@ejj

@ejj ejj commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

This commit introduces a self alias in the DSL ident parser. parse_endorsements and parse_constraint now take a self_imid, and bare self resolves to it anywhere an imid is accepted (endorser, target, authz source/dest, nested constraints). Positions that do not accept imids — claim values, names — continue to reject self. The CLI fetches its own imid from admin_client.debug_dump() and threads it through; the e2e self-endorsement loop now uses self endorses self, exercising the alias end to end.

This commit instead introduces a `self` alias in the DSL ident parser.
`parse_endorsements` and `parse_constraint` now take a `self_imid`, and
bare `self` resolves to it anywhere an imid is accepted (endorser,
target, authz source/dest, nested constraints). Positions that do not
accept imids — claim values, names — continue to reject `self`. The CLI
fetches its own imid from `admin_client.debug_dump()` and threads it
through; the e2e self-endorsement loop now uses `self endorses self`,
exercising the alias end to end.

@patricklyc patricklyc left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@ejj
ejj merged commit ff905e9 into NetSys:main Jun 13, 2026
1 check passed
@ejj
ejj deleted the pr-self branch June 13, 2026 02:18
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.

2 participants