frontend: app: Add scriptjs permission to az-auth plugin#755
Open
sniok wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds support for the new az-auth (Azure Authentication) plugin across the frontend plugin loader and Electron runtime so it can execute a bundled azure-api.js script via scriptjs with the appropriate permission secret and pre-consented command entry (per the needs of #754).
Changes:
- Register
az-authin plugin package/path identification so it can be recognized at runtime. - Plumb a dedicated
runCmd-scriptjs-az-auth/azure-api.jspermission secret to theaz-authplugin and expose a restrictedpluginRunCommand('scriptjs', ...)for it. - Allow Electron to treat
az-authas a valid plugin/bin folder and add startup pre-consent for itsscriptjscommand.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| frontend/src/plugin/runPlugin.ts | Adds az-auth to the identifyPackages mappings (paths + package names). |
| frontend/src/plugin/index.ts | Grants az-auth access to the scriptjs permission secret and injects a scriptjs-only pluginRunCommand. |
| app/electron/runCmd.ts | Adds az-auth command consent entry and a new scriptjs permission secret for azure-api.js. |
| app/electron/plugin-management.ts | Allows az-auth as a valid plugin bin folder. |
| app/electron/main.ts | Pre-seeds run-command consent for az-auth at app startup. |
sniok
marked this pull request as draft
July 10, 2026 18:53
sniok
force-pushed
the
hl-az-auth
branch
2 times, most recently
from
July 13, 2026 15:39
c13717d to
ad9922b
Compare
sniok
marked this pull request as ready for review
July 13, 2026 16:17
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.
Comments suppressed due to low confidence (1)
frontend/src/plugin/runPlugin.test.ts:692
identifyPackageswas extended to recognize theaz-authpackage, but the test suite only asserts thataz-authisfalsein other scenarios. Adding at least one positive test (path + name match) would prevent regressions in the new mapping.
// Tests for aks-desktop package
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.
Required for #754
Gives permission to the Azure Auth plugin to execute
azure-api.jsscript for authentication