<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Chris BJ</title>
    <description>The latest articles on DEV Community by Chris BJ (@chris_bj_97483cb5eded6c6c).</description>
    <link>https://dev.to/chris_bj_97483cb5eded6c6c</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4136731%2Ffaf17ebd-ac0b-4bb1-91e7-cfec3b75e47d.png</url>
      <title>DEV Community: Chris BJ</title>
      <link>https://dev.to/chris_bj_97483cb5eded6c6c</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/chris_bj_97483cb5eded6c6c"/>
    <language>en</language>
    <item>
      <title>Teaching Wazuh to watch Windows Defender</title>
      <dc:creator>Chris BJ</dc:creator>
      <pubDate>Tue, 22 Sep 2026 03:26:27 +0000</pubDate>
      <link>https://dev.to/chris_bj_97483cb5eded6c6c/teaching-wazuh-to-watch-windows-defender-12b2</link>
      <guid>https://dev.to/chris_bj_97483cb5eded6c6c/teaching-wazuh-to-watch-windows-defender-12b2</guid>
      <description>&lt;h1&gt;
  
  
  Teaching Wazuh to watch Windows Defender
&lt;/h1&gt;

&lt;h1&gt;
  
  
  Introduction
&lt;/h1&gt;

&lt;p&gt;Hello, my name is Christopher Brown Johnson, I am pursuing my CompTIA Security+ through the wonderful program Triple Ten. I have never studied anything within the field but over the last few months have learned a tremendous amount of knowledge within this field thanks to this program.&lt;/p&gt;

