<?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: Ruslan Murtuzaliyev</title>
    <description>The latest articles on DEV Community by Ruslan Murtuzaliyev (@id_1).</description>
    <link>https://dev.to/id_1</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.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3632363%2F808b68be-14b0-4b31-9148-77cfa4052180.jpg</url>
      <title>DEV Community: Ruslan Murtuzaliyev</title>
      <link>https://dev.to/id_1</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/id_1"/>
    <language>en</language>
    <item>
      <title>Kaspersky Found 512 Bugs in OpenClaw. So I Built a Monitor to Catch AI Agents Misbehaving.</title>
      <dc:creator>Ruslan Murtuzaliyev</dc:creator>
      <pubDate>Wed, 18 Mar 2026 22:35:10 +0000</pubDate>
      <link>https://dev.to/id_1/kaspersky-found-512-bugs-in-openclaw-so-i-built-a-monitor-to-catch-ai-agents-misbehaving-30a9</link>
      <guid>https://dev.to/id_1/kaspersky-found-512-bugs-in-openclaw-so-i-built-a-monitor-to-catch-ai-agents-misbehaving-30a9</guid>
      <description>&lt;h2&gt;
  
  
  &lt;strong&gt;How this started&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;I didn't plan to build a security tool. I'm a CS student in Toronto. My February plans involved catching up on assignments, maybe learning some Rust.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Then OpenClaw went viral.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you missed it: OpenClaw is an open-source AI agent that hit 20,000 GitHub stars in 24 hours. It connects to your WhatsApp, email, calendar, terminal. It runs 24/7. It writes its own code for tasks it hasn't seen before.&lt;/p&gt;

&lt;p&gt;Kaspersky audited it: &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;512 vulnerabilities. Eight critical. A researcher got into Anthropic API keys, Telegram tokens, full admin access on exposed instances with Shodan. SecurityScorecard counted 135,000+ instances on the public internet, zero auth. More than 15,000 were vulnerable to remote code execution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;820 out of 10,700 ClawHub skills were malware.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I read the Kaspersky report in my dorm and realized something basic: there's no tooling for this. Antivirus for malware, sure. Firewalls for networks. EDR for endpoints. But for AI agents running code on your machine with full disk access?&lt;/p&gt;

&lt;p&gt;&lt;em&gt;&lt;strong&gt;Nothing existed. So I started building...&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;What it does?&lt;/strong&gt; (&lt;a href="https://aegis-demo-ten.vercel.app/" rel="noopener noreferrer"&gt;demo&lt;/a&gt;)
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fziajp6ewg0sd3kp2zz08.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fziajp6ewg0sd3kp2zz08.gif" alt="1"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Aegis sits between your AI agent and your OS. It polls and diffs process trees, watches the filesystem via chokidar, and logs network activity through OS-level APIs, all in user-space, no drivers required. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It watches four things:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1) Processes:&lt;/strong&gt;&lt;br&gt;
Every spawn, every child process, every shell command. When Claude Code runs npm install, you see it. When something tries to curl a domain you don't recognize, you see that too.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2) Files:&lt;/strong&gt;&lt;br&gt;
Real-time filesystem monitoring via chokidar. What's being read, written, created, deleted. Configurable rules flag when anything touches .env, .ssh/, or your credentials directory.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3) Network:&lt;/strong&gt;&lt;br&gt;
Outbound connections, DNS lookups, data leaving your machine. This is the one that gets the most attention from testers — knowing exactly where your agent sends data.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4) Behavior:&lt;/strong&gt; &lt;br&gt;
68 detection rules match against known risky patterns. Each agent gets a trust score, 0 to 100, updated live.&lt;/p&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4959o2kj6osp0emdpc4z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4959o2kj6osp0emdpc4z.png" alt="2"&gt;&lt;/a&gt;&lt;/p&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuyh7bqu4tnurz3ixr2ix.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuyh7bqu4tnurz3ixr2ix.png" alt="3"&gt;&lt;/a&gt;&lt;/p&gt;


