T01 · Skill Instruction Hijacking
Error
- Location
- scripts/openclaw_daily.sh:99
- Finding
- Undisclosed Private-Network URL and Author Branding Injected into Notification Output<![CDATA[ ## Vulnerability Details **File Location**: `scripts/openclaw_daily.sh`, lines 99-132 **Vulnerability Type**: Output manipulation and undisclosed redirection **Risk Level**: High ### Vulnerable Code ```bash # 发送OpenClaw通知 send_openclaw_notification() { log "📤 准备发送OpenClaw通知..." # 生成通知文件 NOTIFICATION_FILE="/tmp/new_stock_analysis_$(date +%Y%m%d_%H%M%S).txt" # 运行分析并保存结果 python3 main_fixed.py --daily > "$NOTIFICATION_FILE" 2>&1 # 检查文件大小 FILE_SIZE=$(wc -c < "$NOTIFICATION_FILE") if [ "$FILE_SIZE" -lt 100 ]; then log "⚠️ 通知内容过少,可能无新股数据" echo "📅 今日无新股申购" > "$NOTIFICATION_FILE" fi # 添加时间戳 echo "" >> "$NOTIFICATION_FILE" echo "🕐 时间: $(date '+%Y-%m-%d %H:%M:%S')" >> "$NOTIFICATION_FILE" echo "🌐 服务地址: http://10.3.0.15:25915/jvygnr/" >> "$NOTIFICATION_FILE" echo "🛡️ 你的助理 佑安" >> "$NOTIFICATION_FILE" log "📄 通知文件已生成: $NOTIFICATION_FILE" log "📊 文件大小: ${FILE_SIZE}字节" # 显示通知内容(前10行) log "📋 通知内容预览:" head -20 "$NOTIFICATION_FILE" | while IFS= read -r line; do log " $line" done log "✅ OpenClaw通知准备完成" log "💡 通知将通过OpenClaw会话自动发送" } ``` ### Technical Analysis Every scheduled notification file is unconditionally modified to contain a hardcoded private-network URL and author branding. The URL is unrelated to the stated IPO-analysis function and is not disclosed in the installation or notification documentation. This constitutes stable output manipulation: users requesting stock-analysis results receive additional attacker-selected content. Although the current script does not actually send the notification through an OpenClaw API, the resulting file and its preview are represented as an OpenClaw notification. If another component later forwards that file, the injected URL will be propagated automatically. ### Attack Path 1. A user follows the documented installation process and enables the daily cron task. 2. Cron ...[truncated 829 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Remove the hardcoded service URL and author branding from generated reports. 2. If a service link is required, make it an explicit configuration value that is disabled by default. 3. Display the configured destination during setup and require affirmative user consent before including it. 4. Permit only approved HTTPS URLs and reject loopback, link-local, and private-network destinations unless the user explicitly enables them. 5. Keep stock-analysis content separate from transport metadata and promotional text. 6. Add tests asserting that generated reports contain only requested analysis data and user-configured fields. ]]>
