State-sponsored threat actors linked to China are now actively incorporating publicly available Artificial Intelligence (AI) tools into their cyber-espionage operations. A report from Hunt.io reveals that China-aligned Advanced Persistent Threat (APT) groups have been using Anthropic's Claude Code and DeepSeek as integral parts of their attack chain. These AI services were used to automate intrusions, generate malicious scripts, and execute commands against government targets in Thailand and Afghanistan, and financial institutions in Taiwan. This represents a tactical shift towards using legitimate, commercially available AI platforms as offensive tools. By 'living off the trusted service,' these APTs can better evade detection, as traffic to these AI platforms may be considered benign within a target's network. This development makes sophisticated threats more stealthy and effective.
The integration of public AI tools into state-sponsored attacks marks a significant evolution in APT methodology. Instead of relying solely on custom malware and infrastructure, these groups are now weaponizing dual-use technologies that may already be present and trusted within a target environment.
The observed workflow involved using the AI models for distinct purposes:
bash commands to be run on the compromised system.This division of labor allows the APT group to accelerate its operations, adapt to target environments on the fly, and reduce the need for hands-on-keyboard activity by human operators, thereby increasing stealth and scalability.
The core technique at play is a form of 'Living off the Land' but extended to cloud services: 'Living off the Trusted Service.' By routing their command generation and execution logic through legitimate AI APIs, the attackers' activities can be difficult to distinguish from normal developer or user activity.
MITRE ATT&CK Techniques:
T1071.001 - Web Protocols: The attackers use standard HTTPS traffic to communicate with the Claude and DeepSeek APIs for command and control.T1105 - Ingress Tool Transfer: The AI-generated scripts and payloads are downloaded to the victim machine.T1059.004 - Unix Shell: Claude Code was used to generate and execute bash commands.T1588.006 - Web Services: The attackers are acquiring and using web-based AI services as part of their operational toolkit.This tactic is particularly insidious because it abuses the trust that organizations place in popular AI services. Security teams may have allow-listed traffic to anthropic.com or other AI providers, inadvertently creating a covert channel for APT command and control.
This trend is consistent with a broader increase in APT activity. A separate report from NSFOCUS noted a continuous rise in global APT operations in 2025, with 42 new groups identified. The integration of AI is seen as a key factor making these groups more dangerous.
The use of public AI tools by APTs has several critical impacts:
No specific Indicators of Compromise (IOCs) were provided in the source articles.
Defending against this tactic requires a shift in mindset from blocking known-bad to detecting anomalous-good.
bash script. The correlation of events is key. (D3FEND: Process Analysis)M1035 - Limit Access to Resource Over Network)M1020 - SSL/TLS Inspection)M1038 - Execution Prevention)Update reveals specific AI roles, TencShell backdoor, detailed data exfiltration, and staging of infrastructure for U.S. government targets by China-linked APTs.
The campaign's dual-AI setup is further detailed: DeepSeek-v4-pro handles strategic reasoning, vulnerability identification, and exploit generation (including SQL injection and Laravel deserialization), while Claude Code manages tactical execution, persistence, and session management. The operation was uncovered via an exposed directory linked to the TencShell Go-based backdoor. Attackers successfully exfiltrated cloud tokens from Taiwan, national ID records from Thailand, and citizen complaint databases with encryption keys from Afghanistan. Significantly, infrastructure was staged to target U.S. government entities, including NASA subdomains, indicating an expanded scope. New cyber observables for hunting are also provided.

Cybersecurity professional with over 10 years of specialized experience in security operations, threat intelligence, incident response, and security automation. Expertise spans SOAR/XSOAR orchestration, threat intelligence platforms, SIEM/UEBA analytics, and building cyber fusion centers. Background includes technical enablement, solution architecture for enterprise and government clients, and implementing security automation workflows across IR, TIP, and SOC use cases.
CyberNetSec.io uses automation to assist source monitoring, deduplication, observable extraction, and structured intelligence generation. Published analysis follows human-defined editorial standards and adds defensive context including MITRE ATT&CK, D3FEND, STIX, and Sigma where applicable. Read our editorial policy.
Help others stay informed about cybersecurity threats
Every tactic, technique, and sub-technique used in this threat has been identified and mapped to the MITRE ATT&CK framework for consistent, actionable threat language.
Observables and indicators of compromise (IOCs) have been extracted and cataloged. Risk has been assessed and correlated with known threat actors and historical campaigns.
Detection rules, incident response steps, and D3FEND-aligned mitigation strategies are included so your team can act on this intelligence immediately.
Structured threat data is packaged as a STIX 2.1 bundle and can be visualized as an interactive graph — relationships between actors, malware, techniques, and indicators.
Sigma detection rules are derived from the threat techniques in this article and can be converted for deployment across any major SIEM or EDR platform.