&lt;h2&gt;
  
  
  &lt;strong&gt;The rule engine&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;This is where Aegis went from personal hack to something shareable. Rules are defined in a structured format, an example of what one looks like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;    &lt;span class="na"&gt;yaml- id&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;AI012&lt;/span&gt;
    &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Sensitive Config Access&lt;/span&gt;
    &lt;span class="na"&gt;category&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;filesystem&lt;/span&gt;
    &lt;span class="na"&gt;severity&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;high&lt;/span&gt;
    &lt;span class="na"&gt;pattern&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\\&lt;/span&gt;&lt;span class="s"&gt;.env|&lt;/span&gt;&lt;span class="se"&gt;\\&lt;/span&gt;&lt;span class="s"&gt;.ssh|credentials|secret"&lt;/span&gt;
    &lt;span class="na"&gt;description&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Agent accessing sensitive configuration files&lt;/span&gt;
    &lt;span class="na"&gt;riskModifier&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;On startup, the loader compiles patterns to RegExp, caches them in a Map, builds a categoryIndex for O(1) lookups by category.&lt;br&gt;
Rules hot-reload - edit the source, they update without a restart.&lt;/p&gt;

&lt;p&gt;68 rules cover filesystem access, network patterns, process behaviors, and agent-specific signatures including OpenClaw.&lt;/p&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;What I got wrong:&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;1: Chokidar globs.&lt;/strong&gt; I used glob patterns in ignored. Lost two days to events either missing or crashing. The issue is documented but not obvious. Function-form fixed it immediately.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2: Tautological tests.&lt;/strong&gt; I wrote 12 tests for formatBytes, all green, looked great. A contributor pointed out every single test checked static input against static output. No edge cases. No boundaries. No negative numbers, no zero, no floats. She rewrote them into 25 tests that actually caught bugs. I merged it the same day.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3: Backdrop-filter stacking.&lt;/strong&gt; I put backdrop-filter: blur() on 33 elements for the glassmorphism look. Frames dropped. I didn't profile for a week because the rest of the UI was "fast enough." Eventually measured it — 33 composited elements is just too many. Cut it to 5, kept the visual effect where it mattered.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4: Pushing to master.&lt;/strong&gt; "It's just a docs change." Lint-staged v16 has a bug on markdown-only commits. CI failed. Now I have a pre-commit hook that blocks edits on master. Should have had that from the start.&lt;br&gt;
My own security bugs. During a hardening pass I found HTML injection in IPC channels, path traversal bypassing file access rules, and no protection against LLM prompt injection. Three PRs, 112 new tests. If you're building anything that talks to an AI model over IPC, audit it. You'll find something.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5: My own security bugs.&lt;/strong&gt; During a hardening pass I found HTML injection in IPC channels, path traversal bypassing file access rules, and no protection against LLM prompt injection. Three PRs, 112 new tests. If you're building anything that talks to an AI model over IPC, audit it. You'll find something.&lt;/p&gt;




&lt;h2&gt;
  
  
  Stack
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; Electron 33       Desktop shell
 Svelte 5 (runes)  43 components, pure CSS, no UI libraries
 Vite 7             Build: ~1.5s
 Vitest 4           707 tests, 44 files
 TypeScript         Strict, incremental migration from JS
 chokidar 3.6       File watching
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The main process is 28 CommonJS modules (23 core + 5 platform-specific) loaded directly by Node — no build step. CJS gets grief, but Electron's main process doesn't need a bundler, and I haven't spent a single hour debugging module resolution. I'll migrate when Electron's ESM support is stable.&lt;/p&gt;

&lt;p&gt;The renderer is 43 Svelte components with all animations constrained to &lt;em&gt;transform&lt;/em&gt; and &lt;em&gt;opacity&lt;/em&gt;, GPU composited only. No layout thrashing.&lt;/p&gt;

&lt;p&gt;IPC is batched at 1000ms. Stats use running counters, not recalculated from raw data. Startup staggers monitors at 3, 8, and 12 seconds so nothing blocks first paint. Bundle ships at 60kB gzipped JS. Idle memory sits around 180-220MB (Electron baseline + monitoring overhead).&lt;/p&gt;




