<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Macdonald</title>
    <description>The latest articles on DEV Community by Macdonald (@macbere).</description>
    <link>https://dev.to/macbere</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4038499%2F1b4ada6b-eb24-428e-ae73-6096fb01b203.png</url>
      <title>DEV Community: Macdonald</title>
      <link>https://dev.to/macbere</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/macbere"/>
    <language>en</language>
    <item>
      <title>How I Built an Autonomous Cyber Security Agent with Qwen AI- A Nocoder's Journey</title>
      <dc:creator>Macdonald</dc:creator>
      <pubDate>Mon, 20 Jul 2026 16:32:22 +0000</pubDate>
      <link>https://dev.to/macbere/how-i-built-an-autonomous-cyber-security-agent-with-qwen-ai-a-nocoders-journey-14m6</link>
      <guid>https://dev.to/macbere/how-i-built-an-autonomous-cyber-security-agent-with-qwen-ai-a-nocoders-journey-14m6</guid>
      <description>&lt;p&gt;The Problem That Kept Me Up at Night&lt;br&gt;
Every 39 seconds, a cyberattack happens somewhere in the world. Security teams are overwhelmed, thousands of alerts, not enough analysts, and average response times of 4 hours. In those 4 hours, ransomware encrypts files, credentials get exfiltrated, and attackers establish persistence.&lt;/p&gt;

&lt;p&gt;I am not a developer. I have never written production code before. But I knew this problem was solvable, and the Global AI Hackathon Series with Qwen Cloud gave me the opportunity to try.&lt;/p&gt;

&lt;p&gt;This is the story of how I built Sentinel Edge, a fully autonomous cybersecurity incident response agent, entirely on Android using Termux, with Qwen AI as the brain and Alibaba Cloud ECS as the backbone.&lt;/p&gt;

&lt;p&gt;What Is Sentinel Edge?&lt;br&gt;
Sentinel Edge is an autonomous cybersecurity agent that responds to security alerts in under 15 seconds. When a threat alert comes in, it runs a 9-step pipeline — with 4 Qwen AI reasoning steps at its core:&lt;br&gt;
Step 1 — Alert Ingestion: The perception module extracts every indicator of compromise from the raw alert; IP addresses, file paths, usernames, domains.&lt;/p&gt;

&lt;p&gt;Step 2 — Threat Classification (Qwen AI ①): Qwen-max classifies the threat type and severity. Ransomware? Data exfiltration? Privilege escalation? Qwen decides.&lt;/p&gt;

&lt;p&gt;Step 3 — Tool Selection (Qwen AI ②): Based on the threat, Qwen selects the most appropriate security tools. GitHub exposure? It recommends GitGuardian and Trufflehog. Ransomware? CrowdStrike Falcon and EDR.&lt;/p&gt;

&lt;p&gt;Step 4 — Threat Intelligence Lookup: Live AbuseIPDB integration checks attacker IP reputation in real time. Abuse score 100%. Tor exit node. Germany. This is live data, not simulated.&lt;/p&gt;

&lt;p&gt;Step 5 — Action Plan Generation (Qwen AI ③): Qwen generates specific, actionable containment steps tailored to the exact threat.&lt;/p&gt;

&lt;p&gt;Step 6 — Confidence Validation (Qwen AI ④): Qwen validates its own reasoning, a self-check that catches low-confidence decisions before they reach a human.&lt;/p&gt;

&lt;p&gt;Step 7 — Campaign Correlation: The correlation engine cross-references this incident against 720 hours of historical data to detect coordinated APT campaigns.&lt;/p&gt;

&lt;p&gt;Step 8 — Human Approval Gate: This is the most important step. Sentinel Edge never acts alone on critical threats. It presents its full reasoning chain and waits for human authorization.&lt;/p&gt;

&lt;p&gt;Step 9 — Containment Execution: Only after human approval does the system execute and log all containment actions with full timestamps for compliance and forensics.&lt;/p&gt;

&lt;p&gt;Why Qwen AI?&lt;br&gt;
I chose Qwen specifically because it natively supports JSON response format, critical for structured security data extraction. Its advanced reasoning handles 4 distinct cognitive tasks sequentially without hallucinating intermediate steps.&lt;/p&gt;

&lt;p&gt;Running on Alibaba Cloud DashScope International provides low-latency access from our ECS deployment on the same infrastructure. Every single one of our 111+ analyses is a real Qwen API call, zero mocked responses, zero offline fallbacks.&lt;br&gt;
The results speak for themselves:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;111 real Qwen AI analyses — 100% real API calls&lt;/li&gt;
&lt;li&gt;6 APT campaigns automatically detected across 111 incidents&lt;/li&gt;
&lt;li&gt;Under 15 seconds from alert submission to containment plan&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The Technical Stack&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;AI Brain: Qwen Cloud API (qwen-max) via Alibaba Cloud DashScope&lt;/li&gt;
&lt;li&gt;Backend: Python Flask + Gunicorn (5 workers × 4 threads)&lt;/li&gt;
&lt;li&gt;Database: SQLite with persistent APT campaign correlation memory&lt;/li&gt;
&lt;li&gt;Web Server: Nginx reverse proxy with SSL/HTTPS&lt;/li&gt;
&lt;li&gt;Deployment: Alibaba Cloud ECS (Ubuntu 22.04, US Silicon Valley)&lt;/li&gt;
&lt;li&gt;Process Manager: systemd — 430+ hours continuous uptime&lt;/li&gt;
&lt;li&gt;Threat Intelligence: AbuseIPDB live API via MCP integration&lt;/li&gt;
&lt;li&gt;Frontend: Vanilla HTML/CSS/JavaScript with Chart.js analytics&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The Challenges — Building on Android with No Code Experience&lt;br&gt;
I want to be completely honest about how this was built. I am not a developer. Every single command in this project was written with AI assistance, executed through Termux on my Android phone, and verified step by step. &lt;br&gt;
Challenge 1: API Key Security&lt;br&gt;
Early in the project, I accidentally committed both my Qwen API key and AbuseIPDB key to a public GitHub repository inside a documentation file. The moment I realized this, I immediately rotated both keys, deleted the file from the repository, and implemented proper .gitignore protection. Lesson learned — never commit secrets, always use environment variables.&lt;/p&gt;