&lt;p&gt;For this sprint, I added a new log source to my SIEM: Windows Defender's own detection events from ad01, ingested directly into Wazuh using the agent's built-in event channel log collector. Before this, my deployment had no visibility into what Defender was catching on that endpoint; if malware got flagged, the SIEM would never know. I closed that gap, then ran three experiments to see how different types of Defender detections—a straightforward malware signature, a potentially unwanted application, and real-time behavioral analysis— actually show up (or don't) in Wazuh.&lt;/p&gt;

&lt;h1&gt;
  
  
  Setup
&lt;/h1&gt;

&lt;p&gt;&lt;strong&gt;The Modification&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The modification that I chose was configuring the Wazuh agent already running on ad01 to collect the Microsoft-Windows-Windows Defender/Operational event log channel natively (via a localfile entry using the event channel log format in ossec.conf), so that Windows Defender detections, specifically Event ID 1116, flow into Wazuh with full file path details. The baseline deployment had no native AV visibility at all, so this was about closing a real blind spot rather than adding a nice-to-have. This route also meant no separate Winlogbeat install (which at first I believed  was the correct route), no manual cert configuration, and no version matching against the Wazuh indexer. The agent already has a trusted, authenticated channel back to the manager, so this new log source just rides along on that. This was appealing to me due to the fact that identifying these paths would give greater light into where the harm is coming from.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Walkthrough&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;-First, confirmed the Wazuh agent was already running on ad01:&lt;br&gt;
Get-Service WazuhSvc&lt;br&gt;
-Then added a new localfile block to ossec.conf (backing up the original first): &lt;br&gt;
-Restarted the agent to pick up the config change:&lt;br&gt;
Restart-Service WazuhSvc&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7rnxivvkoqt7jvrpoz6r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7rnxivvkoqt7jvrpoz6r.png" alt=" " width="799" height="140"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F1omg9p0bp1eh1dcc4p1c.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F1omg9p0bp1eh1dcc4p1c.png" alt=" " width="537" height="265"&gt;&lt;/a&gt;&lt;br&gt;
![[Modification 1.png]]&lt;br&gt;
![[Modification 2.png]]&lt;/p&gt;

&lt;h1&gt;
  
  
  Experiment #1
&lt;/h1&gt;

&lt;p&gt;**&lt;/p&gt;

&lt;h3&gt;
  
  
  EICAR Standard Antivirus Test
&lt;/h3&gt;

&lt;p&gt;Why: Confirm the whole pipeline works end-to-end with the simplest possible detection before trusting more complex results in Experiments #2 and #3.&lt;/p&gt;

&lt;p&gt;How: Created the standard EICAR test string as a .txt file on ad01 with real-time protection enabled to trigger a baseline Defender detection.&lt;/p&gt;

&lt;p&gt;Expected Outcome: Event ID 1116 in the Microsoft-Windows-Windows Defender/Operational channel, mapped to Wazuh's built-in 0600-win-wdefender_rules.xml ruleset (~level 12). Specific fields expected: threatName = EICAR test file signature, severityName = Severe, detectionSource = Real-Time Protection, path = full path to EICAR.txt.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbe5wn26eo8zb7yk7a8sk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbe5wn26eo8zb7yk7a8sk.png" alt=" " width="800" height="310"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fdv4aoxd8sdy659yd42o0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fdv4aoxd8sdy659yd42o0.png" alt=" " width="800" height="342"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0p8krcncg2f8838ze2uh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0p8krcncg2f8838ze2uh.png" alt=" " width="800" height="520"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft7c95m28be59qhp7iaj3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft7c95m28be59qhp7iaj3.png" alt=" " width="800" height="569"&gt;&lt;/a&gt;&lt;br&gt;
![[EICAR TEST.png]]&lt;br&gt;
![[EICAR Test 3.png]]&lt;br&gt;
![[EICAR Test 3.5.png]]&lt;br&gt;
![[EICAR Test Wazuh.png]]&lt;/p&gt;

&lt;h1&gt;
  
  
  Experiment #2
&lt;/h1&gt;

&lt;p&gt;**&lt;/p&gt;

&lt;h3&gt;
  
  
  Potentially Unwanted Application (PUA) Detection
&lt;/h3&gt;

&lt;p&gt;Why: Test whether a lower-severity PUA flag is actually distinguishable from a full malware detection in Wazuh or whether it just looks identical to Experiment #1.&lt;/p&gt;

&lt;p&gt;How: Enabled PUA protection on ad01 (Set-MpPreference -PUAProtection Enabled) and ran Microsoft's official PUA demonstration file.&lt;/p&gt;

&lt;p&gt;Expected Outcome: Still Event ID 1116 (same as Experiment #1); the event ID alone shouldn't distinguish this from malware. The differentiator should be in the fields: category = PotentiallyUnwantedApplication/PUA (vs. Trojan/Virus), severityName = Low/Moderate (vs. Severe), and a correspondingly lower Wazuh rule level than the EICAR alert.&lt;/p&gt;

&lt;p&gt;When running this test, there were no notifications or anything that was found when looking through Defender or Wazuh. &lt;/p&gt;

&lt;h1&gt;
  
  
  Experiment #3
&lt;/h1&gt;

&lt;p&gt;&amp;nbsp;### &amp;nbsp;Behavior Monitoring Demonstration&lt;/p&gt;

&lt;p&gt;Why: Test a fundamentally different detection mechanism (behavior/heuristics vs. static signature) and see whether PowerShell-based execution logging offers a second, independent view of the same activity.&lt;/p&gt;

&lt;p&gt;How: Ran Microsoft's official Behavior Monitoring demonstration command via an elevated PowerShell session on ad01:&lt;/p&gt;

&lt;p&gt;powershell.exe -NoExit -Command "powershell.exe hidden 12154dfe-61a5-4357-ba5a-efecc45c34c4"&lt;/p&gt;

&lt;p&gt;Expected Outcome: Still Event ID 1116 from Defender, but with detectionSource = Behavior Monitoring (instead of Real-Time Protection) and threatName prefixed "Behavior:Win32/..." proving the detection engine changed even though the event schema didn't. Separately, if PowerShell Script Block Logging is enabled, expect Event ID 4104 in Microsoft-Windows-PowerShell/Operational with the raw command text as a second independent data point on the same activity.**&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fkyxaa0qhh28rrzfz50e9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fkyxaa0qhh28rrzfz50e9.png" alt=" " width="800" height="487"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq474ahd6c9l6g07u38u3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fq474ahd6c9l6g07u38u3.png" alt=" " width="800" height="177"&gt;&lt;/a&gt;&lt;br&gt;
![[Behavior Monitoring 1 3.png]]&lt;br&gt;
![[Behavior Monitoring 2.png]]&lt;/p&gt;

&lt;h1&gt;
  
  
  Conclusion
&lt;/h1&gt;

&lt;p&gt;What I found:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Experiment 1 (EICAR): Wazuh was able to identify that Defender had done its job and showed details of where the file path came from.&lt;/li&gt;
&lt;li&gt;Experiment 2 (PUA): I found that Defender had no communication with the PUA suggesting that it wasn't a notable threat. &lt;/li&gt;
&lt;li&gt;Experiment 3 (Behavior Monitoring): Wazuh was able to identify that Defender had done its job and showed details of where the file path came from. Even identifying that in this experiment Event ID 1116 wasn't the only ID detected.&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  Mistakes Made
&lt;/h1&gt;

&lt;p&gt;Modification 1&lt;br&gt;
    -There was no need in using winlogbeats, the only thing needed was to edit the already existing ossec.conf file&lt;br&gt;
     -Tried loading an entire logging system that was unnecessary&lt;/p&gt;

&lt;p&gt;Experiment 1 &lt;br&gt;
    -Did not use Power Shell at first and there were no hits in Wazuh &lt;br&gt;
     -Changed to powershell then wazuh got notified&lt;/p&gt;

&lt;p&gt;Experiment 2&lt;br&gt;
    -When trying to download &lt;a href="https://www.amtso.org/feature-settings-check-potentially-unwanted-applications/" rel="noopener noreferrer"&gt;https://www.amtso.org/feature-settings-check-potentially-unwanted-applications/&lt;/a&gt; nothing happened. &lt;/p&gt;

&lt;h1&gt;
  
  
  Advice on avoiding mistakes
&lt;/h1&gt;

&lt;p&gt;My best advice on how to avoid mistakes would be patience. While configuring the modification, there were a few times when I didn't recognize that I was too high in the line of code or the simple task of verifying that each space is the correct distance. ALWAYS double-check what you typed was the correct line.&lt;/p&gt;

&lt;h1&gt;
  
  
  The coolest thing I learned
&lt;/h1&gt;

&lt;p&gt;I learned that the amount of information that one can gain from exploring Wazuh is almost infinite. The fact that simply changing the ossec.conf file to recognize a specific set of information can allow you to gain knowledge of the threat, where it comes from, what was done to protect the system, and the ability to teach the system how to recognize these threats brings me so much insight on how enormous this CyberSecurity field truly is.&lt;/p&gt;

&lt;h1&gt;
  
  
  One piece of advice
&lt;/h1&gt;

&lt;p&gt;My one piece of advice that I will stress over and over again is to be patient, assess the situation, and make sure that you are double-checking all of your steps so you don't have to start over from the beginning. This is something that helped me once the wheels started to turn.&lt;/p&gt;

&lt;h1&gt;
  
  
  My favorite resource
&lt;/h1&gt;

&lt;p&gt;I am a big advocate of using Reddit, as well as DOT, which both guided me and gave me the information needed to complete this sprint.&lt;/p&gt;

&lt;h1&gt;
  
  
  Thank you (gratitudes)!
&lt;/h1&gt;

&lt;p&gt;I would like to thank Jean Forbe for helping me identify the issues in my plan, DOT for helping me organize the plan and have a well-rounded idea of how to create this blog, and I would like to thank every single instructor in the Triple Ten program who has checked my sprints and given me feedback to become a better analyst.&lt;/p&gt;

&lt;h1&gt;
  
  
  References
&lt;/h1&gt;

&lt;h1&gt;
  
  
  1.
&lt;/h1&gt;

&lt;p&gt;Wazuh. (n.d.). Windows Defender Logs Collection. &lt;a href="https://documentation.wazuh.com/current/user-manual/capabilities/malware-detection/win-defender-logs-collection.html" rel="noopener noreferrer"&gt;https://documentation.wazuh.com/current/user-manual/capabilities/malware-detection/win-defender-logs-collection.html&lt;/a&gt; Official Wazuh documentation covering the eventchannel log format used to add the Microsoft-Windows-Windows Defender/Operational channel directly to the agent's ossec.conf, including a sample alert used as a reference point for expected rule structure.&lt;/p&gt;

&lt;h1&gt;
  
  
  2.
&lt;/h1&gt;

&lt;p&gt;EICAR. (n.d.). Anti-Malware Testfile. &lt;a href="https://www.eicar.org/download-anti-malware-testfile/" rel="noopener noreferrer"&gt;https://www.eicar.org/download-anti-malware-testfile/&lt;/a&gt; The standard, harmless test string recognized by virtually all antivirus engines as "malware," used to trigger a baseline Defender detection without using real malicious code.&lt;/p&gt;

&lt;h1&gt;
  
  
  3.
&lt;/h1&gt;

&lt;p&gt;Microsoft. (n.d.). Microsoft Defender for Endpoint — Demonstration Scenarios. &lt;a href="https://learn.microsoft.com/en-us/defender-endpoint/defender-endpoint-demonstrations" rel="noopener noreferrer"&gt;https://learn.microsoft.com/en-us/defender-endpoint/defender-endpoint-demonstrations&lt;/a&gt; Index page of official Microsoft demonstration scenarios, used to select the PUA and Behavior Monitoring demonstrations for Experiments 2 and 3.&lt;/p&gt;

&lt;h1&gt;
  
  
  4.
&lt;/h1&gt;

&lt;p&gt;Microsoft. (n.d.). Behavior Monitoring Demonstration. &lt;a href="https://learn.microsoft.com/en-us/defender-endpoint/demonstration-behavior-monitoring" rel="noopener noreferrer"&gt;https://learn.microsoft.com/en-us/defender-endpoint/demonstration-behavior-monitoring&lt;/a&gt; Official walkthrough with the specific PowerShell command used to simulate behavior-based detection in Experiment 3.&lt;/p&gt;

</description>
      <category>cybersecurity</category>
      <category>monitoring</category>
      <category>security</category>
    </item>
  </channel>
</rss>
