process where host.os.type == "linux" and event.type == "start" and event.action == "exec" and
process.executable : "/var/lib/dpkg/info/*" and process.session_leader.name != null and
process.group_leader.name != null and not (
process.parent.name in ("dpkg", "dpkg-reconfigure", "frontend") or
process.session_leader.name == "dpkg" or
process.group_leader.name == "dpkg" or
process.parent.executable in ("/usr/share/debconf/frontend", "/usr/bin/unattended-upgrade")
)
Install detection rules in Elastic Security
Detect Unusual DPKG Execution in the Elastic Security detection engine by installing this rule into your Elastic Stack.
To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(opens in a new tab or window).