<?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: Ri Piao</title>
    <description>The latest articles on DEV Community by Ri Piao (@pr7426).</description>
    <link>https://dev.to/pr7426</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F99mvlsfu5tfj9m7ku25d.png</url>
      <title>DEV Community: Ri Piao</title>
      <link>https://dev.to/pr7426</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/pr7426"/>
    <language>en</language>
    <item>
      <title>HermesSec: Turning Open-Weight Gemma &amp; AST Triage into a $149 Freelance Security Audit Side Hustle</title>
      <dc:creator>Ri Piao</dc:creator>
      <pubDate>Wed, 14 Oct 2026 18:21:12 +0000</pubDate>
      <link>https://dev.to/pr7426/hermessec-turning-open-weight-gemma-ast-triage-into-a-149-freelance-security-audit-side-hustle-1h77</link>
      <guid>https://dev.to/pr7426/hermessec-turning-open-weight-gemma-ast-triage-into-a-149-freelance-security-audit-side-hustle-1h77</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/hacktoberfest-week2-2026-10-12"&gt;Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Built
&lt;/h2&gt;

&lt;p&gt;Indie SaaS founders, vibe-coders, and small dev agencies ship payment and authentication code at breakneck speed. They cannot afford a traditional $15,000 penetration test before launching, yet a single SQL injection (&lt;code&gt;CWE-89&lt;/code&gt;), hardcoded production secret (&lt;code&gt;CWE-798&lt;/code&gt;), or &lt;code&gt;shell=True&lt;/code&gt; command execution (&lt;code&gt;CWE-78&lt;/code&gt;) can wipe out their business overnight.&lt;/p&gt;

&lt;p&gt;On the flip side, freelance security practitioners want to offer affordable &lt;strong&gt;$149 Express Pre-Launch Code Audits&lt;/strong&gt;—but manually reviewing snippets, mapping CWE identifiers, and writing copy-pasteable remediation patches takes hours of unbilled effort.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;HermesSec&lt;/strong&gt; bridges this gap. Inspired by the &lt;strong&gt;Hermes / OpenClaw&lt;/strong&gt; multi-agent task decomposition workflow, it combines deterministic Python AST (Abstract Syntax Tree) pre-triage with &lt;strong&gt;Google Gemma&lt;/strong&gt; open-weight models, &lt;strong&gt;Backboard&lt;/strong&gt;'s stateful thread memory (&lt;code&gt;memory="Auto"&lt;/code&gt;), and &lt;strong&gt;Render&lt;/strong&gt; cloud hosting to generate line-accurate, client-ready security audit reports in seconds.&lt;/p&gt;

&lt;h2&gt;
  
  
  Demo
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Live App on Render&lt;/strong&gt;: &lt;a href="https://hermes-sec-audit.onrender.com/" rel="noopener noreferrer"&gt;https://hermes-sec-audit.onrender.com/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Try it live&lt;/strong&gt;: Click &lt;strong&gt;Sample 1 (SQLi + Secret)&lt;/strong&gt; or &lt;strong&gt;Sample 2 (RCE / Command Inj)&lt;/strong&gt;, or paste your own custom Python code—the AST engine + Gemma pipeline will dynamically detect the exact line numbers and generate a tailored patch!&lt;/li&gt;
&lt;/ul&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.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fi1yvq0nbv1ui1dgc4tox.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.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fi1yvq0nbv1ui1dgc4tox.png" alt=" " width="800" height="614"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Code
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub Repository&lt;/strong&gt;: &lt;a href="https://github.com/pr7426/hermes-sec-audit/tree/main" rel="noopener noreferrer"&gt;https://github.com/pr7426/hermes-sec-audit/tree/main&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Includes &lt;code&gt;app.py&lt;/code&gt; (FastAPI + AST Triage + Backboard &lt;code&gt;/api/threads/messages&lt;/code&gt; + Local Ollama &lt;code&gt;/api/chat&lt;/code&gt;), &lt;code&gt;Dockerfile&lt;/code&gt;, and &lt;code&gt;render.yaml&lt;/code&gt; Blueprint.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How I Built It
&lt;/h2&gt;

