Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Credential check version mismatches violate the registry invariant and cause getRegistry() to throw.
1 open finding
What changed in this PR
Restricts Shopify CLI’s agent security investigations to static code inspection, preventing execution or live-service probing to prove findings.
Changes:
- Adds static-only rules and unresolved-candidate guidance.
- Updates both credential-leakage prompts to version 3 and regenerates embedded content.
- Adds targeted instruction assertions.
| File | Description |
|---|---|
| packages/app/src/cli/services/app-security-instructions.test.ts | Tests static-only workflow instructions. |
| packages/app/src/cli/services/app-security-engine/tests/checks.test.ts | Checks restrictions and credential prompt versions. |
| packages/app/src/cli/services/app-security-engine/INSTRUCTIONS.md | Defines static-only investigation rules. |
| packages/app/src/cli/services/app-security-engine/checks/index.ts | Adds restrictions to generated agent instructions. |
| packages/app/src/cli/services/app-security-engine/checks/embedded.ts | Synchronizes embedded prompts and instructions. |
| packages/app/src/cli/services/app-security-engine/checks/CREDENTIAL_LOG_LEAKAGE.md | Restricts verification and bumps version. |
| packages/app/src/cli/services/app-security-engine/checks/CREDENTIAL_BROWSER_LEAKAGE.md | Restricts verification and bumps version. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| --- | ||
| id: CREDENTIAL_LOG_LEAKAGE | ||
| version: 2 | ||
| version: 3 |
dmerand
approved these changes
Oct 16, 2026
Contributor
There was a problem hiding this comment.
These tests are a bit funny but it does make sense to assert our product guidance in tests this way at least 👍🏼
This branch has not been deployed
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.

WHY are these changes introduced?
An agent proving a credential-leakage finding executed app/SDK code to build a repro, which made an unintended outbound request. The shipped prompts never forbade execution or network calls, unlike the XSS/SQLi checks, so a security-review agent could touch live services while trying to prove a finding.
WHAT is this pull request doing?
checks/index.tsINSTRUCTIONS andINSTRUCTIONS.md§3): verify by reading code; don't execute app, SDK, test, or repro code; don't make network calls or probe live stores/services to prove a finding; if a candidate can't be proved from code, record the check as unresolved naming the candidate.CREDENTIAL_LOG_LEAKAGEandCREDENTIAL_BROWSER_LEAKAGE, bumping both v2 → v3, and regenerateschecks/embedded.ts.Targeted tests:
checks.test.tsandapp-security-instructions.test.ts(64 passed); eslint on the touched TS files passes.