&lt;p&gt;Challenge 2: HTTPS Setup&lt;br&gt;
Getting SSL certificates for a DuckDNS subdomain was surprisingly complex. The standard HTTP-01 challenge kept failing because Let's Encrypt's servers couldn't reach my domain consistently. After multiple failed attempts with certbot, I switched to acme.sh with DNS-01 challenge, which automatically sets TXT records via the DuckDNS API. It worked perfectly.&lt;/p&gt;

&lt;p&gt;Challenge 3: SSH Connection Drops&lt;br&gt;
Running interactive commands over a mobile 4G connection meant SSH sessions would drop mid-execution. During one certbot attempt, the connection dropped just as I pressed Enter to confirm the DNS challenge, and the certificate wasn't issued. The solution was using acme.sh's non-interactive DNS challenge mode, which completes entirely server-side.&lt;/p&gt;

&lt;p&gt;Challenge 4: State Synchronization Bug&lt;br&gt;
I discovered a logical bug where the UI showed "4 actions executed successfully" on incidents that were still pending human approval, before anyone had clicked approve. This was a state mismatch between the backend status and the frontend rendering logic. Fixed by injecting the incident's status into the containment step rendering and locking the UI until the status changed to "executed."&lt;/p&gt;

&lt;p&gt;Challenge 5: Own IP as Threat Actor&lt;br&gt;
The APT campaign correlation engine was flagging my own Alibaba Cloud server IP (47.77.199.98) as a threat actor in campaign profiles. The fix was implementing an IP whitelist across all 4 modules; perception, reasoning, correlation, and MCP threat intel, to exclude our own infrastructure from threat detection.&lt;/p&gt;

&lt;p&gt;The Human-in-the-Loop Philosophy&lt;br&gt;
The most important design decision in Sentinel Edge was the Human Approval Gate. Many AI agents are fully autonomous, they act without human oversight. I deliberately chose not to do this.&lt;br&gt;
For critical and high-severity threats, Sentinel Edge presents its complete reasoning chain; every step, every data point, every confidence score, and then stops. It waits for a human operator to review and authorize containment.&lt;br&gt;
This is not a weakness. This is the feature that makes Sentinel Edge trustworthy for real enterprise use. AI should augment human judgment, not replace it.&lt;/p&gt;

&lt;p&gt;What I Learned&lt;br&gt;
Qwen AI is genuinely impressive at cybersecurity reasoning. The 4-step chain consistently produces analysis quality that rivals what a senior SOC analyst would produce; threat classification, tool selection, containment planning, and self-validation, all in under 10 seconds.&lt;/p&gt;

&lt;p&gt;Production deployment is 10× harder than building the application. SSL certificates, reverse proxies, systemd service files, security group rules, IP whitelisting, each took significant effort to get right. But the result is a system that has run continuously for 430+ hours without manual intervention.&lt;/p&gt;

&lt;p&gt;Being a no-coder is not a limitation, it is a different kind of engineering. The challenge is not writing code, it is understanding systems deeply enough to direct and instruct AI assistance precisely. Every bug I fixed, I had to understand well enough to explain what was wrong and verify the fix worked.&lt;/p&gt;

&lt;p&gt;The Result&lt;br&gt;
Sentinel Edge is live right now at &lt;a href="https://sentinel-edge.duckdns.org" rel="noopener noreferrer"&gt;https://sentinel-edge.duckdns.org&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;111 incidents processed&lt;/li&gt;
&lt;li&gt;111 real Qwen AI analyses (100%)&lt;/li&gt;
&lt;li&gt;6 APT campaigns automatically detected&lt;/li&gt;
&lt;li&gt;49/49 tests passing&lt;/li&gt;
&lt;li&gt;430+ hours continuous uptime on Alibaba Cloud ECS&lt;/li&gt;
&lt;li&gt;Full HTTPS with Let's Encrypt SSL&lt;/li&gt;
&lt;li&gt;Human-in-the-Loop approval gate securing every critical action
The source code is fully open source at &lt;a href="https://github.com/macbere/sentinel-edge" rel="noopener noreferrer"&gt;https://github.com/macbere/sentinel-edge&lt;/a&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;What's Next&lt;br&gt;
Sentinel Edge proved that a no-coder with the right AI tools can build production-grade cybersecurity infrastructure. The next steps are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Multi-tenant SaaS with user authentication&lt;/li&gt;
&lt;li&gt;Slack and email alerting for new critical incidents&lt;/li&gt;
&lt;li&gt;SIEM integrations for Splunk and Microsoft Sentinel&lt;/li&gt;
&lt;li&gt;Mobile approval app for on-the-go authorization&lt;/li&gt;
&lt;li&gt;VirusTotal and Shodan threat intelligence expansion&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Built with Qwen Cloud AI · Alibaba Cloud ECS · Python Flask · AbuseIPDB · Love and stubbornness&lt;br&gt;
Global AI Hackathon Series 2026 · Track 4-Autopilot Agent&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>hackathon</category>
      <category>alibabachallenge</category>
    </item>
  </channel>
</rss>
