Skip to content

feat: Add Azure RBAC condition parser - #496

Merged
anakrish merged 2 commits into
microsoft:mainfrom
anakrish:azure-rbac-conditions
Nov 17, 2025
Merged

feat: Add Azure RBAC condition parser#496
anakrish merged 2 commits into
microsoft:mainfrom
anakrish:azure-rbac-conditions

Conversation

@anakrish

@anakrish anakrish commented Nov 5, 2025

Copy link
Copy Markdown
Collaborator
  • declare an azure-rbac feature and expose the Azure RBAC module with parser, AST, and YAML-driven tests
  • extend the shared lexer with RBAC-specific tokens, single-quoted strings, and corrected raw-string spans
  • verify the parser via comprehensive test cases covering every operator and complex chaining

Comment thread src/languages/azure_rbac/ast.rs Fixed
Comment thread src/languages/azure_rbac/parser.rs Fixed
@anakrish
anakrish force-pushed the azure-rbac-conditions branch from 0d4a69e to 99baa0f Compare November 5, 2025 21:36
@anakrish
anakrish marked this pull request as ready for review November 5, 2025 21:55
@anakrish
anakrish force-pushed the azure-rbac-conditions branch 2 times, most recently from 41bdc33 to 886e04b Compare November 15, 2025 00:27
- declare an `azure-rbac` feature and expose the Azure RBAC module with parser, AST, and YAML-driven tests
- extend the shared lexer with RBAC-specific tokens, single-quoted strings, and corrected raw-string spans
- verify the parser via comprehensive test cases covering every operator and complex chaining

Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
@anakrish
anakrish force-pushed the azure-rbac-conditions branch from 886e04b to 728d0f3 Compare November 15, 2025 00:29
Comment thread src/languages/azure_rbac/test_cases.yaml
Comment thread src/parser.rs Outdated
Comment thread src/languages/azure_rbac/tests.rs
dekomissMSFT
dekomissMSFT previously approved these changes Nov 15, 2025

@dekomissMSFT dekomissMSFT 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.

:shipit:

dpokluda
dpokluda previously approved these changes Nov 15, 2025

@dpokluda dpokluda left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

:shipit:

@anakrish
anakrish dismissed stale reviews from dpokluda and dekomissMSFT via 87cf1b2 November 15, 2025 01:39
@anakrish

Copy link
Copy Markdown
Collaborator Author

@dekomissMSFT, I have addressed your PR feedback.

@anakrish
anakrish force-pushed the azure-rbac-conditions branch from 87cf1b2 to 752522f Compare November 15, 2025 01:44
- Add more parse error tests
- Test rbac in github workflows
- Simplify rego parser's token text function to not need feature flags.

Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
@anakrish
anakrish force-pushed the azure-rbac-conditions branch from 752522f to d02c796 Compare November 17, 2025 15:15

@dpokluda dpokluda left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

:shipit:

@anakrish
anakrish merged commit ad8c543 into microsoft:main Nov 17, 2025
41 checks passed
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.

4 participants