Back to skill

Security audit

ios mobpush integration (MobTech MobPush 一键集成 )

Security checks for vulnerabilities and agentic risk

Overview

The skill is mostly coherent for MobPush integration, but it needs review because it collects an app secret and may leave it in project files without enough handling guidance.

Install only after reviewing the workflow. Keep MobPush_iOS_Config.xlsx out of source control, delete or move the populated workbook after use, treat MOBAppSecret in Info.plist as client-extractable, pin and review the mob_pushsdk version, and only run pod install/update after checking the planned file changes and target selection.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
Findings (2)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:271
Finding
Unpinned MobPush SDK Dependency Allows Unreviewed Supply-Chain Changes<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:271`, `SKILL.md:407-412` **Vulnerability Type**: Unpinned third-party native dependency **Risk Level**: Medium ### Vulnerable Code ```markdown - `Podfile` 中加入 `pod 'mob_pushsdk'` ``` ```markdown 在用户确认后才执行: - `pod install` 或 `pod update` - **注意**:Ruby 4.0+ 环境下 `pod install` 可能因编码问题失败,需先设置环境变量: ```bash export LANG=en_US.UTF-8 && export LC_ALL=en_US.UTF-8 pod install ``` ``` ### Technical Analysis The generated CocoaPods declaration does not constrain `mob_pushsdk` to an exact, reviewed version. The workflow also permits `pod update`, which may replace a previously locked dependency with the latest version allowed by the Podfile. CocoaPods dependencies can contain native application code, transitive dependencies, resource-processing logic, and build-phase scripts. Consequently, resolving a changed or compromised release may introduce code that executes during the build or becomes embedded in the resulting application. User confirmation before dependency installation reduces accidental execution, but it does not address dependency authenticity, version mutability, or review of lockfile changes. ### Attack Path 1. An attacker compromises the upstream package, its publishing account, a transitive dependency, or the package distribution infrastructure. 2. A malicious or unexpectedly modified `mob_pushsdk` release becomes available. 3. The Skill adds the unpinned declaration `pod 'mob_pushsdk'`. 4. The user authorizes `pod install` or `pod update`. 5. CocoaPods resolves the altered dependency and modifies `Podfile.lock`. 6. Malicious native code or a build hook executes in the developer or CI environment, or is embedded in the application. 7. The payload can act with the permissions available to the build process or, after deployment, with the permissions granted to the application. ### Impact Assessment A compromised dependency could: - Execute code under the developer or CI account d ...[truncated 484 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Pin `mob_pushsdk` to an exact version that has been reviewed: ```ruby pod 'mob_pushsdk', 'REVIEWED_VERSION' ``` 2. Commit and review `Podfile.lock`, and fail CI when it changes without explicit dependency-review approval. 3. Use `pod install` for normal installation. Do not offer `pod update` as an interchangeable default operation. 4. Before accepting an update: - Review the resolved version and source. - Inspect all lockfile and transitive-dependency changes. - Review newly introduced build scripts. - Validate available package checksums and release signatures against trusted vendor information. 5. Restrict build jobs so dependency scripts cannot access unrelated deployment credentials or signing secrets. 6. Run dependency installation and builds in an isolated, minimally privileged environment. 7. Document the approved MobPush version and define a controlled process for security updates. ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
assets/generate_excel_template.py:36
Finding
MobPush Application Secret Is Collected and Stored in Plaintext Project Artifacts<![CDATA[ ## Vulnerability Details **File Location**: `assets/generate_excel_template.py:36-41`, `SKILL.md:183-210`, `SKILL.md:251-255` **Vulnerability Type**: Plaintext sensitive-data storage **Risk Level**: Medium ### Vulnerable Code ```python rows = [ ["appKey", "MobTech 后台申请得到的 AppKey,必填", ""], ["appSecret", "MobTech 后台申请得到的 AppSecret,必填", ""], ["apnsAuthMode", "APNs 鉴权方式,只填 p12、p8 或 已存在", "已存在"], ["needLiveActivity", "本次是否需要同时接入 Live Activity,只填 是 或 否", "否"], ] ``` The Skill requires this value to be populated in a project-root workbook: ```markdown 必须明确告诉用户只需要填写这些最小字段: - `appKey` - `appSecret` - `apnsAuthMode` - `needLiveActivity` ``` It then directs the Agent to place the same value in the application property list: ```markdown - `Info.plist`:写入 `MOBAppKey`、`MOBAppSecret`、`MOBNetLater = 2` ``` ### Technical Analysis The workflow collects `appSecret` in `MobPush_iOS_Config.xlsx`, which is copied to the target project root. It does not instruct the Agent to exclude the populated workbook from version control, delete it after use, limit its filesystem permissions, or prevent it from entering shared archives and CI artifacts. The value is subsequently written into `Info.plist`. Values embedded in an iOS application bundle are recoverable from a distributed application and therefore cannot provide strong confidentiality. Calling the value a secret may lead developers to rely on it as though it were a server-side credential. This issue does not establish that the credential can independently authorize a specific MobTech operation. Exploitability and business impact depend on MobTech's server-side authorization and credential-rotation model. Nevertheless, the workflow unnecessarily creates an additional plaintext copy in a repository-prone workbook. ### Attack Path 1. A developer runs the template generator and copies `MobPush_iOS_Config.xlsx` to the project root as instructed. 2. The developer enters the MobPush `appSecret` into th ...[truncated 1450 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Add the populated workbook to `.gitignore` before generating or copying it: ```gitignore MobPush_iOS_Config.xlsx ``` 2. Clearly distinguish the distributable blank template from the populated local configuration file. 3. Delete the populated workbook immediately after validated import, or store it outside the repository with restrictive filesystem permissions. 4. Never include actual credential values in `MobPush_README.md`, logs, command output, patches, screenshots, or audit summaries. 5. Where the SDK and build system support it, inject configuration from local or CI-managed secret storage rather than maintaining a plaintext project-root workbook. 6. Document that any value embedded in `Info.plist` is recoverable from the application bundle and must not be treated as a server-side secret. 7. Ensure sensitive operations require server-side authorization independent of client-embedded credentials. 8. Rotate the MobPush credential if a populated workbook or plist has entered a public repository, untrusted artifact store, or unauthorized archive. 9. Add automated secret scanning for `MOBAppSecret`, populated configuration workbooks, and equivalent credential formats. ]]>
Vulnerability Patterns
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (19)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
声明描述的是一个能够对 iOS 项目进行实际 MobPush 集成的技能,核心能力应包括工程扫描、依赖接入、配置修改和文档落地。实际代码则是一个离线资产生成脚本,只负责创建 Excel 模板,帮助用户填写 appKey/appSecret、APNs 鉴权方式和合规提示。虽然模板内容与 MobPush 集成主题相关,属于辅助材料,但它并不实现声明中的主要功能,主目的存在明显偏差,因此应判定为不匹配。

Natural-Language Policy Violations

Medium
Confidence
95% confidence
Finding
The skill description is written entirely in Chinese and does not indicate that another language is available or that Chinese is a required locale for a region-specific use case. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Session Persistence

Medium
Category
Rogue Agent
Content
- `Podfile`
- `Podfile.lock`
- `Info.plist`
- App 启动入口文件
- 隐私同意回调文件
- 其他按实际项目补充
Confidence
75% confidence
Finding
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Natural-Language Policy Violations

Low
Confidence
94% confidence
Finding
The skill explicitly instructs the agent to '默认使用中文与用户沟通', which imposes a language preference on all interactions. Under the policy, language constraints should either offer user choice or be clearly justified as region-specific; this section does not provide opt-in or a documented necessity.

Natural-Language Policy Violations

Low
Confidence
88% confidence
Finding
This markdown file contains user-facing instructions only in Chinese, and there is no indication that the skill is region-specific or that users can opt into another language. Under the policy criteria, forcing a specific language without opt-in can be a natural-language policy violation.

Static analysis

No suspicious patterns detected.