Skip to content

ci: remove public-artifact secret scan from mobile release workflows - #8908

Merged
mdmohsin7 merged 1 commit into
mainfrom
ci/remove-mobile-artifact-secret-scan
Jul 3, 2026
Merged

mdmohsin7 merged 1 commit into
mainfrom
ci/remove-mobile-artifact-secret-scan

Conversation

@mdmohsin7

@mdmohsin7 mdmohsin7 commented Jul 3, 2026 •

Copy link
Copy Markdown
Member

Summary

Removes the six scan-public-artifact-secrets.py invocations (and the AAB_ARTIFACTS find lines that existed only to feed them) from the iOS/Android prod and shorebird-patch workflows in codemagic.yaml. The scanner script, its tests, client_env_policy.yaml, and the desktop release guard are untouched.

Why

Every prod mobile build is currently failing on false positives. The variable-like-token heuristic greps ALL-CAPS tokens out of compiled artifacts and matches them against denied_name_patterns — and the flagged tokens are all Firebase Auth SDK error constants baked into the statically linked Runner executable, plus P12 in the dSYM Symbols/*.symbols files:

  • ERROR_INVALID_CREDENTIAL, MISSING_APP_CREDENTIAL, INVALID_LOGIN_CREDENTIALS, MISSING_MFA_PENDING_CREDENTIAL, INVALID_MFA_PENDING_CREDENTIAL → (^|_)CREDENTIALS?($|_)
  • ERROR_CUSTOM_TOKEN_MISMATCH, ERROR_INVALID_CUSTOM_TOKEN, MISSING_IOS_APP_TOKEN → (^|_)TOKEN($|_)
  • INVALID_PASSWORD → (^|_)PASSWORD($|_), API_KEY → (^|_)API_KEY($|_), P12 → (^|_)P12($|_)

The .framework/.xcframework carve-out from #8741 never covered the main binary or the top-level Symbols/ directory.

This is the second time this scan has broken the mobile release on SDK constant strings (first: BatteryWidget.appex, reverted in 7123930; re-landed hours later by #8773). The mobile build steps inject no server env values into the bundle, so scanning compiled Mach-O output for env-var-shaped names is noise by construction — the scanner's real protection (the check for actual CI secret values) never fired.

cc @Git-on-my-level — if this scan is re-landed a third time, it needs to exclude compiled executables and symbol files from the name-pattern heuristic first (the exact-name and secret-value checks can safely keep running on binaries).

Validation

  • python3 .github/scripts/check-release-process-guards.py passes (the guard requires scripts/scan-public-artifact-secrets.py to exist; it still does)
  • codemagic.yaml parses as valid YAML; zero remaining scanner references; no dangling AAB_ARTIFACTS uses

🤖 Generated with Claude Code

Review in cubic

The variable-like-token heuristic in scan-public-artifact-secrets.py
false-positives on every mobile build: Firebase Auth SDK error constants
(ERROR_INVALID_CREDENTIAL, INVALID_LOGIN_CREDENTIALS, MISSING_IOS_APP_TOKEN,
INVALID_PASSWORD, API_KEY) compiled into the statically linked Runner
executable and P12 in the dSYM Symbols/*.symbols files all match the
denied_name_patterns in client_env_policy.yaml. The .framework/.xcframework
carve-out from #8741 never covered the main binary or top-level Symbols/.

This is the second time the scanner has broken the Codemagic mobile
release on SDK constant strings (see revert 7123930); PR #8773
re-landed the wiring hours after that revert. The mobile build injects
no server env values, so scanning compiled Mach-O output for ALL-CAPS
env-var-shaped names yields only noise.

Removes the six scan invocations (and the AAB_ARTIFACTS find lines that
existed only to feed them) from the iOS/Android prod and shorebird-patch
workflows. The scanner script, its tests, and the desktop release guard
(which only requires the file to exist) are untouched.

@cubic-dev-ai cubic-dev-ai Bot 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.

No issues found across 1 file

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Re-trigger cubic

@mdmohsin7
mdmohsin7 merged commit b781d91 into main Jul 3, 2026
3 checks passed
@mdmohsin7
mdmohsin7 deleted the ci/remove-mobile-artifact-secret-scan branch July 3, 2026 09:14
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.

1 participant