&lt;p&gt;HermesSec uses a three-stage sub-agent architecture designed for zero-hallucination reliability:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Sub-Agent 1 — Deterministic Python AST &amp;amp; Regex Triage&lt;/strong&gt;: Parses incoming source code into an Abstract Syntax Tree (&lt;code&gt;ast.walk&lt;/code&gt;) to pinpoint exact line numbers for dangerous sinks (&lt;code&gt;eval&lt;/code&gt;, &lt;code&gt;exec&lt;/code&gt;, &lt;code&gt;pickle.loads&lt;/code&gt;, &lt;code&gt;subprocess&lt;/code&gt; with &lt;code&gt;shell=True&lt;/code&gt;, raw SQL string interpolation, and hardcoded secrets).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sub-Agent 2 — Google Gemma Remediation Engine&lt;/strong&gt;: Feeds the structured AST findings into open-weight &lt;code&gt;gemma-2-9b-it&lt;/code&gt; (via Backboard or local Ollama &lt;code&gt;/api/chat&lt;/code&gt;) to synthesize drop-in secure refactoring code and executive risk summaries.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sub-Agent 3 — Backboard Stateful Memory &amp;amp; Model Benchmark&lt;/strong&gt;: Uses Backboard's &lt;code&gt;POST https://app.backboard.io/api/threads/messages&lt;/code&gt; endpoint with &lt;code&gt;X-API-Key&lt;/code&gt; and &lt;code&gt;memory="Auto"&lt;/code&gt; to retain recurring CWE context across audit threads and compare &lt;code&gt;google/gemma-2-9b-it&lt;/code&gt; against &lt;code&gt;qwen-2.5-coder-7b-instruct&lt;/code&gt; side-by-side.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Why Does Open Innovation Matter?
&lt;/h2&gt;

&lt;p&gt;A freelance code auditing business &lt;strong&gt;cannot&lt;/strong&gt; be built on closed commercial AI APIs for three practical reasons:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Client NDA &amp;amp; Source Code Privacy&lt;/strong&gt;: Paying clients will never allow proprietary authentication or checkout code to be sent to closed-source frontier providers that retain prompts for training. Because HermesSec supports open-weight &lt;strong&gt;Gemma&lt;/strong&gt; via local Ollama (&lt;code&gt;http://localhost:11434/api/chat&lt;/code&gt;) or controlled endpoints, sensitive client code stays completely private.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No False-Positive Safety Refusals on Security Code&lt;/strong&gt;: Closed commercial APIs frequently refuse to analyze legitimate SQL injection queries, XSS sinks, or command-injection snippets due to overly aggressive refusal guardrails. Open-weight models like &lt;strong&gt;Gemma&lt;/strong&gt; let security engineers inspect and patch real vulnerabilities without arbitrary blocks.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;99% Gross Margin Unit Economics&lt;/strong&gt;: Running a 9B open-weight model combined with local AST pre-filtering costs less than &lt;code&gt;$0.0003&lt;/code&gt; per audit, making a fixed-price &lt;strong&gt;$149 micro-audit&lt;/strong&gt; highly profitable from day one.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  My First User
&lt;/h2&gt;

&lt;p&gt;I put the live Render deployment in front of a fellow developer and content creator who launches web apps and social e-commerce tools.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;How it went&lt;/strong&gt;: They pasted a real backend utility script into HermesSec. Within 2 seconds, the tool flagged a hardcoded token and an unvalidated query line by exact line number, outputting the parameterized replacement code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Would they pay?&lt;/strong&gt;: They said paying a flat $99–$149 for a verified pre-launch security sign-off before opening public access is an easy "yes" compared to enterprise consulting rates.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;What they asked for next&lt;/strong&gt;: Automatic GitHub Pull Request webhook integration and downloadable PDF certificates they can show to their customers.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Prize Categories
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Best Use of Render&lt;/strong&gt;: Deployed the containerized FastAPI + multi-agent runtime on Render using a native &lt;code&gt;Dockerfile&lt;/code&gt; and &lt;code&gt;render.yaml&lt;/code&gt; Blueprint.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Best Use of Gemma&lt;/strong&gt;: Used Google's open-weight &lt;strong&gt;Gemma&lt;/strong&gt; (&lt;code&gt;gemma-2-9b-it&lt;/code&gt; / &lt;code&gt;gemma2:9b&lt;/code&gt;) as the primary vulnerability explanation and secure patch synthesis model.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Best Use of Backboard&lt;/strong&gt;: Integrated Backboard's &lt;code&gt;POST /api/threads/messages&lt;/code&gt; API with &lt;code&gt;X-API-Key&lt;/code&gt; and &lt;code&gt;memory="Auto"&lt;/code&gt; to maintain stateful audit memory and compare open-weight models (&lt;code&gt;gemma-2-9b-it&lt;/code&gt; vs &lt;code&gt;qwen-2.5-coder&lt;/code&gt;) through a single key.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>devchallenge</category>
      <category>hf26challenge</category>
      <category>opensource</category>
      <category>ai</category>
    </item>
  </channel>
</rss>
