Web3 security firm GoPlus recently disclosed a “self-attack” security incident involving the AI development tool OpenClaw. During an automated task, the system generated an incorrect Bash command while attempting to create a GitHub Issue, unintentionally triggering a command injection vulnerability that exposed sensitive environment variables.
The issue occurred because the AI-generated string contained the command set wrapped in backticks. In Bash, backticks are interpreted as command substitution, meaning the command is executed automatically. When executed without parameters, set outputs all current environment variables in the system.
As a result, more than 100 lines of sensitive data—including Telegram keys and authentication tokens—were automatically written into a public GitHub Issue.
The incident highlights the growing security risks associated with AI-driven automation in development workflows. When AI tools dynamically construct Shell commands, even minor logic errors can lead to command injection, privilege misuse, or sensitive data exposure.
GoPlus recommends using API-based operations instead of direct Shell command construction in AI automation scenarios. Developers should also follow the principle of least privilege, isolate environment variables, disable high-risk execution modes, and introduce human review for critical operations.
From a broader security perspective, development vulnerabilities can quickly escalate into on-chain financial risks in the Web3 ecosystem. Once attackers obtain credentials or system access, stolen funds may be rapidly transferred across blockchain networks.
This is where Know Your Transaction (KYT) solutions become essential. Platforms such as Trustformer KYT, developed by Trustformer, enable real-time monitoring of blockchain transactions and identification of high-risk addresses, helping crypto businesses detect suspicious fund flows linked to potential security incidents.
As AI adoption in software development accelerates, integrating development security with blockchain monitoring and compliance tools will be increasingly important for protecting Web3 ecosystems.