Tactics: Privilege Escalation, Persistence · Platforms: Linux, macOS, Windows
Adversaries may establish persistence and elevate privileges by using an installer to trigger the execution of malicious content. Installer packages are OS specific and contain the resources an operating system needs to install applications on a system. Installer packages can include scripts that…
Sub-technique of Event Triggered Execution (T1546).
title: "T1546.016 Event Triggered Execution: Installer Packages"
id: 8982a7ab-13ef-4319-94af-3e53437c1b34
description: 'Detection Strategy for T1546.016 - Event Triggered Execution via Installer Packages. (Retargeted: the previous rule watched creation of files under apt.conf.d/ and dnf plugins/, which is package-manager-hook persistence, not installer package scripting; this version instead watches EXECUTION of the actual dpkg/rpm maintainer scripts -- preinst/postinst/prerm/postrm under /var/lib/dpkg/info/, and rpm''s scriptlet temp files under /var/tmp/rpm-tmp.* -- which is what T1546.016 describes as running with inherited root privileges during package install/remove.) Tune using: ScriptName, PackageManager.'
references:
- https://attack.mitre.org/techniques/T1546/016
author: Shahrukh Khan
date: 2026-04-26
license: MIT
tags:
- attack.privilege-escalation
- attack.persistence
- attack.t1546.016
logsource:
category: process_creation
product: linux
service: auditd
detection:
selection_dpkg_maintainer_script:
type: EXECVE
a0|contains: '/var/lib/dpkg/info/'
a0|re: '.*\.(postinst|preinst|prerm|postrm)