<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Detection Engineering on RGROSEC</title><link>https://aegrah.github.io/tags/detection-engineering.html</link><description>Recent content in Detection Engineering on RGROSEC</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>Copyright © Ruben Groenewoud</copyright><lastBuildDate>Sat, 09 May 2026 12:00:00 +0200</lastBuildDate><atom:link href="https://aegrah.github.io/tags/detection-engineering/index.xml" rel="self" type="application/rss+xml"/><item><title>Copy Fail and DirtyFrag: Linux Page Cache Bugs in the Wild</title><link>https://aegrah.github.io/post/2026-05-09-copy-fail-dirtyfrag-linux-page-bugs-in-the-wild.html</link><pubDate>Sat, 09 May 2026 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2026-05-09-copy-fail-dirtyfrag-linux-page-bugs-in-the-wild.html</guid><description>
At Elastic Security Labs, together with Eric Forte and Samir Bousseaden, we analyzed the Linux kernel privilege escalation vulnerabilities Copy Fail (CVE-2026-31431), Copy Fail 2, and DirtyFrag. These issues exploit subtle page cache corruption bugs to create reliable paths to root access, using legitimate kernel interfaces such as AF_ALG, splice(), and in DirtyFrag's case, networking stack primitives via AF_NETLINK and AF_RXRPC.
Copy Fail has been reported as exploited in the wild and was added to CISA's Known Exploited Vulnerabilities catalog.</description></item><item><title>Hooked on Linux: Rootkit Detection Engineering</title><link>https://aegrah.github.io/post/2026-04-02-linux-rootkits-2-caught-in-the-act.html</link><pubDate>Thu, 02 Apr 2026 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2026-04-02-linux-rootkits-2-caught-in-the-act.html</guid><description>
In the second part of our two-part Linux rootkit series at Elastic Security Labs, Remco Sprooten and I turn from theory to detection engineering. We begin by demonstrating why static detection is often unreliable against Linux rootkits—even trivial modifications like stripping binaries or appending a single null byte can significantly degrade VirusTotal detection rates.
From there, we cover practical behavioral detection across userland rootkit loading (LD_PRELOAD, /etc/ld.so.preload, dynamic linker configuration), kernel-space LKM loading via init_module/finit_module syscalls, out-of-tree and unsigned module taint signals, kill-signal abuse, eBPF rootkits, io_uring-based evasion, persistence mechanisms, and defense evasion techniques such as masquerading as kernel threads and log cleansing.</description></item><item><title>Linux &amp; Cloud Detection Engineering - TeamPCP Container Attack Scenario</title><link>https://aegrah.github.io/post/2026-03-20-teampcp-container-attack-scenario.html</link><pubDate>Fri, 20 Mar 2026 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2026-03-20-teampcp-container-attack-scenario.html</guid><description>
At Elastic Security Labs, I published a real-world walkthrough of TeamPCP's multi-stage container compromise, demonstrating how Elastic's Defend for Containers (D4C) surfaces runtime signals across each stage of the attack chain. Rather than analyzing isolated techniques in abstraction, we follow the attack as it unfolds inside a containerized environment based on the TeamPCP cloud-native ransomware operation documented by Flare.
The scenario spans nearly the entire MITRE ATT&amp;amp;CK lifecycle—from initial execution via curl | bash and Kubernetes environment discovery, through lateral movement via kube.</description></item><item><title>Linux &amp; Cloud Detection Engineering - Getting Started with Defend for Containers (D4C)</title><link>https://aegrah.github.io/post/2026-03-19-getting-started-with-defend-for-containers.html</link><pubDate>Thu, 19 Mar 2026 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2026-03-19-getting-started-with-defend-for-containers.html</guid><description>
At Elastic Security Labs, I published a comprehensive walkthrough of Elastic's Defend for Containers (D4C) integration, covering Kubernetes-based deployment, BPF-enriched runtime telemetry analysis, and the practical application of policy-driven security controls for containerized Linux environments.
Defend for Containers arrived in Elastic Stack 9.3.0 as a runtime security integration that captures process execution and file access events enriched with container and orchestration context. This post provides a practical starting point for detection engineers: how to deploy D4C via Elastic Agent in Kubernetes, how its selector-response policy model works, which fields matter for detection logic (capabilities, interactive execution, container privilege context), and how to enable the pre-built detection ruleset.</description></item><item><title>Linux Detection Engineering - The Grand Finale on Linux Persistence Mechanisms</title><link>https://aegrah.github.io/post/2025-02-25-linux-detection-engineering-grand-finale-on-linux-persistence-mechanisms.html</link><pubDate>Tue, 25 Feb 2025 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2025-02-25-linux-detection-engineering-grand-finale-on-linux-persistence-mechanisms.html</guid><description>
In the fifth and final part of the Linux Persistence Detection Engineering series, we bring the journey to its grand finale by exploring some of the most obscure, creative, and complex persistence mechanisms. Building on the foundational concepts covered in previous publications, this final installment focuses on techniques rooted in the Linux boot process, authentication systems, inter-process communication, and core utilities.
We begin with GRUB-based persistence and the manipulation of initramfs, demonstrating both manual modifications and automated approaches using Dracut.</description></item><item><title>Linux Detection Engineering - Approaching the Summit on Persistence Mechanisms</title><link>https://aegrah.github.io/post/2025-02-11-linux-detection-engineering-approach-the-summit-on-persistence-mechanisms.html</link><pubDate>Tue, 11 Feb 2025 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2025-02-11-linux-detection-engineering-approach-the-summit-on-persistence-mechanisms.html</guid><description>
In the fourth part of the Linux Persistence Detection Engineering series, I continue exploring advanced Linux persistence techniques, expanding on the foundation set in previous publications.
This latest installment delves into additional creative and complex methods adversaries use to maintain persistence on Linux systems. We explore the abuse of Pluggable Authentication Modules (PAM), specifically how pam_exec can be leveraged to execute malicious code during authentication events. We also analyze installer package manipulation via RPM and DPKG, where lifecycle scripts are weaponized to establish persistence through package installations and updates.</description></item><item><title>Linux Detection Engineering - A Continuation on Persistence Mechanisms</title><link>https://aegrah.github.io/post/2025-01-27-linux-detection-engineering-continuation-on-persistence-mechanisms.html</link><pubDate>Mon, 27 Jan 2025 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2025-01-27-linux-detection-engineering-continuation-on-persistence-mechanisms.html</guid><description>
In the third part of the Linux Persistence Detection Engineering series, I continue exploring advanced Linux persistence techniques, expanding on the foundation set in previous publications.
This latest installment dives into more creative and complex persistence methods, providing security researchers and defenders with a deeper understanding of how adversaries maintain access on Linux systems. We explore techniques such as dynamic linker hijacking, where adversaries manipulate the dynamic linker through LD_PRELOAD to execute malicious code persistently.</description></item><item><title>Securing the edge: Harnessing Falco's power with Elastic Security for cloud workload protection</title><link>https://aegrah.github.io/post/2024-11-15-falco-workload-protection.html</link><pubDate>Fri, 15 Nov 2024 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2024-11-15-falco-workload-protection.html</guid><description>
At Elastic, we recognize the critical need for securing containerized applications in Kubernetes and cloud environments. To enhance runtime security, we’ve integrated Falco—an open-source cloud-native security tool—directly with Elastic Security. Falco leverages Linux kernel events and plugins to detect abnormal behavior, security threats, and compliance violations across hosts, containers, and Kubernetes clusters.
Building on our recent expansion of cloud security protections using CNCF open-source tools, this research details how the Falco and Elastic Security integration strengthens threat detection at the edge.</description></item><item><title>Cups Overflow: When your printer spills more than Ink</title><link>https://aegrah.github.io/post/2024-09-28-cups-overflow.html</link><pubDate>Sat, 28 Sep 2024 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2024-09-28-cups-overflow.html</guid><description>
At Elastic Security Labs, we analyzed a critical set of vulnerabilities in the CUPS printing system, disclosed by security researcher Simone Margaritelli (@evilsocket) on September 26, 2024. These flaws, affecting CUPS versions ≤ 2.0.1, enable unauthenticated remote attackers to achieve remote code execution (RCE) via the Internet Printing Protocol (IPP) and mDNS, exploiting UDP port 631. Key weaknesses include input validation flaws in cups-browsed, libcupsfilters, and libppd, as well as the long-unpatched foomatic-rip filter.</description></item><item><title>Linux Detection Engineering - A sequel on persistence mechanisms</title><link>https://aegrah.github.io/post/2024-08-29-linux-detection-engineering-sequel-on-persistence-mechanisms.html</link><pubDate>Thu, 29 Aug 2024 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2024-08-29-linux-detection-engineering-sequel-on-persistence-mechanisms.html</guid><description>
In this second part of the Linux Persistence Detection Engineering series, I explore the world of more advanced Linux persistence techniques. This part builds upon the knowledge obtained from the previous persistence blog dubbed &amp;quot;Linux Detection Engineering - A Primer on Persistence Mechanisms&amp;quot;. This sequel aims to equip defenders and security researchers with a more comprehensive understanding of Linux persistence. With the help of PANIX, a Linux persistence tool I developed, we will simulate these techniques, analyze the logs and observe detection opportunities.</description></item><item><title>Linux Detection Engineering - A primer on persistence mechanisms</title><link>https://aegrah.github.io/post/2024-08-21-linux-detection-engineering-primer-on-persistence-mechanisms.html</link><pubDate>Fri, 23 Aug 2024 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2024-08-21-linux-detection-engineering-primer-on-persistence-mechanisms.html</guid><description>
In this first installment of the Linux Persistence Detection Engineering series, I delve into Linux persistence mechanisms, exploring both common and complex techniques to enhance the knowledge of defenders and security researchers. I examine how these persistence methods operate, how to set them up, and most importantly, how to detect and hunt for them effectively. With the help of PANIX, a Linux persistence tool I developed, I’ll demonstrate practical examples and detection strategies, ensuring you gain a solid understanding of these crucial techniques.</description></item><item><title>Linux detection engineering with Auditd</title><link>https://aegrah.github.io/post/2024-04-09-linux-detection-engineering-with-auditd.html</link><pubDate>Tue, 09 Apr 2024 12:00:00 +0200</pubDate><guid>https://aegrah.github.io/post/2024-04-09-linux-detection-engineering-with-auditd.html</guid><description>
In this article, I explore how to effectively use Auditd and Auditd Manager for detection engineering. I’ll demonstrate Auditd's powerful features, guide you through the setup process, and show you how to create and modify rules to capture specific behaviors. You'll also learn how to interpret the logs and discover how Auditd Manager, an Elastic integration, enhances Auditd's utility by streamlining its management.
Are you interested in this research? The full paper is available at Elastic Security Labs!</description></item></channel></rss>