&lt;h2&gt;
  
  
  What Aegis can't do
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;No kernel-level monitoring.&lt;/strong&gt; Everything is user-space polling. A sophisticated agent or malware with privilege escalation can bypass this , Aegis won't catch what it can't observe. This is a visibility tool for understanding agent workflows, not a defense against APTs. ETW on Windows and eBPF on Linux are on the long-term roadmap.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Windows gets the most testing.&lt;/strong&gt; macOS and Linux work — a contributor shipped the cross-platform layer in PR #37 — but I develop on Windows, so that's where the edge cases get caught first.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;No rule editor UI.&lt;/strong&gt; You edit rules by hand. The IPC is ready (getRulesByCategory() and onRulesReloaded() already exist), the frontend isn't built yet.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Single machine.&lt;/strong&gt; No fleet management. No cloud console. Aegis is a local tool. It tells you what happened on this computer.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Monitoring, not prevention.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Will be added in future updates. But now, Aegis shows you what an agent did. It doesn't block it. If you're running OpenClaw in production, you need an isolated VM. This tool is a camera, not a lock.&lt;/p&gt;




&lt;h2&gt;
  
  
  Roadmap
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;v0.10.0-alpha  ← current

Next           Spawn hardening (child_process security)
               Rules UI (visual editor in the app)
               TypeScript migration — 9 remaining files

Later          UtilityProcess for scan loop
               Ring buffers + OOM hardening

Future         ML anomaly detection
               z-score deviation from baseline agent behavior

Long-term      ETW / eBPF kernel-level hooks
               Rust N-API modules for hot paths
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The ML layer is what I keep thinking about. Pattern-matching catches known bad behavior. But what about unknown bad behavior? An agent that usually reads five files per minute suddenly reading 500, that's a deviation you can catch with statistical methods, no rule required.&lt;/p&gt;

&lt;p&gt;Build a baseline, flag anomalies.&lt;/p&gt;




&lt;h2&gt;
  
  
  Try it:
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/antropos17/Aegis.git
&lt;span class="nb"&gt;cd &lt;/span&gt;Aegis
npm &lt;span class="nb"&gt;install
&lt;/span&gt;npm start
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Starts in demo mode with simulated agent traffic. Poke around.&lt;/p&gt;

&lt;p&gt;Or skip install: &lt;strong&gt;&lt;a href="https://aegis-demo-ten.vercel.app/" rel="noopener noreferrer"&gt;live web demo&lt;/a&gt;&lt;/strong&gt; — runs in the browser, no setup.&lt;/p&gt;




&lt;h2&gt;
  
  
  By the numbers:
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;Tests - 707 pass,0 fail&lt;br&gt;
Test files - 44&lt;br&gt;
Svelte components - 43&lt;br&gt;
Main process modules - 28 (23 core + 5 platform)&lt;br&gt;
Detection rules - 68&lt;br&gt;
Known agents - 107&lt;br&gt;
tsc errors - 0&lt;br&gt;
&lt;code&gt;any&lt;/code&gt; types - 0&lt;br&gt;
ESLint errors - 0&lt;br&gt;
Build - ~1.5s&lt;br&gt;
JS bundle (gzip) - 60 kB&lt;br&gt;
License - MIT&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  &lt;strong&gt;What I need&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Stars matter for open-source visibility. &lt;/p&gt;

&lt;p&gt;If this seems useful,please &lt;strong&gt;&lt;a href="https://github.com/antropos17/Aegis" rel="noopener noreferrer"&gt;STAR&lt;/a&gt;&lt;/strong&gt; the repo.&lt;/p&gt;

&lt;p&gt;Beyond that: install it, break it, file issues. There are &lt;strong&gt;&lt;a href="https://github.com/antropos17/Aegis/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22" rel="noopener noreferrer"&gt;some good-first-issues&lt;/a&gt;&lt;/strong&gt; if you want to contribute code. If you know an agent's risky patterns, write a detection rule, I'll review and merge.&lt;/p&gt;

&lt;p&gt;What agent behavior would you want to detect first? Curious what rules people would write.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/antropos17/Aegis" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt; · &lt;a href="https://aegis-demo-ten.vercel.app/" rel="noopener noreferrer"&gt;Demo&lt;/a&gt; · &lt;a href="https://aegisprotect.vercel.app/" rel="noopener noreferrer"&gt;Landing Page&lt;/a&gt;&lt;/p&gt;

</description>
      <category>security</category>
      <category>ai</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
