feat: renderer IPC bridges + script security split + decouple scripting#10011
Closed
jackkav wants to merge 7 commits into
Closed
feat: renderer IPC bridges + script security split + decouple scripting#10011jackkav wants to merge 7 commits into
jackkav wants to merge 7 commits into
Conversation
✅ Circular References ReportGenerated at: 2026-06-02T18:53:44.931Z Summary
Click to view all circular references in PR (10)Click to view all circular references in base branch (10)Analysis✅ No Change: This PR does not introduce or remove any circular references. This report was generated automatically by comparing against the |
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
This PR bundles 5 related, self-contained improvements extracted from PR #9996 (disable nodeIntegration) and pr/safe-utilities-cleanup. Each commit applies exactly one architectural technique to move Node-dependent logic out of the renderer or to improve module boundaries.
Changes
1. Script Security Split (commit: a015f4a)
script-security-rules.ts— pure-data constants/types with zero Node importsscript-security-policy.ts, keeping onlyrequireInterceptor-dependent logic2. Testing IPC Adapter (commit: 4852f93)
insomnia-testing.renderer.tsas a new renderer-safe surfaceinsomnia-testing/src/generate/index.tssogenerate()has zero Node imports (onlygenerateToFile()depends onnode:fs)vite.config.tsto route renderer imports correctlywindow.main.runTests(src)via IPC instead of importing directly3. gRPC Proto Validation IPC (commit: 7a48ec1)
@grpc/proto-loadervalidation (usesnode:path) to main process via newmain/ipc/grpc.tshandlerwindow.main.grpc.validateProtoFileinstead of direct importentry.preload.tsandmain/ipc/electron.ts4. Vault Adapter Split (commit: 6a9fa56)
vault-adapter.ts(type definitions),vault-adapter.node.ts(Node-side),vault-adapter.renderer.ts(browser-safe via node-forge)node-forge; renderer callswindow.main.vault.{en,de}cryptSecretValuevia IPC bridgevault.tsto delegate to adapter5. Decouple Renderer from Scripting (commit: 67c8c01)
insomnia-scripting-environment/scripts/generate-autocomplete.tsgenerates autocomplete snippets from types at build timerequest-script-editor.tsxnow imports auto-generatedautocomplete-snippets.jsoninstead of hardcoded snippetsTest Plan
npm run type-check -w insomniapassesnpm run type-check -w insomnia-testingpassesnpm run lint -w insomniapassesrequire is not definederrors in renderer console