<?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:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Bayu Sangkaya on Medium]]></title>
        <description><![CDATA[Stories by Bayu Sangkaya on Medium]]></description>
        <link>https://medium.com/@bayusangkaya?source=rss-f41e1b25314b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*WVGrdYcOgYAJ3SgC</url>
            <title>Stories by Bayu Sangkaya on Medium</title>
            <link>https://medium.com/@bayusangkaya?source=rss-f41e1b25314b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 16:00:50 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@bayusangkaya/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Detecting PHP2Shell from Real Attack Telemetry]]></title>
            <link>https://medium.com/@bayusangkaya/detecting-php2shell-from-real-attack-telemetry-d52a4334c3a5?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/d52a4334c3a5</guid>
            <category><![CDATA[wazuh]]></category>
            <category><![CDATA[detection-engineering]]></category>
            <category><![CDATA[php2shell]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Fri, 23 Oct 2026 17:14:28 GMT</pubDate>
            <atom:updated>2026-10-23T17:14:28.997Z</atom:updated>
            <content:encoded><![CDATA[<h3>How CVE-2026–109618 / CVE-2026–109619 look in your Apache and PHP logs, and how to catch them with Wazuh</h3><p><em>This article is purely defensive. It reconstructs the log trail of a PHP2Shell attack to build detection. It contains no exploit code, offsets, or weaponization steps. All testing was done on an isolated lab inside Cybershield.id’s environment.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FgHAxlzaJnkSjukcwGpNfA.png" /><figcaption>The POC of the CVE</figcaption></figure><p>When Wiz, OpenAI, and Calif disclosed PHP2Shell — two memory-safety vulnerabilities in the PHP runtime (CVE-2026–109618 and CVE-2026–109619, CWE-824, CVSS 9.2), the scary part wasn’t just that they reach pre-authentication remote code execution. It was that the flaw lives in PHP itself, not in application code, so even an endpoint that merely echoes “OK” is exposed.</p><p>The good news for defenders: a successful exploit is noisy. It leaves a rich, layered trail in standard logs. You never need to “see” the RCE to catch the attempt. This post dissects one real run of a public PoC against my lab and maps every log artifact to a Wazuh detection rule.</p><h3>Why you detect the trail, not the exploit</h3><p>PHP2Shell weaponization is probabilistic. Triggering the bug is easy; turning it into code execution requires landing attacker-shaped data into freed memory on the same worker at the right moment. Most attempts just crash a worker; occasionally one lands. Because the final step has no fixed byte signature, detection targets the preconditions (triggers) and the effects (crashes, memory disclosure) instead.</p><h3>The lab</h3><ul><li>Image: php:8.4-apache (Debian Bookworm) via Docker</li><li>PHP 8.4.26, Apache 2.4.69 (prefork), memory_limit = 8M (image default)</li><li>Target: <a href="http://10.10.1.6:8080/index.php">http://10.10.1.6:8080/index.php</a></li><li>Attacker: 172.18.151.246 (Docker network)</li><li>Result: PRE-AUTH RCE CONFIRMED, uid=33(www-data)</li></ul><p>The exploit ran id, wrote the output to a file, then retrieved it via GET /p1, returning:</p><pre>uid=33(www-data) gid=33(www-data) groups=33(www-data)</pre><h3>The attack, as the logs saw it</h3><p>The entire chain unfolded in about 37 seconds.</p><pre>15:22:13  POST /index.php 200 4268   -&gt; initial burst<br>15:22:13  [php:warn] Cannot modify header information - headers already sent<br>                     in /var/www/html/index.php on line 112 (and 113)<br>15:22:13  POST /index.php 200 693<br>15:22:14  [php:warn] PHP Request Startup: Input variables exceeded 1000.<br>                     To increase the limit change max_input_vars in php.ini<br>15:22:14  [php:warn] PHP Request Startup: Session cookie cannot be sent after<br>                     headers have already been sent<br>15:22:14  [php:error] PHP Fatal error: Allowed memory size of 8388608 bytes<br>                     exhausted (tried to allocate 1589248 bytes) in Unknown on line 0<br>15:22:14  zend_mm_heap corrupted<br>15:22:18  [core:notice] AH00051: child pid 100 exit signal Abort (6),<br>                     possible coredump in /etc/apache2<br>15:22:21  [php:error] [client 172.18.151.246:60739] Allowed memory size of 8388608<br>                     bytes exhausted (tried to allocate 2098791 bytes) in Unknown on line 0<br>15:22:26  [core:notice] AH00051: child pid 101 exit signal Segmentation fault (11),<br>                     possible coredump in /etc/apache2<br>15:22:27  GET /p1 200 275   -&gt; command output retrieval (RCE proof)<br>15:22:42  GET /p1 200 256 &quot;curl/8.7.1&quot;<br>15:22:50  GET /p1 200 312 &quot;Mozilla/5.0 ... Firefox/158.0&quot;</pre><p>Read it in order and the shape becomes obvious:</p><ol><li>A burst of POST /index.php within seconds, the attacker rotates workers to hit the same process with a crafted body.</li><li>“Input variables exceeded 1000”, the body carries more than 1000 POST fields, a side effect of memory grooming, and a precursor that rarely appears in normal traffic.</li><li>“Cannot modify header information” and “Session cookie cannot be sent”, output forced out before headers, consistent with session/output manipulation.</li><li>An OOM at exactly 8388608 bytes (8M), the attacker fingerprinted memory_limit=8M and deliberately exhausted it to leave a stale pointer behind.</li><li>zend_mm_heap corrupted, the single most specific indicator. The Zend heap manager detected corruption. You almost never see this in a healthy app.</li><li>The worker dies twice, two different ways: exit signal Abort (6), SIGABRT from the heap-corruption abort, then Segmentation fault (11). A rule that only looks for segfaults will miss the SIGABRT path entirely.</li><li>GET /p1, a short, unfamiliar path that returns command output. This is the post-exploitation tell: the attacker retrieving the result.</li></ol><p>None of these lines is the RCE. Together, in a tight window on one host, they are unmistakable.</p><h3>The three signals most rules miss</h3><p>If you already wrote PHP2Shell detection from the advisory alone, real telemetry adds three artifacts you probably do not have yet:</p><pre>zend_mm_heap corrupted<br>AH00051: child pid &lt;N&gt; exit signal Abort (6)<br>PHP Request Startup: Input variables exceeded 1000</pre><ul><li>zend_mm_heap corrupted is the strongest standalone marker, raise it to a high severity with almost no false positives.</li><li>exit signal Abort (6) extends worker-crash detection beyond segfault(11). This PoC killed its first worker with SIGABRT, not a segfault.</li><li>Input variables exceeded 1000 is a cheap precursor that sharpens confidence when correlated with the OOM and the crash.</li></ul><p>One more detail worth noting: the fatal error reads “in Unknown on line 0”, not a real file path. That is because it fires in an internal runtime phase, not in application code , exactly what you expect from a flaw in the PHP runtime itself.</p><h3>Wazuh decoders and rules</h3><p>The idea is to detect from error logs. Anchor the decoders on body tokens so they work regardless of the log header (native PHP format, Apache mod_php, or journald).</p><p>Decoders (excerpt):</p><pre>&lt;!-- OOM, with srcip pulled from the mod_php &quot;[client IP:port]&quot; field --&gt;<br>&lt;decoder name=&quot;php2shell-oom&quot;&gt;<br>  &lt;prematch&gt;Allowed memory size of &lt;/prematch&gt;<br>&lt;/decoder&gt;<br>&lt;decoder name=&quot;php2shell-oom&quot;&gt;<br>  &lt;parent&gt;php2shell-oom&lt;/parent&gt;<br>  &lt;regex&gt;Allowed memory size of (\d+) bytes exhausted&lt;/regex&gt;<br>  &lt;order&gt;php_mem_limit&lt;/order&gt;<br>&lt;/decoder&gt;<br>&lt;decoder name=&quot;php2shell-oom&quot;&gt;<br>  &lt;parent&gt;php2shell-oom&lt;/parent&gt;<br>  &lt;regex&gt;[client (\d+.\d+.\d+.\d+):\d+]&lt;/regex&gt;<br>  &lt;order&gt;srcip&lt;/order&gt;<br>&lt;/decoder&gt;</pre><pre>&lt;!-- Strongest single signal --&gt;<br>&lt;decoder name=&quot;php2shell-heap&quot;&gt;<br>  &lt;prematch&gt;zend_mm_heap corrupted&lt;/prematch&gt;<br>&lt;/decoder&gt;</pre><pre>&lt;!-- Catch BOTH Segmentation fault (11) and Abort (6) --&gt;<br>&lt;decoder name=&quot;php2shell-worker-exit&quot;&gt;<br>  &lt;prematch&gt;exit signal &lt;/prematch&gt;<br>&lt;/decoder&gt;<br>&lt;decoder name=&quot;php2shell-worker-exit&quot;&gt;<br>  &lt;parent&gt;php2shell-worker-exit&lt;/parent&gt;<br>  &lt;regex&gt;child pid (\d+) exit signal&lt;/regex&gt;<br>  &lt;order&gt;proc_pid&lt;/order&gt;<br>&lt;/decoder&gt;</pre><p>Rules (excerpt):</p><pre>&lt;!-- zend_mm_heap corrupted: very strong --&gt;<br>&lt;rule id=&quot;100222&quot; level=&quot;12&quot;&gt;<br>  &lt;decoded_as&gt;php2shell-heap&lt;/decoded_as&gt;<br>  &lt;description&gt;PHP2Shell: zend_mm_heap corrupted - heap corruption (very strong indicator)&lt;/description&gt;<br>  &lt;mitre&gt;&lt;id&gt;T1190&lt;/id&gt;&lt;/mitre&gt;<br>  &lt;group&gt;php2shell,exploit_attempt,&lt;/group&gt;<br>&lt;/rule&gt;</pre><pre>&lt;!-- Worker killed by SIGABRT (the path a segfault-only rule misses) --&gt;<br>&lt;rule id=&quot;100212&quot; level=&quot;6&quot;&gt;<br>  &lt;if_sid&gt;100210&lt;/if_sid&gt;<br>  &lt;match&gt;Abort&lt;/match&gt;<br>  &lt;description&gt;Apache worker killed by SIGABRT - heap corruption abort (possible PHP2Shell)&lt;/description&gt;<br>  &lt;mitre&gt;&lt;id&gt;T1190&lt;/id&gt;&lt;/mitre&gt;<br>  &lt;group&gt;php2shell,segfault,php2shell_segv,&lt;/group&gt;<br>&lt;/rule&gt;</pre><pre>&lt;!-- The key correlation: OOM followed by a worker crash on the same host --&gt;<br>&lt;rule id=&quot;100230&quot; level=&quot;10&quot; timeframe=&quot;120&quot;&gt;<br>  &lt;if_sid&gt;100218&lt;/if_sid&gt;<br>  &lt;if_matched_sid&gt;100201&lt;/if_matched_sid&gt;<br>  &lt;description&gt;PHP2Shell: memory exhaustion followed by worker crash on same host - likely exploitation attempt&lt;/description&gt;<br>  &lt;mitre&gt;&lt;id&gt;T1190&lt;/id&gt;&lt;/mitre&gt;<br>  &lt;group&gt;php2shell,exploit_attempt,&lt;/group&gt;<br>&lt;/rule&gt;</pre><p>The detection that matters is not any single rule, it is the correlation: OOM, then a worker crash (Abort or Segfault), on the same host, within a short window. In this telemetry the gap was 4 to 12 seconds.</p><h3>Docker vs bare-metal: are the logs the same?</h3><p>Yes, the log lines are identical in content, because PHP and Apache generate them inside the container. Only collection and context differ:</p><ul><li>Log destination: the official php:apache image sends logs to the container’s stdout/stderr (/proc/self/fd/1 and /dev/stderr), not to /var/log/apache2/<em>. So collect them with docker logs, a logging driver, or by reading the host json log at /var/lib/docker/containers/</em>/*-json.log.</li><li>Client IP: inside Docker it is the network IP (172.18.x). Behind a real reverse proxy or CDN, the “[client …]” field is the proxy/CDN IP unless you configure mod_remoteip (RemoteIPHeader X-Forwarded-For). Source-based correlation must use the X-Forwarded-For client, not the raw remote IP.</li><li>PID 1 is the Apache master in the container (vs systemd-managed on bare metal). Cosmetic, the signals are the same.</li></ul><h3>A word on auto-blocking</h3><p>The attacker IP does appear in the mod_php error lines ([client 172.18.151.246:60739]), which makes active response tempting. Do it carefully.</p><ul><li>Behind a CDN, that “[client …]” IP is the CDN edge, not the attacker. Dropping it at the host firewall takes the whole site offline. Either configure mod_remoteip so the real client IP is logged, or push the block to the CDN/WAF via your SOAR instead.</li><li>OOM and segfaults can be benign. Trigger active response only on a strong, IP-bearing signal (for example, repeated OOM from the same source in a short window), never on a single event.</li><li>Use a timed block, keep a safelist of internal and CDN ranges, and run alert-only first while you tune.</li></ul><h3>Mitigation</h3><p>Patching PHP is the real fix. When framework compatibility locks the version, the temporary php.ini measures from the advisory help:</p><pre>session.upload_progress.enabled = 0 #closes three of the five demonstrated techniques <br>opcache.enable = 0 #test for performance impact first</pre><p>but they do not close every path, so active detection stays mandatory as compensation.</p><h3>Takeaway</h3><p>PHP2Shell is a runtime memory-corruption bug, and runtime memory corruption is loud. OOM, heap-corruption aborts, segfaults, an input-vars precursor, and result retrieval all land in logs you already collect. Build the correlation, add the three signals most people miss, and you will see the attempt long before you ever see a shell.</p><p><em>If this helped, the full Wazuh decoders, rules, and Suricata signatures are things I’m happy to share, still work in progress by the way. And if you need professional Cybersecurity Services, connect with us at Cybershield.id. Stay defensive.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d52a4334c3a5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Under the Hood: Tuning the Blind Spots of a High-Volume Wazuh Deployment]]></title>
            <link>https://medium.com/@bayusangkaya/under-the-hood-tuning-the-blind-spots-of-a-high-volume-wazuh-deployment-442b3c83e8b9?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/442b3c83e8b9</guid>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Mon, 24 Aug 2026 05:39:44 GMT</pubDate>
            <atom:updated>2026-08-24T05:39:44.683Z</atom:updated>
            <content:encoded><![CDATA[<p>Wazuh is a powerful platform. Out of the box, it delivers host-based intrusion detection, file integrity monitoring, vulnerability assessment, and log analysis, all in one open-source stack. For a deployment with a hundred or two hundred agents, the default configuration handles the load without complaint.</p><p>But power does not mean invincibility. The moment your environment grows, thousands of agents, dozens of network devices generating tens of thousands of events per second, Wazuh starts to struggle. Alerts arrive late. Queues fill up. Files grow faster than the system can consume them. The dashboard shows data from hours ago, not minutes ago.</p><p>The instinct is to blame capacity: “we need more CPU, more RAM, more disk.” Sometimes that is true. But more often, the real problem is not hardware, it is configuration. Wazuh ships with conservative defaults designed for broad compatibility, not for high-volume production. These defaults create blind spots: bottlenecks that are invisible during normal operation and catastrophic under load.</p><p>This article walks through four of those blind spots, the “under the hood” tuning areas that are rarely discussed but make the difference between a Wazuh deployment that keeps up and one that falls behind.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MgcFkBis-YAXZtdEec4bXw.png" /></figure><h4><strong>The Agent: A 1000 EPS Ceiling Nobody Mentions</strong></h4><p>Before any event reaches the Wazuh Manager for analysis, it must pass through the agent’s internal buffer. This buffer has a configurable throughput limit: 5<strong>00 events per second (EPS)</strong> by default.</p><pre>&lt;!-- Agent-side ossec.conf --&gt;<br>&lt;client_buffer&gt;<br>  &lt;disabled&gt;no&lt;/disabled&gt;<br>  &lt;queue_size&gt;5000&lt;/queue_size&gt;<br>  &lt;events_per_second&gt;500&lt;/events_per_second&gt;<br>&lt;/client_buffer&gt;</pre><p>And in case not enough, it can be extended to</p><pre>&lt;!-- Agent-side ossec.conf --&gt;<br>&lt;client_buffer&gt;<br>  &lt;disabled&gt;no&lt;/disabled&gt;<br>  &lt;queue_size&gt;100000&lt;/queue_size&gt;<br>  &lt;events_per_second&gt;1000&lt;/events_per_second&gt;<br>&lt;/client_buffer&gt;</pre><p>For endpoint agents (Linux servers, Windows workstations), 1000 EPS is generous. Most hosts generate a few dozen EPS under normal conditions, spiking to a few hundred during FIM scans or syscollector runs. The limit is never reached.</p><p>The problem surfaces when you use Wazuh Agents to ingest <strong>network device logs</strong> via &lt;localfile&gt;. In a common architecture, syslog from firewalls, WAFs, and other appliances lands on a collector VM, and a Wazuh Agent on that VM reads the log files and forwards them to the Manager:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/696/1*2ooez05m1lB0J-opzBB2wA.png" /></figure><p>A single Firewall or WAF device can generate 3,000–5,000+ EPS during peak traffic. Multiple devices behind one collector pushes it even higher. When the event rate exceeds the events_per_second limit, events are <strong>silently dropped</strong> at the agent leve, before they ever reach the Manager. There is no alert, no log entry, no indication that security-relevant data is being lost.</p><p><strong>Detecting the Problem</strong></p><p>On the agent:</p><pre>cat /var/ossec/var/run/wazuh-agentd.state</pre><p>Track msg_count and msg_sent over time. A growing gap means the buffer is overflowing.</p><p><strong>Fix: Redesign the Data Path</strong></p><p>Raising events_per_second beyond 1000 is possible but merely pushes the bottleneck downstream to the Manager. The more sustainable approach is to <strong>split the data path</strong> at the rsyslog level:</p><pre>Device → rsyslog → SPLIT:<br>    ├─ raw.log        (ALL traffic)       → Log Shipper → Indexer (searchable, no rules)<br>    └─ violations.log (blocked/alerted)   → Wazuh Agent → Manager (full rule matching)</pre><p>The insight: for high-volume devices, the majority of events are “allowed” traffic. Important for forensics, but not for real-time detection. By filtering at rsyslog, only the security-relevant subset flows through the agent’s client_buffer, keeping EPS well within limits.</p><p>The raw stream bypasses Wazuh entirely, a tool like Vector or Logstash ships it directly to the Indexer for searchability without consuming agent buffer or Manager CPU.</p><p><strong>The trade-off is explicit:</strong> raw-path traffic does not trigger Wazuh rules. Attack patterns hidden in allowed traffic will only be visible through manual investigation, not automated alerting. This is a conscious architectural decision, not a limitation.</p><p><strong>When you do NOT need this:</strong> if a device generates less than ~500 EPS, the standard agent path handles it comfortably. Split architecture adds operational complexity, only adopt it when the EPS math demands it.</p><h4><strong>The Analysis Engine: Threads That Nobody Configures</strong></h4><p>The analysis daemon (wazuh-analysisd) is the heart of Wazuh. Every event from every agent passes through it: decoded, matched against rules, and written to alerts.json if a rule fires.</p><p>Internally, analysisd is a multithreaded pipeline:</p><pre>Event arrives → Decoder queue (per type) → Decoder thread → Rule matching queue<br>    → Rule matching thread → Writer thread → alerts.json / archives.json</pre><p>There are separate decoder queues for syscheck (FIM), syscollector (inventory), rootcheck, hostinfo, and general events. Each queue has its own pool of threads. When a queue is full, incoming events are <strong>dropped </strong>again, silently.</p><p><strong>Default Behavior</strong></p><p>The thread count for each queue is controlled in /var/ossec/etc/internal_options.conf via parameters like analysisd.event_threads and analysisd.rule_matching_threads. The default value for all of them is 0, which means &quot;auto-detect based on CPU cores.&quot;</p><p>In theory, this is smart — a 4-core machine gets 4 threads per queue, an 8-core machine gets 8. In practice, on virtualized infrastructure where vCPU counts may not reflect actual available compute, the auto-detection can produce thread counts that are inadequate for high-volume workloads. We observed this firsthand in production: analysisd consuming 275–507% CPU while events were being dropped because the queues could not drain fast enough.</p><p><strong>Diagnosing the Bottleneck</strong></p><p>Analysisd exposes its internal state in a file that updates every 5 seconds:</p><pre>cat /var/ossec/var/run/wazuh-analysisd.state</pre><p>The critical fields:</p><pre>events_received=&#39;285012&#39;<br>events_processed=&#39;279843&#39;<br>events_dropped=&#39;5169&#39;             # &lt;-- This should be zero<br>event_queue_usage=&#39;0.87&#39;          # &lt;-- Approaching 1.0 = queue full, drops imminent<br>rule_matching_queue_usage=&#39;0.72&#39;</pre><p>If event_queue_usage approaches 1.00 or events_dropped is climbing, the decoder threads cannot keep up with the incoming event rate.</p><p><strong>Applying the Fix</strong></p><p>Use /var/ossec/etc/local_internal_options.conf,not internal_options.conf, which gets overwritten on upgrades:</p><pre># /var/ossec/etc/local_internal_options.conf<br><br>analysisd.event_threads=4<br>analysisd.rule_matching_threads=4<br>analysisd.syscheck_threads=2<br>analysisd.syscollector_threads=2<br>analysisd.rootcheck_threads=1<br>analysisd.hostinfo_threads=1</pre><p>Restart the Manager:</p><pre>sudo systemctl restart wazuh-manager</pre><p>Monitor analysisd.state again. You should see event_queue_usage drop and events_dropped stabilize at zero.</p><p><strong>Sizing Guidance</strong></p><p>Thread count should never exceed physical core count. Remember that analysisd shares the CPU with wazuh-remoted, wazuh-modulesd, wazuh-db, Filebeat, and often additional agents (EDR, observability tools). Overcommitting threads guarantees context-switch overhead that negates the benefit.</p><p>A practical starting point:</p><ul><li><strong>8-core manager:</strong> event_threads=4, rule_matching_threads=4</li><li><strong>12–16 core manager:</strong> event_threads=6–8, rule_matching_threads=6–8</li></ul><p>On a multi-node manager cluster, every node needs the same tuning — not just the master. Each node processes events independently from the agents connected to it.</p><h4><strong>Filebeat: The 9x Throughput You Are Leaving on the Table</strong></h4><p>This is the single most impactful discovery in our tuning journey, and the most frustrating, because the fix takes two minutes.</p><p><strong>The Scenario</strong></p><p>All three manager nodes showed alerts.json growing by gigabytes per hour. Analysisd was decoding events as fast as it could. But the Indexer showed alerts arriving <strong>hours</strong> late. We checked the Indexer (not overloaded), checked analysisd (drops were fixed). The culprit was not where we expected.</p><p>Filebeat sits between the Manager and the Indexer. It reads alerts.json and ships documents to the Indexer via bulk API calls over HTTPS. The default Wazuh Filebeat configuration does not explicitly set worker or bulk_max_size, so Filebeat falls back to built-in defaults:</p><ul><li><strong>worker: 1</strong> &gt; one connection to the Indexer.</li><li><strong>bulk_max_size: 50</strong> &gt; 50documents per bulk request.</li></ul><p>With a single worker, the cycle is sequential:</p><pre>Read 50 docs → TLS handshake → Send → Wait for ACK → Advance offset → Repeat</pre><p>Each round trip takes 10–50 ms. At 50 docs per cycle and ~20 ms per round trip, maximum throughput is roughly <strong>2,500 docs/second</strong>. Meanwhile, a busy Manager can produce 10,000–50,000+ events per second into alerts.json.</p><p>The bottleneck is not CPU, Filebeat sits near 0% CPU utilization. It is <strong>network-round-trip-bound</strong>: the worker thread spends most of its time waiting, not processing. This is invisible unless you know to measure it.</p><p><strong>The Math That Does Not Lie</strong></p><p>On one of our managers:</p><pre>alerts.json growth rate:    ~38 MB/min<br>Filebeat indexing rate:     ~6.5 MB/min<br>Accumulated backlog:        97 GB<br>Estimated time to clear:    ~24 days</pre><p>With the default configuration, Filebeat would never catch up. Ever.</p><p><strong>The Fix</strong></p><p>Edit /etc/filebeat/filebeat.yml on every manager node:</p><pre>output.elasticsearch:<br>  hosts:<br>    - &quot;https://indexer-node1:9200&quot;<br>    - &quot;https://indexer-node2:9200&quot;<br>    - &quot;https://indexer-node3:9200&quot;<br>  worker: 4<br>  bulk_max_size: 500<br>  compression_level: 3</pre><p>Restart:</p><pre>sudo systemctl restart filebeat</pre><p>Result: <strong>approximately 9–10x throughput increase.</strong> Backlogs projected to take 24 days were cleared in hours.</p><p><strong>Why These Values</strong></p><p><strong>worker: 4</strong> opens four parallel HTTPS connections. Filebeat round-robins across the hosts list, so 4 workers across 3 Indexer nodes means near-constant utilization. Going higher has diminishing returns, the Indexer&#39;s write thread pool becomes the next bottleneck beyond 4–6 workers.</p><p><strong>bulk_max_size: 500</strong> increases the batch from 50 to 500 documents, amortizing per-request overhead (TLS, HTTP framing, pipeline invocation) across 10x more documents. Memory cost is negligible: ~1.5 MB per worker at average alert sizes.</p><p><strong>compression_level: 3</strong> enables gzip on the bulk payload. Level 3 balances compression ratio against CPU cost. Effective when alerts contain verbose JSON (Network device CEF events can be 2–4 KB each).</p><h4><strong>The Indexer: JVM Heap, Replicas, and the 30-Processor Pipeline</strong></h4><p>A properly tuned Filebeat can now push thousands of documents per second. If the Indexer cannot absorb them, the symptoms cascade backward: write queue saturation → bulk timeouts → Filebeat backoff → alerts.json backlog → stale alerts. Everything is only as fast as its slowest stage.</p><p><strong>JVM Heap: The Three Rules</strong></p><p>The Wazuh Indexer runs on the JVM (it is OpenSearch under the hood). Heap is configured in /etc/wazuh-indexer/jvm.options:</p><pre>-Xms1g<br>-Xmx1g</pre><p>The default is often 1 GB or 4 GB. For high-volume deployments, this is insufficient. Three rules govern sizing:</p><p><strong>Rule 1: Allocate 50% of total RAM to heap.</strong> The other 50% is equally critical, the OS uses it for filesystem page cache, which keeps Lucene segment files in memory. Starving either heap or page cache degrades performance.</p><p><strong>Rule 2: Set </strong><strong>-Xms and </strong><strong>-Xmx to the same value.</strong> Different values force runtime heap resizing, causing stop-the-world GC pauses.</p><p><strong>Rule 3: Never exceed ~30–31 GB.</strong> Above this threshold, the JVM disables compressed ordinary object pointers (compressed oops), increasing per-object memory by ~40–50%. A 31 GB heap is effectively larger than a 40 GB heap.</p><p>Practical sizing:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1QFReAJ_XQB7OGhxawGL9A.png" /></figure><p>Monitor heap after changes:</p><pre>GET _nodes/stats/jvm?filter_path=nodes.*.jvm.mem</pre><p>heap_used_percent should fluctuate between 30–75%. Consistently above 85% means the heap is too small. Frequent [gc][old] entries in /var/log/wazuh-indexer/wazuh-cluster.log with durations over 500 ms confirm heap pressure.</p><p><strong>Replicas: The Silent Write Amplifier</strong></p><p>The default Wazuh template includes:</p><pre>&quot;auto_expand_replicas&quot;: &quot;0-1&quot;</pre><p>This silently maintains one replica shard for every primary, <strong>overriding</strong> any manual number_of_replicas: 0 setting. You can set replicas to zero a hundred times, the template restores it on the next evaluation cycle.</p><p>With replicas enabled, every write follows this path:</p><pre>Bulk request → Write to primary → Synchronous forward to replica →<br>Wait for replica ACK → Respond to Filebeat</pre><p>If the node holding the replica is under pressure, the primary write blocks waiting for the ACK. A single slow node can stall writes across the entire cluster, even writes to primaries on healthy nodes. In our environment, this cascading pattern caused total write cessation across all three managers.</p><p><strong>The fix:</strong></p><pre>PUT _template/wazuh<br>{<br>  &quot;settings&quot;: {<br>    &quot;index.auto_expand_replicas&quot;: false,<br>    &quot;index.number_of_replicas&quot;: 0<br>  }<br>}</pre><pre>PUT wazuh-alerts-*,wazuh-archives-*/_settings<br>{<br>  &quot;index.auto_expand_replicas&quot;: false,<br>  &quot;index.number_of_replicas&quot;: 0<br>}</pre><p>In deployments where all Indexer nodes share the same datacenter, replicas provide minimal availability benefit at the cost of doubling write load. Use snapshots for data protection, not replicas.</p><p><strong>The Ingest Pipeline Nobody Audits</strong></p><p>Every document Filebeat sends passes through an ingest pipeline on the Indexer side: filebeat-7.10.2-wazuh-alerts-pipeline. Inspect it:</p><pre>GET _ingest/pipeline/filebeat-7.10.2-wazuh-alerts-pipeline</pre><p>The default pipeline can contain <strong>30+ processors</strong>, including 8 geoip lookups for AWS, GCP, Azure, Office365, MS-Graph services (your deployment may not use), 2 set processors for cloud-specific fields, and 13 individual remove processors that could be consolidated into one.</p><p>At 10,000 documents per second, 30 processors per document means <strong>300,000 processor invocations per second</strong> on the Indexer. Each geoip lookup queries a database. Each individual remove processor parses the document structure.</p><p>In our deployment, we simplified the pipeline from 30 processors to 6:</p><pre>PUT _ingest/pipeline/filebeat-7.10.2-wazuh-alerts-pipeline<br>{<br>  &quot;description&quot;: &quot;Wazuh alerts pipeline - optimized&quot;,<br>  &quot;processors&quot;: [<br>    { &quot;json&quot;: { &quot;field&quot;: &quot;message&quot;, &quot;add_to_root&quot;: true } },<br>    { &quot;date&quot;: { &quot;field&quot;: &quot;timestamp&quot;, &quot;target_field&quot;: &quot;@timestamp&quot;,<br>                &quot;formats&quot;: [&quot;ISO8601&quot;] } },<br>    { &quot;date_index_name&quot;: { &quot;field&quot;: &quot;timestamp&quot;, &quot;date_rounding&quot;: &quot;d&quot;,<br>                           &quot;index_name_prefix&quot;: &quot;{{fields.index_prefix}}&quot;,<br>                           &quot;index_name_format&quot;: &quot;yyyy.MM.dd&quot; } },<br>    { &quot;remove&quot;: { &quot;field&quot;: [&quot;message&quot;,&quot;ecs&quot;,&quot;beat&quot;,&quot;input_type&quot;,&quot;tags&quot;,<br>                             &quot;count&quot;,&quot;@version&quot;,&quot;log&quot;,&quot;offset&quot;,&quot;type&quot;,<br>                             &quot;host&quot;,&quot;fields&quot;,&quot;event&quot;,&quot;fileset&quot;,&quot;service&quot;],<br>                  &quot;ignore_missing&quot;: true, &quot;ignore_failure&quot;: true } }<br>  ],<br>  &quot;on_failure&quot;: [{ &quot;drop&quot;: {} }]<br>}</pre><p>The pipeline update takes effect immediately, no Filebeat restart needed. If you use device-specific index routing (e.g., FortiGate alerts to wazuh-alerts-fortigate-*), add conditional date_index_name processors between the generic routing and the remove processor.</p><p><strong>Monitoring Write Pressure</strong></p><p>The earliest indicator of Indexer saturation:</p><pre>GET _cat/thread_pool/write?v&amp;h=node_name,active,queue,rejected,completed</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kd0RZJSFVxMCV4kbjll2WA.png" /></figure><p>One common misconception: changing which Indexer node Filebeat connects to does not solve write pressure. Indexing happens at the node holding the <strong>primary shard</strong>, not at the node receiving the bulk request. The receiving node is just a coordinator that forwards internally. If one node is saturated because it holds all the large primary shards, the only fix is to rebalance shards, not to change Filebeat’s target.</p><h4>Bringing It Together</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WFSiVBeW-1O7qo5w5kuhqw.png" /></figure><p>None of these changes require additional hardware. They are configuration-only optimizations that unlock performance Wazuh is already capable of, performance that the conservative defaults leave on the table.</p><p>The lesson is not that Wazuh’s defaults are wrong. They are intentionally conservative: safe for the widest range of deployments, from a 10-agent lab to a 100-agent enterprise. But if you are operating at scale, hundreds or thousands of agents, dozens of network devices, or environments with high EPS, treat the default configuration as a starting point. Look under the hood. Check the blind spots. Measure with analysisd.state, Filebeat logs, and _cat/thread_pool. Then tune deliberately.</p><p>The pipeline is only as fast as its slowest stage. Now you know where to look.</p><p>Visit Wazuh page here:</p><p><a href="https://wazuh.com/">Wazuh - Open Source XDR. Open Source SIEM.</a></p><p>Join Wazuh Ambassador program here:</p><p><a href="https://wazuh.com/ambassadors-program">Ambassadors Program | Wazuh</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=442b3c83e8b9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Unlocking Endpoint Visibility: Real-Time Browser History Monitoring with Wazuh]]></title>
            <link>https://medium.com/@bayusangkaya/unlocking-endpoint-visibility-real-time-browser-history-monitoring-with-wazuh-8459b86d3e14?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/8459b86d3e14</guid>
            <category><![CDATA[wazuh]]></category>
            <category><![CDATA[browser-monitoring]]></category>
            <category><![CDATA[soc]]></category>
            <category><![CDATA[siem]]></category>
            <category><![CDATA[custom-detection]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Thu, 11 Dec 2025 16:49:40 GMT</pubDate>
            <atom:updated>2025-12-11T16:49:40.773Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>Disclaimer: Ensure you comply with local privacy laws and company policies before monitoring user browser history.</blockquote><p><strong>Browser activity is often the blind spot in endpoint security.</strong> While we monitor processes, file changes, and network connections, the actual context of <em>what</em> a user is viewing, whether it’s a phishing site, a competitor’s portal, or an unauthorized SaaS application, is usually locked away in SQLite databases on the endpoint.</p><p>Wazuh is an incredible SIEM, but out of the box, it doesn’t ingest browser history files (like Chrome’s History or Firefox’s places.sqlite). These files are databases, not flat logs.</p><p>In this guide, I will share a custom solution I developed: a cross-platform Python agent that extracts browser history in real-time, converts it into a Syslog-compatible format, and feeds it directly into Wazuh.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/582/1*4i9bgu0nbZtPPs91qO2B-Q.png" /></figure><h4>The Challenge: Databases vs. Logs</h4><p>Browsers (Chrome, Edge, Firefox, Safari, Opera) store history in SQLite databases. They are often locked when the browser is open, and they use different timestamp formats (WebKit Epoch, Unix Epoch, Mac Epoch).</p><p>To monitor this with Wazuh, we need a “translator” that:</p><ol><li>Safely copies the database (to avoid file locks).</li><li>Normalizes the timestamps to a human-readable format.</li><li>Writes the output to a text log file that the Wazuh Agent can read.</li></ol><h4>Solution: browser-history-monitor.py</h4><p>I wrote a Python script that acts as this translator. It runs in the background on Windows, macOS, and Linux, supports multiple profiles, and even detects installed extensions.</p><h4><strong>Key Features:</strong></h4><ul><li><strong>Cross-Platform:</strong> Works on Windows, Linux, and macOS.</li><li><strong>Multi-Browser:</strong> Chrome, Edge, Firefox, Brave, Opera, Safari (macOS).</li><li><strong>Extension Auditing:</strong> Logs installed browser extensions and versions.</li><li><strong>Smart Logging:</strong> Uses Syslog formatting for easy parsing in Wazuh.</li></ul><p>Visit my works <a href="https://github.com/bayusky/wazuh-custom-rules-and-decoders">here</a>:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QAfVS0GyKaZejBFK4PnSHQ.png" /></figure><h4>Step 1: Deploying the Monitor</h4><p>I have created automated installers that handle dependencies (like Python 3) and set up persistence (Scheduled Tasks on Windows, Systemd / LaunchAgents on Linux / Mac).</p><h4>For Windows Endpoints</h4><p>Run this PowerShell one-liner as Administrator. It installs Python (if missing), downloads the script, and sets up a background Scheduled Task that runs for any logged-on user.</p><pre>powershell -ExecutionPolicy Bypass -Command &quot;[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; iwr -UseBasicParsing &#39;https://raw.githubusercontent.com/bayusky/wazuh-custom-rules-and-decoders/main/browser-monitoring/windows-installer.ps1&#39; | iex&quot;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EiDj_IgTr8Rnpws21orKYg.png" /></figure><h4>For Linux and macOS Endpoints</h4><p>Run this Bash command. It detects your OS and sets up the appropriate background service.</p><pre>curl -s https://raw.githubusercontent.com/bayusky/wazuh-custom-rules-and-decoders/main/browser-monitoring/install_browser_monitor.sh | bash</pre><blockquote>Note for macOS Users: To monitor Safari, you must grant “Full Disk Access” to the terminal or the Python executable in System Settings &gt; Privacy &amp; Security.</blockquote><h4>Step 2: Configuring the Wazuh Agent</h4><p>Once the monitor is running, it generates a log file. We need to tell the Wazuh Agent to tail this file.</p><h4>Log Locations</h4><ul><li><strong>Windows:</strong> C:\\BrowserMonitor\\browser_history.log</li><li><strong>Linux/Mac:</strong> ~/.browser-monitor/browser_history.log</li></ul><p>Add the following configuration to your agent’s ossec.conf (or via Centralized Configuration in agent.conf):</p><pre>&lt;localfile&gt;<br>  &lt;location&gt;C:\BrowserMonitor\browser_history.log&lt;/location&gt;<br>  &lt;log_format&gt;syslog&lt;/log_format&gt;<br>  &lt;out_format&gt;monitor: $(log)&lt;/out_format&gt;<br>&lt;/localfile&gt;</pre><p>or Linux/Mac, simply change the &lt;location&gt;path.</p><pre>&lt;localfile&gt;<br>  &lt;location&gt;~/.browser-monitor/browser_history.log&lt;/location&gt;<br>  &lt;log_format&gt;syslog&lt;/log_format&gt;<br>  &lt;out_format&gt;monitor: $(log)&lt;/out_format&gt;<br>&lt;/localfile&gt;</pre><blockquote>The out_format part is necessary to avoid conflict with syslog decoder</blockquote><h4>Step 3: Parsing the Logs (Decoders)</h4><p>Since the script outputs in a standard format (Timestamp Hostname Tag: Message), Wazuh can read the header automatically. However, we want to extract the specific fields: <strong>Browser</strong>, <strong>Profile</strong>, <strong>URL</strong>, and <strong>Title</strong>.</p><p>Add this to your /var/ossec/etc/decoders/local_decoder.xml on the Wazuh Manager:</p><pre>  &lt;decoder name=&quot;browser-monitor-log&quot;&gt;<br>     &lt;prematch&gt;browser-monitor&lt;/prematch&gt;<br>     &lt;regex&gt;browser-monitor: (\S+ \S+) (\S+) (\S+) (\S+) (\.+)&lt;/regex&gt;<br>     &lt;order&gt;mon_timestamp,mon_browser_name,mon_profile,mon_url,mon_title&lt;/order&gt;<br>  &lt;/decoder&gt;</pre><h4>Step 4: Creating Alerts (Rules)</h4><p>Now, let’s create rules to alert on suspicious activity. Add these to /var/ossec/etc/rules/local_rules.xml.</p><h4><strong>Basic Rule: Capture All History</strong></h4><p>This rule fires on every visited URL (level 3).</p><pre>&lt;group name=&quot;browser_history&quot;&gt;<br>  &lt;rule id=&quot;980001&quot; level=&quot;3&quot;&gt;<br>    &lt;decoded_as&gt;browser-monitor-log&lt;/decoded_as&gt;<br>    &lt;description&gt;Browser History&lt;/description&gt;<br>  &lt;/rule&gt;<br>&lt;/group&gt;</pre><h4>Threat Hunting Rules</h4><p>You can get creative here. For example, detecting access to generative AI tools or known malicious domains.</p><pre>  &lt;rule id=&quot;980002&quot; level=&quot;7&quot;&gt;<br>    &lt;if_sid&gt;920001&lt;/if_sid&gt;<br>    &lt;field name=&quot;mon_url&quot; type=&quot;pcre2&quot;&gt;chatgpt\.com|claude\.ai|bard\.google\.com&lt;/field&gt;<br>    &lt;description&gt;Policy: User accessed Generative AI tool $(url)&lt;/description&gt;<br>  &lt;/rule&gt;<br><br>  &lt;rule id=&quot;920003&quot; level=&quot;10&quot;&gt;<br>    &lt;if_sid&gt;920001&lt;/if_sid&gt;<br>    &lt;field name=&quot;mon_urlurl&quot; type=&quot;pcre2&quot;&gt;anonfiles|mega\.nz|temp-mail&lt;/field&gt;<br>    &lt;description&gt;High Risk: User accessed file sharing or disposable email site&lt;/description&gt;<br>  &lt;/rule&gt;</pre><h4>Alerts Visulization</h4><p>Once deployed, you will see real-time events in your Wazuh Dashboard whenever a user navigates to a new webpage. This data is invaluable for:</p><ol><li><strong>Forensic Timelines:</strong> Correlating a malware download with the exact URL visited seconds before.</li><li><strong>Shadow IT Discovery:</strong> Finding users utilizing unauthorized SaaS tools.</li><li><strong>Productivity Monitoring:</strong> (If your policy permits) Analyzing browsing habits.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3NyvdbZeZkNAUk0O_7TXkg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rCnbAMz7vyW0no9hTx2lZw.png" /></figure><h4>Conclusion</h4><p>By combining a lightweight Python script with Wazuh’s powerful log ingestion, we bridge the gap between endpoint databases and security monitoring. This setup is free, open-source, and highly customizable.</p><p>You can find the full source code and installers in my GitHub repository here:</p><p><a href="https://github.com/bayusky/wazuh-custom-rules-and-decoders/tree/main/browser-monitoring">wazuh-custom-rules-and-decoders/browser-monitoring at main · bayusky/wazuh-custom-rules-and-decoders</a></p><p>Visit Wazuh page here:</p><p><a href="https://wazuh.com/">Wazuh - Open Source XDR. Open Source SIEM.</a></p><p>Join Wazuh Ambassador program here:</p><p><a href="https://wazuh.com/ambassadors-program/">Ambassadors Program | Wazuh</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8459b86d3e14" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Deteksi File Judol memanfaatkan FIM Wazuh]]></title>
            <link>https://medium.com/cyberkarta/deteksi-file-judol-memanfaatkan-fim-wazuh-4d43fb8333f6?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/4d43fb8333f6</guid>
            <category><![CDATA[detection]]></category>
            <category><![CDATA[fim]]></category>
            <category><![CDATA[wazuh]]></category>
            <category><![CDATA[judol]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Sun, 09 Mar 2025 05:10:00 GMT</pubDate>
            <atom:updated>2025-03-09T05:10:00.810Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KHgTQJcD58nPXguPNOxm_w.png" /><figcaption>Serangan situs judol pada situs pemerintahan</figcaption></figure><h4>Overview</h4><p>Saat ini masif sekali attack terhadap website di Indonesia dari situs-situs penyedia layanan judi online. Modus operandi mereka adalah memanfaatkan celah di situs dan meng-inject atau mengubah file yang ada dalam directory website dengan laman promosi judi online. Melalui modus operandi yang dilakukan, sebetulnya saya langsung terpikirkan bahwa ini seharusnya bisa dideteksi menggunakan Wazuh FIM.</p><p>Wazuh memiliki fitur File Integrity Monitoring (FIM) yang bisa mendeteksi penambahan, perubahan, maupun penghapusan file dalam direktori yang diawasi, secara default FIM ini dijalankan setiap 12 jam. Konfigurasi FIM bisa ditambahkan dengan property ‘real-time’ dan ‘report-changes’ untuk mendeteksi perubahan secara real time dan mendeteksi ada perubahan apa pada file tersebut. Limitasinya adalah ‘report-changes’ hanya bisa diterapkan pada file berbasis text. Sementara itu file laman dan kode pada direktori website berupa file text, sehingga metode ‘report-changes’ bisa diterapkan.</p><h4>Konfigurasi pada Agent</h4><p>Masukkan direktori website dan enable property ‘real-time’ dan ‘report-changes’ pada konfigurasi agent di /var/ossec/etc/ossec.conf di dalam tag &lt;syscheck&gt;</p><pre>&lt;directories realtime=&quot;yes&quot; check_all=&quot;yes&quot; report_changes=&quot;yes&quot;&gt;/var/www/html&lt;/directories&gt;</pre><p>SIlakan ganti /var/www/html dengan direktori website masing-masing. Lalu restart wazuh agent untuk mengaktifkan konfigurasi ini. FIM ini bersifat recursive, jadi wazuh agent akan mengawasi isi direktori dan sub direktori yang ada pada path yang dicantumkan.</p><pre>systemctl restart wazuh-agent</pre><p>Konfigurasi ini juga bisa diterapkan melalui shared configuration pada wazuh manager pada file /var/ossec/etc/shared/default/agent.conf dengan menambahkan konfigurasi ini dalam tang &lt;agent_config&gt;</p><pre>&lt;syscheck&gt;<br>  &lt;directories realtime=&quot;yes&quot; check_all=&quot;yes&quot; report_changes=&quot;yes&quot;&gt;/var/www/html&lt;/directories&gt;<br>&lt;/syscheck&gt;</pre><p>Aktifkan shared configuration ini jika direktori website dalam beberapa agent berada pada path yang sama.</p><h4>Konfigurasi dari Wazuh Manager</h4><p>Tambahkan rules untuk mendeteksi file judol. Rules ini terdiri dari 2 tahap:</p><ol><li>Mendeteksi jika ada file baru ditambahkan pada direktori website</li><li>Mendeteksi jika ada perubahan file yang berisi signature laman judol</li></ol><p>Tambahkan pada /var/ossec/etc/rules/local_rules.xml atau buat file rules sendiri.</p><pre>&lt;!-- Rules for judol detection --&gt;<br>&lt;group name=&quot;ossec,syscheck,&quot;&gt;<br>  &lt;!-- This rule detects file creation on web directory --&gt;<br>  &lt;rule id=&quot;500554&quot; level=&quot;12&quot;&gt;<br>    &lt;if_sid&gt;554&lt;/if_sid&gt;<br>    &lt;field name=&quot;file&quot; type=&quot;pcre2&quot;&gt;(?i)public|www|html&lt;/field&gt;<br>    &lt;description&gt;[File creation on web directory]: New file $(file) on web directory&lt;/description&gt;<br>    &lt;group&gt;syscheck_entry_added,syscheck_file&lt;/group&gt;<br> &lt;mitre&gt;<br>      &lt;id&gt;T1105&lt;/id&gt;<br>      &lt;id&gt;T1505&lt;/id&gt;<br>    &lt;/mitre&gt;<br>  &lt;/rule&gt;<br>  <br>  &lt;!-- This rule detects files modified with judol signatures. --&gt;<br>  &lt;rule id=&quot;500550&quot; level=&quot;15&quot;&gt;<br>    &lt;if_sid&gt;550&lt;/if_sid&gt;<br>    &lt;field name=&quot;changed_content&quot; type=&quot;pcre2&quot;&gt;(?i)slot|gacor|maxwin|thailand|sigmaslot|zeus|cuan&lt;/field&gt;<br>    &lt;description&gt;[Judol File Modification]: File $(file) contains a judol signature&lt;/description&gt;<br> &lt;group&gt;syscheck_entry_modified, syscheck_file, judol_file&lt;/group&gt;<br>    &lt;mitre&gt;<br>      &lt;id&gt;T1105&lt;/id&gt;<br>      &lt;id&gt;T1505.003&lt;/id&gt;<br>    &lt;/mitre&gt;<br>  &lt;/rule&gt;<br>&lt;/group&gt;</pre><p>Rules <strong>500554</strong> akan mendeteksi jika ada file baru yang ditambahkan pada direktori website. Jika ada file yang ditambahkan namun path bukan pada upload direktori ataupun bukan pada saat update/patch website, maka itu adalah event yang harus dicurigai dan segera dilakukan pengecekan.</p><p>Rules <strong>500550</strong> akan memeriksa isi perubahan pada file yang berubah. Jika ada signature judol yang disertakan dalam &lt;changed_content&gt; maka event akan dibangkitkan.</p><p>Rules lengkap bisa dilihat pada: <a href="https://github.com/bayusky/wazuh-custom-rules-and-decoders/tree/main/rules">wazuh-custom-rules-and-decoders/rules at main · bayusky/wazuh-custom-rules-and-decoders</a></p><p>Save lalu restart wazuh manager</p><pre>systemctl restart wazuh-manager</pre><h4>Proof of Concept</h4><p>SSH ke dalam VM web server lalu buat file baru pada direktori yang diawasi</p><pre>touch /var/www/html/index.text</pre><p>Perhatikan alert yang muncul</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1008/1*PqX1WfDEWrmnF4QDlZFk_w.png" /></figure><p>Rule <strong>500554</strong> akan dengan level 12 akan di-generate oleh Wazuh, karena ada file yang ditambahkan pada direktori web server.</p><p>Lalu masukkan signature judol pada file yang ditambahkan tadi.</p><pre>echo &quot;maxwin slot gacor&quot; &gt;&gt; /var/www/index.text</pre><p>Perhatikan alert yang muncul.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fz2PIslnjaY3P3f3knAzzA.png" /></figure><p>Rule 500550 akan di-generate oleh Wazuh dengan level 15 yang menunjukkan adanya dignature judol yang dimasukkan ke dalam file</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/525/1*G_YA8sn2PidJCBs_nltL9w.png" /></figure><p>Bagian yang berubah ditangkap dalam key <strong>syscheck.diff.</strong></p><h4>Visualisasi dan Dashboard</h4><p>Untuk memudahkan pemantauan, bisa dibuat visualiasi untuk memberitahukan bahwa ada alerts mengenai judol yang dibangkitkan. Pada side menu, pilih menu Visualize di dalam Explore.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/599/1*aRc8zimwXV3tJWvLRE_XSA.png" /></figure><p>Lalu pilih create visualization, pilih Metric.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z2fCp_wzcEAIzH-sc6Wdlw.png" /></figure><p>Untuk sumber data, pilih wazuh-alerts-*</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/990/1*dKn1GgCJ_OgJa7CvE6Nepw.png" /></figure><p>Klik Add filter, pilih filter seperti pada gambar berikut: rule.id is 500554 untuk rule new file pada direktori web, atau rule.id is 500550 untuk signature judol, klik Save.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/896/1*YclaqX2DXcA4HHf9aBnjiQ.png" /></figure><p>Klik Save di pojok kanan atas untuk menyimpan visualisasi.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ffHBJj73dgZHQ_dss-S-SQ.png" /></figure><p>Beri nama visualisasi yang menggambarkan informasi yang ditampilkan, lalu klik Save</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/556/1*SspZXUUWJvCD3NhtyRjqxw.png" /></figure><p>Ulangi untuk file judol.</p><p>Selanjutnya buat visualisasi untuk menampilkan path file dan agent lokasi file tersebut terdeteksi. Pilih jenis visualisasi Data Table, lalu wazuh-alerts-* untuk sumber data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EDUQ-VdBz9VKOjDncEYloA.png" /></figure><p>Atur filter rule.id is 500554 untuk rule new file pada direktori web, atau rule.id is 500550 untuk signature judol, klik Save.</p><p>Pada menu kanan, bagian data, klik Buckets klik Add lalu klik Split rows</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/571/1*qlqv7YSedHiIQcDb2jQFXw.png" /></figure><p>Klik Aggregation lalu pilih Terms, pada Field ketik agent.name lalu isi Agent untuk Custom Label. Buckets ini artinya visualisasi akan dibedakan per barisnya untuk setiap agent.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/518/1*V9hxECsZNa4lfd0NcJ8QUQ.png" /></figure><p>Klik Addlagi dan pilih Split rowslagi untuk menambahkan data berikutnya untuk Sub-buckets.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/532/1*EMR_OdahCrvmUmt0meRtAQ.png" /></figure><p>Pilih Terms untuk Sub-aggregation, ketik syscheck.pathpada Field lalu isi Path untuk Custom Label. Buckets ini artinya visualisasi akan dibedakan per barisnya untuk path file yang berubah untuk setiap agent. Lalu klik Update</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/517/1*POwkKRwFGL2pUbIhxVhNTQ.png" /></figure><p>Periksa hasil Visualisasi, jika sudah sesuai klik Save lalu berikan judul sesuai dengan informasi yang ditampilkan.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CiIN_9o1lzXsQFaSxplNRw.png" /></figure><p>Ulangi hal yang sama untuk rule.id: 500550</p><p>Pastikan Visualisasi ini sudah ada pada menu Visualize.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*w8HmyHVM8Kl1INjI5WOQ-Q.png" /></figure><p>Buat Dashboard baru melalui side menu Explore &gt; Dashboard &gt; Create new Dashboard</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/691/1*hCiFHAuro06UXaX_1W4Jcw.png" /></figure><p>Untuk menambahkan Visualisasi ke dalam Dashboard pilih menu Add, lalu tambahkan semua Visualisasi yang sudah dibuat</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hamuV9_haRIc9thX9XHRPw.png" /></figure><p>Pilih semua visualisasi yang sudah dibuat</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/937/1*Ogl3m7JkLQkPMAdV6fB6_Q.png" /></figure><p>Isi panel pada dashboard dapat disesuaikan agar menarik dan informatif dengan metode klik and drag pada Judul panel dan Icon pada kanan bawah panel.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8sfo5t60YfT5n2F7_Fwidw.png" /></figure><p>Save Dashboard dengan memberikan judul yang sesuai dengan informasi yang ditampilkan.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/554/1*o4yRPjEcq_fSugYE4bHWiw.png" /></figure><p>Sehingga ketika membuka Wazuh kembali, Dashboard bisa langsung dipilih untuk ditampilkan kembali.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_JNRjIBILcawJmuOQQjy5w.png" /></figure><p>Jika sudah memiliki Dashboard monitoring, Visualisasi juga bisa ditambahkan untuk visibilitas Event.</p><p><strong>Tips 1. </strong>Wazuh memiliki session yang pendek jadi harus login secara berkala, namun jika ingin Dashboard SOC ditampilkan dalam waktu lama dan dalam session yang panjang, bisa diintegrasikan dengan Grafana Dashboard (akan dibahas pada course mengenai SOAR yang akan launching di Cyberkarta).</p><p><strong>Tips 2.</strong> Kirimkan alert mengenai Rules 500554 dan 500550 melalui Telegram Bot supaya bisa direspon dengan cepat oleh tim CSIRT, caranya bisa mengikuti: <a href="https://bayuskylabs.com/integrasi-wazuh-alert-dengan-telegram-bot/">Integrasi Wazuh Alert dengan Telegram Bot — BayuSky’s Virtual Labs</a></p><p><strong>Tips 3. </strong>Bisa ditambahkan deteksi webshell / reverse shell untuk mendetksi kapan file judol di-inject mengikuti tutorial: <a href="https://wazuh.com/blog/web-shell-attack-detection-with-wazuh/">Web shell attack detection with Wazuh | Wazuh</a></p><p><strong>Tips 4.</strong> Jika sudah terlanjur ada file judol sebelum rules ini diterapkan, bisa dicari menggunakan tools buatan rekan saya: <a href="https://github.com/adpermana/Incident-Response-Tools/tree/analisa">adpermana/Incident-Response-Tools at analisa</a></p><h4>Conclusion</h4><p>Rules ini dapat mendeteksi jika ada perubahan file terkait judol. Namun tetap diperlukan reaksi cepat dari tim CSIRT jika alert ini muncul. Perhatikan path dan juga isinya untuk menghindari alerts yang bersifat false-positive.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4d43fb8333f6" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/deteksi-file-judol-memanfaatkan-fim-wazuh-4d43fb8333f6">Deteksi File Judol memanfaatkan FIM Wazuh</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Part 1 : Integrasi SIEM dan CTI. Instalasi MISP Threat Intelligence]]></title>
            <link>https://medium.com/cyberkarta/part-1-integrasi-siem-dan-cti-instalasi-misp-threat-intelligence-639efd9f43e7?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/639efd9f43e7</guid>
            <category><![CDATA[threat-intelligence]]></category>
            <category><![CDATA[misp]]></category>
            <category><![CDATA[wazuh]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Sat, 06 Jul 2024 02:14:29 GMT</pubDate>
            <atom:updated>2025-06-09T05:32:29.747Z</atom:updated>
            <content:encoded><![CDATA[<h3>Part 1 : Integrasi Wazuh dan CTI. Instalasi MISP Threat Intelligence</h3><p>MISP adalah open source threat intelligence yang dapat diinstall secara on premise. MISP dpat dijadikan sebagai sumber informasi tambahan untuk pengayaan informasi untuk Wazuh agar dapat berfungsi sebagai XDR. System requirements untuk MISP adalah sebagai berikut :</p><ul><li>2 CPU</li><li>4GB RAM</li><li>150 GB Storage</li></ul><p>Instalasi menggunakan docker, namun harus menggunakan package dari dockerhub. Jika instalasi dari apt resources (untuk Ubuntu) kemungkinan akan mendapatkan error saat build images. Jadi pertama-tama install dulu docker engines dengan langkah-langkah berikut.</p><p>Install docker engine dari dockerhub</p><pre>for pkg in docker.io docker-doc docker-compose podman-docker containerd runc; do apt-get remove $pkg; done</pre><pre># Add Docker&#39;s official GPG key:<br>apt-get update<br>apt-get install ca-certificates curl<br>install -m 0755 -d /etc/apt/keyrings<br>sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc<br>sudo chmod a+r /etc/apt/keyrings/docker.asc</pre><pre># Add the repository to Apt sources:<br>echo \\<br>  &quot;deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] &lt;https://download.docker.com/linux/debian&gt; \\<br>  $(. /etc/os-release &amp;&amp; echo &quot;$VERSION_CODENAME&quot;) stable&quot; | \\<br>  tee /etc/apt/sources.list.d/docker.list &gt; /dev/null<br>apt-get update</pre><pre>sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin</pre><p>Setelah docker engine siap, kita bisa melanjutkan ke instalasi MISP. Langkah-langkahnya adalah sebagai berikut.</p><p>Clone repositori MISP</p><pre>git clone &lt;https://github.com/MISP/misp-docker&gt; &amp;&amp; cd misp-docker</pre><p>Ubah parameter di .env</p><pre>cp template.env .env<br>nano .env</pre><pre>## ubah bagian ini<br>MISP_BASEURL=https://&lt;misp-ip-address&gt;</pre><p>MISP base url ini harus tepat karena tampilan dari UI MISP bergantung dari path yang ditentukan di sini.</p><p>Pada docker compose, service misp, hanya expose https</p><pre>nano docker-compose.yml</pre><pre>## ubah ports</pre><pre> #&quot;80&quot;:&quot;80&quot;<br> &quot;443&quot;:&quot;443&quot;</pre><p>Build image</p><pre>docker compose build</pre><p>Up image</p><pre>docker compose up -d</pre><p>Follow logs dengan menggunakan command</p><pre>docker logs &lt;ID&gt; --follow</pre><p>Setelah muncul log berupa MISP is live now, user can login, buka UI MISP</p><pre>https://base_url_MISP</pre><p>Login menggunakan credential default yaitu username: <a href="/service/mailto:admin@admin.test">admin@admin.test</a> dan password: admin. Segera ganti password dengan password yang lebih kuat.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XD1apFjt8zo4yk24o4_uCA.png" /><figcaption>change password menu</figcaption></figure><p>Ambil feeds dari <a href="https://github.com/MISP/MISP/blob/2.4/app/files/feed-metadata/defaults.json">sini</a> untuk memasukkan sumber data. Copy raw value lalu pase di Sync Actions &gt; Feeds &gt; Import Feeds from JSON.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jH3dpChUwWP1BMuuIL3eNw.png" /></figure><p>Akan muncul pada List Feeds daftar sumber data</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4Cnn6kIj5XhbCpp8WJuwxQ.png" /></figure><p>Centang lalu klik Enable feeds untuk mengaktifkan sumber data, lalu klik fetch and store all feed data untuk mendownload data yang disediakan setiap sumber feeds.</p><p>Kita bisa melihat data yang diambil dari feeds pada Event Actions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kFG5D7-6cZwCMYapCrPl1g.png" /></figure><p>Dan dapat melihat attributes yang muncul untuk setiap events di List Attributes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3exWVNzi-ImrK7ijOrWtNQ.png" /></figure><p>List attributes ini yang akan dijadikan lookup value oleh Wazuh untuk pencarian IoC.</p><p>Agar Wazuh bisa otomatis lookup, butuh Authkey untuk akses API. Buat Authkey untuk akses API MISP, lokasi di Administration &gt; List Auth Keys &gt; Add Authentication Key</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HbQRbXSA2XIhmfCVtHVwPA.png" /></figure><p>Centang read-only jika ingin membatasi akses.</p><p>Tes API.</p><pre>curl -k  --header &quot;Authorization: &lt;API-key&gt;&quot; \<br>         --header &quot;Accept: application/json&quot; \<br>         --header &quot;Content-Type: application/json&quot; \<br>         https://&lt;MISP-IP&gt;/attributes/restSearch/value:bayuskylabs.com</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z7KpqwVYGVc-7i2Sl7ec7g.png" /></figure><p>Jika attributes kosong berarti tidak ada security event terkait dengan lookup value di MISP.</p><p>Jadwalkan untuk siknronisasi feeds setiap tengah malam, supaya bisa feeds selalu up to date datanya.</p><pre>00 0 * * * /usr/bin/curl -XPOST --insecure --header &quot;Authorization: **YOUR_API_KEY**&quot; --header &quot;Accept: application/json&quot; --header &quot;Content-Type: application/json&quot; https://**YOUR_MISP_ADDRESS**/feeds/fetchFromAllFeeds</pre><p>MISP instance sudah siap dijadikan sumber data untuk Wazuh. Akan berlanjut ke Part 2 untuk mengkoneksikan Wazuh dengan MISP.</p><p>Part 2 Integrasi Wazuh dengan MISP: <a href="https://youtu.be/B-L8QwOwPcU?si=Ygt2-cNPSRPLEfUL">https://youtu.be/B-L8QwOwPcU?si=Ygt2-cNPSRPLEfUL</a></p><p>Untuk Integrasi dan pemanfaatan MISP ini juga saya bahas di Course Wazuh 2 di Cyberkarta : <a href="https://www.cyberkarta.com/kelas/Production-Ready-SIEM-dan-SOC-Menggunakan-Wazuh-dan-Graylog">Production Ready SIEM dan SOC Menggunakan Wazuh dan Graylog (cyberkarta.com)</a><br>Bagi yang ingin mendalami CTI, akan ada live course tentang CTI di Cyberkarta. Stay tuned.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=639efd9f43e7" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/part-1-integrasi-siem-dan-cti-instalasi-misp-threat-intelligence-639efd9f43e7">Part 1 : Integrasi SIEM dan CTI. Instalasi MISP Threat Intelligence</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[NEW! Wazuh 4.8.0 Installation and Quick Look]]></title>
            <link>https://medium.com/cyberkarta/new-wazuh-4-8-0-installation-and-quick-look-19e39e476842?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/19e39e476842</guid>
            <category><![CDATA[installation]]></category>
            <category><![CDATA[new-version]]></category>
            <category><![CDATA[wazuh]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Thu, 13 Jun 2024 16:45:49 GMT</pubDate>
            <atom:updated>2024-06-13T16:53:12.468Z</atom:updated>
            <content:encoded><![CDATA[<p>12 Juni 2024, Wazuh melakukan rilis versi terbarunya, yaitu Wazuh versi 4.8.0. Terdapat banyak revamp dan reposition untuk tampilan Wazuh supaya lebih mudah mengelompokkan security events. Artikel ini akan membahas instalasi dan quick look untuk Versi terbaru Wazuh.</p><p><strong>Requirements</strong></p><p>System requirements untuk Wazuh 4.8.0 masih sama dengan versi sebelumnya yaitu untuk testing menggunakan minimal resource sebagai berikut:</p><ul><li>2 core CPU/vCPU</li><li>4GB RAM</li><li>50GB Storage</li></ul><p>Saya melakukan testing instalasi di 2 lokasi: idcloudhost dan local VM (VirtualBox). Untuk langkah instalasi ini masih sama dengan versi sebelmnya, saya akan bahas menjadi 2 yaitu quickstart dan assissted installation.</p><p><strong>Quickstart</strong></p><p>Metode Quickstart ini adalah metode instalasi one liner dengan listen IP di 127.0.0.1 di Wazuh Manager dan Wazuh Indexer. Sementara Wazuh dashboard menggunakan IP 0.0.0.0 yang artinya menerima semua koneksi. Tinggal copy paste saja dengan catatan jalankan ini pada akun yang memiliki privilege root.</p><pre>curl -sO https://packages.wazuh.com/4.8/wazuh-install.sh &amp;&amp; sudo bash ./wazuh-install.sh -</pre><p>Setelah selesai, akan muncul username dan password untukAkses Wazuh Dashboard.</p><p><strong>Assisted Installation</strong></p><p>Assisted installation menggunakan Wazuh Install Script dari wazuh untuk meginstal setiap komponen Wazuh. Langkah-langkahnya adalah sebagai berikut:</p><ul><li>Download file konfigurasi dan installer</li></ul><pre>curl -sO https://packages.wazuh.com/4.8/wazuh-install.sh<br>curl -sO https://packages.wazuh.com/4.8/config.yml</pre><ul><li>Modifikasi config.yml</li></ul><pre>nodes:<br>  # Wazuh indexer nodes<br>  indexer:<br>    - name: node-1<br>      ip: &quot;192.168.1.9&quot;<br>    #- name: node-2<br>    #  ip: &quot;&lt;indexer-node-ip&gt;&quot;<br>    #- name: node-3<br>    #  ip: &quot;&lt;indexer-node-ip&gt;&quot;<br><br>  # Wazuh server nodes<br>  # If there is more than one Wazuh server<br>  # node, each one must have a node_type<br>  server:<br>    - name: wazuh-1<br>      ip: &quot;192.168.1.9&quot;<br>    #  node_type: master<br>    #- name: wazuh-2<br>    #  ip: &quot;&lt;wazuh-manager-ip&gt;&quot;<br>    #  node_type: worker<br>    #- name: wazuh-3<br>    #  ip: &quot;&lt;wazuh-manager-ip&gt;&quot;<br>    #  node_type: worker<br><br>  # Wazuh dashboard nodes<br>  dashboard:<br>    - name: dashboard<br>      ip: &quot;192.168.1.9&quot;</pre><p>IP 192.168.1.9 adalah IP VM untuk wazuh manager.</p><ul><li>Generate config file</li></ul><pre>bash wazuh-install.sh --generate-config-files</pre><ul><li>Instalasi Wazuh Indexer</li></ul><pre>bash wazuh-install.sh --wazuh-indexer node-1</pre><ul><li>Start Cluster</li></ul><pre>bash wazuh-install.sh --start-cluster</pre><ul><li>Instalasi Wazuh Server</li></ul><pre>bash wazuh-install.sh --wazuh-server wazuh-1</pre><ul><li>Instalasi Wazuh Dashboard</li></ul><pre>bash wazuh-install.sh --wazuh-dashboard dashboard</pre><ul><li>Akses Wazuh Interface di https://192.168.1.9</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KYr745_KZLSUegOFOAz6FA.png" /><figcaption>Tampilan Dashboard Utama</figcaption></figure><p><strong>Quick Look</strong></p><p>Tampilan Wazuh lebih fresh karena Wazuh melakukan refactor dan regrouping terhadapa user interfacse-nya. Bagian Security Events, berpindah menjadi Threat Hunting</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/588/1*T2Gz4_r6kFRf8lm2OAvKQg.png" /><figcaption>Threat Hunting</figcaption></figure><p>Sidebar pun berubah. Sebelumnya sidebar wazuh menunjukkan aplikasi di dalamnya, seperti Opensearch dan Wazuh, sekarang sudah dikelompokkan menjadi beberapa event group. Jadi Wazuh menu yang tadinya ada di top menu, sekarang menjadi satu di dalam sidebar. Ini memudahkan untuk melakukan management karena semua menjadi satu lokasi sidebar. Oh iya untuk sidebar ini juga t</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/522/1*4yiQ85gGPWJBEgdf669xnQ.png" /></figure><p>Di bagian Compliance, Wazuh menambahkan TSC sebagai sarana untuk SOC Compliance Ready.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/905/1*L95RJJIZtyiv_hKGDAw19Q.png" /></figure><p>Demikian adalah proses instalasi dan quick look untuk Wazuh versi 4.8.0. Semoga dengan artikel ini, pembaca menjadi paham dan tidak bingung ketika posisi menu favoritnya berubah. Untuk release notes lengkap ada di <a href="https://documentation.wazuh.com/current/release-notes/release-4-8-0.html">4.8.0 Release notes — 12 June 2024–4.x · Wazuh documentation</a></p><p>Selamat ngoprek dan mencoba.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=19e39e476842" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/new-wazuh-4-8-0-installation-and-quick-look-19e39e476842">NEW! Wazuh 4.8.0 Installation and Quick Look</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Merapikan notifikasi Telegram dari Wazuh Alert]]></title>
            <link>https://medium.com/cyberkarta/merapikan-notifikasi-telegram-dari-wazuh-alert-feccbe68b0b8?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/feccbe68b0b8</guid>
            <category><![CDATA[alerts]]></category>
            <category><![CDATA[telegram-bot]]></category>
            <category><![CDATA[wazuh]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Wed, 12 Jun 2024 16:39:12 GMT</pubDate>
            <atom:updated>2024-06-16T05:37:56.453Z</atom:updated>
            <content:encoded><![CDATA[<p>Melanjutkan tulisan saya di <a href="https://medium.com/@bayusangkaya/integrasi-wazuh-alert-dengan-telegram-bot-dc162e3aa3">Integrasi Wazuh Alert dengan Telegram Bot | by Bayu Sangkaya | Medium</a>, artikel kali ini saya akan merapikan dan memformat notifikasi menggunakan metode Markdown formatting.</p><p>Jika melihat notifikasi telegram seperti ini, tentu akan menyulitkan membacanya bukan?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/632/1*vRRdhTKhKjVjDkfmAfx7Hg.png" /></figure><p>Webhook dari telegram dapat kita tambahkan dengan formatting Markdown, sehingga alert dari Wazuh pun akan lebih tertata dan enak dibaca. Mari kita mulai.</p><p>Kita buat dulu fungsi untuk membuat pesan berisi informasi alert yang akan dikirimkan. Fungsi ini isinya adalah mengambil informasi alert lalu menyusun pesan dalam format Markdown.</p><pre>def create_message(alert_json):<br>    # Get alert information, use empty string if field didn&#39;t exist<br>    title = alert_json[&#39;rule&#39;][&#39;description&#39;] if &#39;description&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    description = alert_json[&#39;full_log&#39;] if &#39;full_log&#39; in alert_json else &#39;&#39;<br>    description.replace(&quot;\\n&quot;, &quot;\n&quot;) <br>    alert_level = alert_json[&#39;rule&#39;][&#39;level&#39;] if &#39;level&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    group_array = &#39;, &#39;.join(alert_json[&#39;rule&#39;][&#39;groups&#39;]) if &#39;groups&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    groups=group_array.replace(&quot;_&quot;,&quot; &quot;) #replace underscore with space, otherwise it will produce a parsing error message<br>    rule_id = alert_json[&#39;rule&#39;][&#39;id&#39;] if &#39;rule&#39; in alert_json else &#39;&#39;<br>    agent_name = alert_json[&#39;agent&#39;][&#39;name&#39;] if &#39;name&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    agent_id = alert_json[&#39;agent&#39;][&#39;id&#39;] if &#39;id&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    agent_ip = alert_json[&#39;agent&#39;][&#39;ip&#39;] if &#39;ip&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    src_ip = alert_json[&#39;data&#39;][&#39;srcip&#39;] if &#39;srcip&#39; in alert_json[&#39;data&#39;] else &#39;&#39;    <br>   <br>    # Format message with markdown<br>    msg_content = f&#39;*{title}*\n\n&#39;<br>    msg_content += f&#39;_{description}_\n\n&#39;<br>    msg_content += f&#39;*Groups:* {groups}\n&#39; if len(groups) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Source IP:* {src_ip}\n&#39; if len(src_ip) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Rule:* {rule_id} (Level {alert_level})\n\n&#39;<br>    msg_content += f&#39;*Agent:* {agent_name} ({agent_id})\n&#39; if len(agent_name) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Agent IP:* {agent_ip}&#39; if len(agent_ip) &gt; 0 else &#39;&#39;<br><br>    msg_data = {}<br>    msg_data[&#39;chat_id&#39;] = CHAT_ID<br>    msg_data[&#39;text&#39;] = msg_content<br>    msg_data[&#39;parse_mode&#39;] = &#39;markdown&#39;<br><br>    # Debug information<br>    with open(&#39;/var/ossec/logs/integrations.log&#39;, &#39;a&#39;) as f:<br>        f.write(f&#39;MSG: {msg_data}\n&#39;)<br><br>    return json.dumps(msg_data)<br></pre><p>Output dari funsgi ini adalah arraymsg_data yang berisi Chat ID, Text, dan Parsing mode. Ketiga hal tersebut menjadi parameter dalam POST message melalui webhook Telegram. Sehingga saat dikirimkan, pesan sudah berformat Markdown. Hasil pesannya adalah seperti ini:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/668/1*gnvSSLOr1HHLkFXyN6zAuw.png" /></figure><p>Jika text tertata seperti itu, tentu saja akan lebih mudah dibaca bukan?</p><p>Source code full bisa dilihat di bawah ini.</p><pre>#!/usr/bin/env python<br><br>import sys<br>import json<br>import requests<br>from requests.auth import HTTPBasicAuth<br>import hashlib<br><br>#CHAT_ID=&quot;-xxxx&quot; --- change with your chat id <br>CHAT_ID=&quot;-xxxxx&quot;<br><br>def create_message(alert_json):<br>    # Get alert information, use empty string if field didn&#39;t exist<br>    title = alert_json[&#39;rule&#39;][&#39;description&#39;] if &#39;description&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    description = alert_json[&#39;full_log&#39;] if &#39;full_log&#39; in alert_json else &#39;&#39;<br>    description.replace(&quot;\\n&quot;, &quot;\n&quot;) <br>    alert_level = alert_json[&#39;rule&#39;][&#39;level&#39;] if &#39;level&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    group_array = &#39;, &#39;.join(alert_json[&#39;rule&#39;][&#39;groups&#39;]) if &#39;groups&#39; in alert_json[&#39;rule&#39;] else &#39;&#39;<br>    groups=group_array.replace(&quot;_&quot;,&quot; &quot;) #replace underscore with space, otherwise it will produce a parsing error message<br>    rule_id = alert_json[&#39;rule&#39;][&#39;id&#39;] if &#39;rule&#39; in alert_json else &#39;&#39;<br>    agent_name = alert_json[&#39;agent&#39;][&#39;name&#39;] if &#39;name&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    agent_id = alert_json[&#39;agent&#39;][&#39;id&#39;] if &#39;id&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    agent_ip = alert_json[&#39;agent&#39;][&#39;ip&#39;] if &#39;ip&#39; in alert_json[&#39;agent&#39;] else &#39;&#39;<br>    src_ip = alert_json[&#39;data&#39;][&#39;srcip&#39;] if &#39;srcip&#39; in alert_json[&#39;data&#39;] else &#39;&#39;<br>    <br>    # Format message with markdown<br>    msg_content = f&#39;*{title}*\n\n&#39;<br>    msg_content += f&#39;_{description}_\n\n&#39;<br>    msg_content += f&#39;*Groups:* {groups}\n&#39; if len(groups) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Source IP:* {src_ip}\n&#39; if len(src_ip) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Rule:* {rule_id} (Level {alert_level})\n\n&#39;<br>    msg_content += f&#39;*Agent:* {agent_name} ({agent_id})\n&#39; if len(agent_name) &gt; 0 else &#39;&#39;<br>    msg_content += f&#39;*Agent IP:* {agent_ip}&#39; if len(agent_ip) &gt; 0 else &#39;&#39;<br><br>    msg_data = {}<br>    msg_data[&#39;chat_id&#39;] = CHAT_ID<br>    msg_data[&#39;text&#39;] = msg_content<br>    msg_data[&#39;parse_mode&#39;] = &#39;markdown&#39;<br><br>    #Debug information  <br>    with open(&#39;/var/ossec/logs/integrations.log&#39;, &#39;a&#39;) as f:<br>        f.write(f&#39;MSG: {msg_data}\n&#39;)<br><br>    return json.dumps(msg_data)<br><br><br>alert_file = open(sys.argv[1])<br>hook_url = sys.argv[3]<br><br># Read the alert file<br>alert_json = json.loads(alert_file.read())<br>alert_file.close()<br><br># Send the request<br>msg_data = create_message(alert_json)<br>headers = {&#39;content-type&#39;: &#39;application/json&#39;, &#39;Accept-Charset&#39;: &#39;UTF-8&#39;}<br>response = requests.post(hook_url, headers=headers, data=msg_data)<br>print(&quot;telegram : &quot;,msg_data)<br><br>#Debug information<br>with open(&#39;/var/ossec/logs/integrations.log&#39;, &#39;a&#39;) as f:<br>    f.write(f&#39;telegram response: {response}\n&#39;)<br><br>sys.exit(0)</pre><p>Selamat ngoprek.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=feccbe68b0b8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/merapikan-notifikasi-telegram-dari-wazuh-alert-feccbe68b0b8">Merapikan notifikasi Telegram dari Wazuh Alert</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Memilih Network Mode pada VirtualBox untuk Pembuatan Lab Wazuh]]></title>
            <link>https://medium.com/cyberkarta/memilih-network-mode-pada-virtualbox-untuk-pembuatan-lab-wazuh-b49f9f5de989?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/b49f9f5de989</guid>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Sun, 09 Jun 2024 15:11:01 GMT</pubDate>
            <atom:updated>2024-06-10T03:05:52.109Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/962/1*SDCrXXG7my4CmACVVYXilw.png" /><figcaption>Virtualbox Networking</figcaption></figure><p>Wazuh merupakan platform cybersecurity yang gratis dan opensource, sehingga kita bisa mempelajarinya dengan mudah melalui virtualisasi. Platform virtualisasi (hypervisor) untuk desktop client yang populer ada 2: Virtualbox dan VMWare. Virtualbox akan paling umum digunakan, hal juga karena Virtualbox merupakan software virtualisasi yang gratis.</p><p>Jaringan LAN dalam Virtualisasi di dalam hypervisor juga dilakukan secara virtual. Namun jaringan ini sangat berpengaruh terhadap komunikasi antar VM, VM dengan host, ataupun VM ke internet. Dalam Virtualbox terdapat beberapa mode networking yang bisa dipilih, yang paling sering dipakai adalah mode NAT (default), Bridge, dan Host-only.</p><p>Dalam praktik Wazuh, VM yang digunakan harus memiliki IP Address yang tetap dan tidak berubah. Hal ini dikarenakan komunikasi antar komponen Wazuh diamankan menggunakan SSL dengan IP Address sebagai pengenalnya. Jika IP Address VM berubah, makan komunikasi antar komponen Wazuh, maupun Wazuh server dengan Wazuh agent akan terganggu dan harus dilakukan penyesuaian ulang. Sealin itu, Wazuh dashboard dan SSH juga harus bisa diakses dari Host. Dengan prasyarat seperti itu, maka mode networking untuk Wazuh Lab harus memenuhi persyaratan berikut.</p><ol><li>VM harus bisa terhubung dengan internet untuk instalasi Wazuh</li><li>VM harus bisa terhubung dengan Host PC untuk instalasi dan dashboard</li><li>VM harus bisa menghubungi VM lainnya untuk test monitoring.</li></ol><p>Mode networking yang bisa memenuhi ketiga syarat tersebut dalah sebagai berikut.</p><h4>Bridge</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1023/1*hfpp1PcawLYuX1mnDGFH3w.png" /><figcaption>Mode Bridge</figcaption></figure><p>Mode network Bridge akan memberikan VM IP address yang satu segmen dengan Host dan keduanya tetap bisa terhubung dengan internet. Hal ini memudahkan pengaturan karena tanpa pengaturan tambahan pun Host PC dengan Wazuh server bisa saling komunikasi. Hanya saja mode Bridge itu mendapatkan IP dari DHCP server yang didapat oleh Host PC. Jadi ketika Host PC berpindah lokasi atau segmen, maka VM yang menggunakan mode Bridge pun akan berubah IP Addressnya dan membutuhkan pengaturan ulang.</p><p>Selain itu, mode Bridge juga akan membuat <strong>VM ter-ekspos</strong> ke Jaringan di mana Host PC berada, sehingga dianggap kurang aman. Namun Bridge tetap bisa digunakan untuk pembuatan Lab jika dan hanya jika Host PC memang <strong>bersifat statis</strong> dan <strong>tidak berpindah tempat</strong> sehingga baik Host PC maupun VM mendapatkan IP Address dalam satu segmen. Selain itu juga untuk menggunakan bridge harus dipastikan dulu bahwa penggunaan jaringan berada di jaringan privat untuk meminimalisir kemungkinan VM terekspos ke pengguna lainnya.</p><p><strong>NAT + Host-only</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aMaKltoa2IGIFokICkvkYw.png" /><figcaption>NAT + Host-only networking</figcaption></figure><p>NAT mode merupakan network default untuk VM Virtualbox. Melalui NAT, setiap VM bisa terhubung ke internet, namun tidak bisa mendapatkan koneksi antar VM maupun VM dengan Host. Namun NAT menawarkan isolasi yang baik terhadap pengguna di luar Host PC. Untuk mengatasi kekurangan tersebut, akan lebih baik jika menggunakan 1 virtual ethernet lagi yang terhubung melalui jaringan Host-only.</p><p>Jaringan Host-only ini hanya bisa digunakan untuk komunikasi antar VM maupun VM dengan host. Pilihan ini merupakan pilihan yang paling aman dan menyeluruh. Aman karena <strong>VM tidak terekspos</strong> ke pengguna lain di mana Host PC berada karena berbeda segmen sama sekali dengan Host PC, namun tetapsemua persyaratan network untuk Lab Praktikum Wazuh bisa tercapai. Pengaturan Host only cukup mudah, tinggal mengaktifkan satu ethernet lagi untuk mode host only agar dapat dilakukan SSH maupun copy-paste perintah melalui Terminal SSH.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/713/1*cpFEtyTCvIFHF3vy05W_3A.png" /><figcaption>NAT Mode</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/713/1*-QE2-ocxlWbdQAwDhJXGzw.png" /><figcaption>Host-only mode</figcaption></figure><p>Selain kedua hal tersebut, pastikan juga antara Wazuh server dan wazuh agent bisa terhubung melalui port 1515 (untuk enrollment agent) dan 1514 (untuk pelaporan antara agent dan server). Silakan pilih mode networking yang sesuai dengan kondisi lab yang anda miliki. Selamat ngoprek.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b49f9f5de989" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/memilih-network-mode-pada-virtualbox-untuk-pembuatan-lab-wazuh-b49f9f5de989">Memilih Network Mode pada VirtualBox untuk Pembuatan Lab Wazuh</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Mengenal Perbedaan IDS, IPS, SIEM, EDR, dan XDR dalam Dunia Cybersecurity]]></title>
            <link>https://medium.com/cyberkarta/mengenal-perbedaan-ids-ips-siem-edr-dan-xdr-dalam-dunia-cybersecurity-e9be0fc62ef0?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/e9be0fc62ef0</guid>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[siem]]></category>
            <category><![CDATA[xdr]]></category>
            <category><![CDATA[ip]]></category>
            <category><![CDATA[id]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Thu, 06 Jun 2024 11:09:41 GMT</pubDate>
            <atom:updated>2024-06-06T11:09:41.766Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g_OYbEXQBWwpcBuS2b828g.jpeg" /></figure><p>Ketika pertama kali terjun dalam dunia cyber security, biasanya akan dihadapkan banyak istilah baru beserta tools yang termasuk di dalamnya. Tentu saja hal baru ini bisa saja membuat mereka yang baru terjun merasa bingung, apalagi istilah dan toolsnya mirip-mirip. Artikel kali ini akan membahas mengenai perbedaan dalam istilah-istilah tersebut. Yuk kita bahas satu per satu.</p><h4>Intrusion Detection System (IDS)</h4><p>IDS berfungsi sebagai <strong>penjaga</strong> atau <strong>detector</strong> di jaringan, berfungsi untuk memantau aktivitas dan mencari tanda-tanda intrusi. Saat mendeteksi aktivitas mencurigakan, IDS akan <strong>memberi tahu</strong> atau meberikan <strong>alert </strong>kepada SOC team,<strong> </strong>agar dapat diinvestigasi lebih lanjut. IDS tidak secara langsung menghentikan serangan, tetapi memberikan informasi valuable untuk mencegah serangan di masa depan.</p><p>IDS dapat dibagi menjadi dua jenis: Network-based IDS (NIDS) yang memonitor lalu lintas jaringan, dan Host-based IDS (HIDS) yang memonitor aktivitas di dalam sistem atau perangkat.</p><p><strong>Contoh:</strong></p><ul><li><strong>Snort dan Suricata:</strong> Salah satu contoh IDS yang populer dan bersifat open-source, digunakan untuk mendeteksi serangan berbasis jaringan.</li><li><strong>OSSEC:</strong> Merupakan HIDS yang bersifat open-source dan mampu mendeteksi ancaman pada sistem.</li><li><strong>Wazuh: </strong>Merupakan HIDS berbasis ossec rules ditambah dengan analysisd untuk mendeteksi ancaman pada sistem.</li></ul><h4>Intrusion Prevention System (IPS)</h4><p>IPS bekerja sama dengan IDS, tetapi dengan kemampuan tambahan untuk <strong>mencegah</strong> serangan secara langsung. Saat IPS mendeteksi aktivitas berbahaya, IPS dapat <strong>memblokir</strong> traffic atau menutup port yang terkena dampak. Hal ini membantu mencegah kerusakan yang disebabkan oleh serangan siber.</p><p>IPS bekerja secara real-time untuk menghentikan atau memblokir aktivitas berbahaya dengan memodifikasi aturan firewall, mengisolasi bagian tertentu dari jaringan, atau menghentikan proses yang mencurigakan.</p><p><strong>Contoh:</strong></p><ul><li><strong>Cisco FirePOWER:</strong> Merupakan contoh IPS yang dapat mengidentifikasi dan mencegah berbagai jenis ancaman.</li><li><strong>McAfee Network Security Platform:</strong> Menyediakan perlindungan IPS dengan kemampuan deteksi dan pencegahan ancaman tingkat lanjut.</li><li><strong>Wazuh: </strong>Memiliki fungsi active response yang dapat digunakan untuk action ketika ada ancaman.</li></ul><h4>Security Information and Event Management (SIEM)</h4><p>SIEM bertindak sebagai <strong>pusat intelijen</strong> untuk keamanan siber atau SOC. SIEM <strong>mengumpulkan</strong> data dari berbagai sumber, seperti log jaringan, log endpoint, dan log aplikasi. Selanjutnya SIEM <strong>menganalisisnya</strong> untuk mencari pola dan anomali yang menunjukkan aktivitas berbahaya. SIEM dapat membantu Anda <strong>mengidentifikasi</strong> serangan di tahap awal dan <strong>menyelidikinya</strong> dengan lebih cepat.</p><p>SIEM membantu dalam deteksi ancaman dengan mengkorelasikan data dari berbagai sumber dan memberikan wawasan serta analisis mendalam mengenai pola serangan. SIEM juga memainkan peran penting dalam kepatuhan (compliance) dengan regulasi keamanan.</p><p><strong>Contoh:</strong></p><ul><li><strong>Splunk:</strong> Platform SIEM yang kuat dengan kemampuan analisis data besar dan korelasi kejadian.</li><li><strong>IBM QRadar:</strong> SIEM yang terkenal dengan fitur analisis ancaman dan manajemen insiden.</li><li><strong>Wazuh: </strong>Megumpulkan seluruh log melalui agent yang terinstall dalam endpoint.</li></ul><h4>Endpoint Detection and Response (EDR)</h4><p>EDR berfokus pada <strong>perlindungan endpoint</strong> Anda, seperti laptop, desktop, dan server. EDR <strong>memonitor</strong> aktivitas endpoint untuk mencari tanda-tanda malware, ransomware, dan serangan lainnya. Saat EDR mendeteksi ancaman, EDR dapat <strong>melakukan tindakan</strong> seperti mengisolasi endpoint yang terinfeksi, menghentikan proses berbahaya, dan menghapus malware.</p><p><strong>EDR</strong> fokus pada pemantauan dan deteksi ancaman pada endpoint (seperti komputer, laptop, dan perangkat mobile). EDR biasanya menyediakan fitur seperti analisis perilaku, deteksi anomali, dan forensik digital.</p><p><strong>Contoh:</strong></p><ul><li><strong>CrowdStrike Falcon:</strong> Solusi EDR yang terkenal dengan kemampuan deteksi dan respon ancaman secara real-time.</li><li><strong>SentinelOne:</strong> Menyediakan alat EDR dengan analisis perilaku yang kuat dan visibilitas yang mendalam.</li></ul><h4>Extended Detection and Response (XDR)</h4><p>XDR adalah solusi keamanan siber terbaru yang <strong>mengintegrasikan</strong> kemampuan IDS, IPS, SIEM, dan EDR. XDR memberikan <strong>pandangan yang lebih luas</strong> tentang aktivitas keamanan di seluruh jaringan dan endpoint Anda. Hal ini memungkinkan Anda untuk <strong>mendeteksi dan merespons</strong> ancaman dengan lebih cepat dan efektif, bahkan di lingkungan yang kompleks dan hybrid.</p><p>XDR bertujuan untuk memberikan visibilitas yang lebih luas dan mendalam serta koordinasi yang lebih baik dalam merespon ancaman yang kompleks. XDR menyatukan berbagai alat keamanan (seperti EDR, NDR, SIEM, dan lainnya) ke dalam satu platform terpadu untuk meningkatkan efisiensi dan efektivitas deteksi dan respon ancaman.</p><p><strong>Contoh:</strong></p><ul><li><strong>Palo Alto Networks Cortex XDR:</strong> Platform XDR yang mengintegrasikan data dari berbagai sumber untuk deteksi dan respon yang lebih baik.</li><li><strong>Trend Micro XDR:</strong> Menyediakan visibilitas lintas endpoint, email, server, cloud workloads, dan jaringan untuk meningkatkan deteksi dan respon ancaman.</li><li><strong>Wazuh XDR: </strong>Wazuh bisa diintegrasikan dengan pihak ketiga untuk memperkaya informasi yang digunakan untuk analysis. Contohnya dengan MISP ataupun Virustotal.</li></ul><p>Dengan memahami perbedaan, fungsi, dan contoh dari IDS, IPS, SIEM, EDR, dan XDR, organisasi dapat memilih solusi yang paling sesuai untuk kebutuhan keamanan sibernya dan melindungi aset digitalnya dari berbagai ancaman yang terus berkembang.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e9be0fc62ef0" width="1" height="1" alt=""><hr><p><a href="https://medium.com/cyberkarta/mengenal-perbedaan-ids-ips-siem-edr-dan-xdr-dalam-dunia-cybersecurity-e9be0fc62ef0">Mengenal Perbedaan IDS, IPS, SIEM, EDR, dan XDR dalam Dunia Cybersecurity</a> was originally published in <a href="https://medium.com/cyberkarta">Cyberkarta</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Memblokir attacker melalui command active-response dari Wazuh]]></title>
            <link>https://medium.com/@bayusangkaya/memblokir-attacker-melalui-command-active-response-dari-wazuh-5277c3311aa3?source=rss-f41e1b25314b------2</link>
            <guid isPermaLink="false">https://medium.com/p/5277c3311aa3</guid>
            <category><![CDATA[wazuh]]></category>
            <category><![CDATA[scanning]]></category>
            <category><![CDATA[siem]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[ip]]></category>
            <dc:creator><![CDATA[Bayu Sangkaya]]></dc:creator>
            <pubDate>Sun, 08 Jan 2023 16:20:40 GMT</pubDate>
            <atom:updated>2023-01-24T03:16:29.447Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/507/1*Ioj5An9TrFD_14d27vVIAw.png" /></figure><p>Wazuh memiliki command active-response. Command ini berfungsi untuk meresponse serangan yang terdeteksi oleh Wazuh. Use case yang saya bahas kali ini adalah mengantisipasi multiple error 400 yang diakses dari satu IP. Multiple error 400 diindikasikan ada usaha scanning, serangan XSS, atau Directory Traversal. Rules ini didefinisikan pada rules-id 31151 dari Wazuh.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/1*H-VZ0JUPdhHSFWjK8Z4Zog.png" /><figcaption>Rules 31151 Wazuh</figcaption></figure><p>Daftar command active-response dapat dilihat pada /var/ossec/active-response/bin</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/803/1*fZtnc2BNOGkmIirV2Aal9w.png" /><figcaption>daftar command active-response</figcaption></figure><h4>Konfigurasi active-response</h4><p>Command yang akan digunakan pada use case ini adalah firewall-drop yang secara default sudah terdefinisi pada /var/ossec/etc/ossec.conf pada bagian ini</p><pre>&lt;command&gt;<br>  &lt;name&gt;firewall-drop&lt;/name&gt;<br>  &lt;executable&gt;firewall-drop&lt;/executable&gt;<br>  &lt;timeout_allowed&gt;yes&lt;/timeout_allowed&gt;<br>&lt;/command&gt;</pre><p>Tambahkan definisi aksi firewall-drop seperti dibawah ini</p><pre>&lt;!-- Active response firewall-drop scanning --&gt;<br>&lt;active-response&gt;<br>  &lt;command&gt;firewall-drop&lt;/command&gt;<br>  &lt;location&gt;all&lt;/location&gt;<br>  &lt;rules_id&gt;31151&lt;/rules_id&gt;<br>  &lt;timeout&gt;3600&lt;/timeout&gt;<br>&lt;/active-response&gt;</pre><ul><li><strong>location:</strong> parameter all digunakan untuk memblokir IP Adrress attacker disemua agent, jika hanya ingin diblokir di agent sumber alert, gunakan local</li><li><strong>rules_id:</strong> sesuai dengan alert Wazuh.</li><li><strong>timeout:</strong> dalam detik.</li></ul><blockquote>Jika timeout sudah terlewati, maka IP Address attacker bisa mengakses lagi.</blockquote><p>Restart wazuh-manager</p><h4>Proof of Concept</h4><p>Muncul alert dari Wazuh seperti ini</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/581/1*usit9KWsHYFzVQJ6I90mig.png" /><figcaption>Alert Telegram Bot</figcaption></figure><p>Cek di Security Events milik agent</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KRp8-MQm231HrwsbQL1s-Q.png" /></figure><p>Terlihat berturut-turut log alert lalu log blokir, lebih jelasnya</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*c4amIQq5m0qDD5JSSbr2mA.png" /><figcaption>host blocked</figcaption></figure><p>Melalui log ini, bisa dibuktikan bahwa IP Address attacker telah diblok dengan aksi firewall-drop melalui active-response dari Wazuh.</p><blockquote>Source : <a href="https://documentation.wazuh.com/current/user-manual/capabilities/active-response/index.html">Active response — Capabilities · Wazuh documentation</a></blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5277c3311aa3" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>