Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Adversaries may configure system settings to automatically execute a program during system boot or logon to maintain persistence or gain higher-level privileges on compromised systems.
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-14 | ✗→✓ | ▲ Improved | -50% | 0% |
| case-16 | ✗→✓ | ▲ Improved | 6% | 0% |
| case-17 | ✗→✓ | ▲ Improved | 2% | 0% |
| case-18 | ✗→✓ | ▲ Improved | 5% | 0% |
| case-19 | ✗→✓ | ▲ Improved | 15% | 0% |
Adversaries may configure system settings to automatically execute a program during system boot or logon to maintain persistence or gain higher-level privileges on compromised systems. Operating systems may have mechanisms for automatically running a program on system boot or account logon. These mechanisms may include automatically executing programs that are placed in specially designated directories or are referenced by repositories that store configuration information, such as the Windows Registry. An adversary may achieve the same goal by modifying or extending features of the kernel.
Since some boot or logon autostart programs run with higher privileges, an adversary may leverage these to elevate privileges.
Platforms: Linux, macOS, Windows, Network Devices
The following tests are from Atomic Red Team and provide actionable ways to test this technique:
Install a driver via pnputil.exe lolbin
Supported Platforms: windows
cmdpnputil.exe /add-driver "#{driver_inf}"
pnputil.exe is a native command-line utility in Windows to install drivers, this can be abused by to install malicious drivers. Ref: https://lolbas-project.github.io/lolbas/Binaries/Pnputil/
Supported Platforms: windows
powershellpnputil.exe -i -a #{driver_path}
Virtual Channels can be leveraged to alter RDP behavior using dedicated Addins.The mechanism is implemented using DLLs which can be executed during RDP session automatically. The DLLs are loaded in the host system only after successful connection is established with the remote system. Once the test is run, amsi.dll will be loaded on the host system during successful RDP session. Blog :https://learn.microsoft.com/en-us/windows/win32/termserv/terminal-services-virtual-channels?redirectedfrom=MSDN
Supported Platforms: windows Elevation Required: Yes
cmdreg add "HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Default\Addins\#{Subkey_Added}" /v Name /t REG_SZ /d "#{dll_inf}" /f
If Atomic Red Team tests are not applicable, manually verify the technique by:
No specific mitigations documented for this technique.
| Finding | Severity | Impact | | ------------------------------------------------------ | -------- | ----------- | | Boot or Logon Autostart Execution technique applicable | High | Persistence |
| CWE ID | Title | | ------- | ----------------------------- | | CWE-276 | Incorrect Default Permissions |
Other measured skills in the registry, with their headline benchmark lift.