Skip to content

Commit 07a3e98

Browse files
author
Florian Roth
committed
v0.5 with Menu for test-set selection
1 parent 7b6ab27 commit 07a3e98

File tree

4 files changed

+57
-26
lines changed

4 files changed

+57
-26
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,5 @@
33
dist
44
out.tmp
55
build
6+
enc-files.7z
7+
enc-toolset.7z

APTSimulator.bat

+45-24
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
@ECHO OFF
22
color 0C
33
ECHO.
4-
ECHO ===========================================================================
5-
ECHO APT Simulator
6-
ECHO Florian Roth, v0.4.4 February 2018
7-
ECHO ===========================================================================
84

95
SET CWD="%~dp0"
106
cd %CWD%
@@ -21,6 +17,9 @@ SET PASS=aptsimulator
2117
SET APTDIR=C:\TMP
2218
SET WWWROOT=C:\inetpub\wwwroot
2319

20+
CLS
21+
ECHO ===========================================================================
22+
ECHO WARNING!
2423
ECHO.
2524
ECHO This program is meant to simulate an APT on the local system by
2625
ECHO distributing traces of typical APT attacks.
@@ -35,42 +34,64 @@ ECHO 4.) DO NOT upload contents of this archive to VIRUSTOTAL or a similar
3534
ECHO online service as they provide backend views in which researchers and
3635
ECHO attackers get access to the uploaded files.
3736
ECHO.
38-
3937
ECHO ===========================================================================
4038
ECHO Let's go ahead ... The next steps will manipulate the local system.
4139
ECHO.
4240
setlocal
4341
:PROMPT
44-
SET /P AREYOUSURE=Are you sure to proceed (Y/[N])?
42+
SET /P AREYOUSURE=Are you sure to proceed (Y/[N])?
4543
IF /I "%AREYOUSURE%" NEQ "Y" GOTO END
4644

47-
:: Run the test sets
45+
:MENU
46+
CLS
47+
color 07
48+
ECHO ===========================================================================
49+
TYPE welcome.txt
50+
ECHO.
51+
ECHO Select the test-set that you want to run:
52+
ECHO.
53+
ECHO 0 - RUN EVERY TEST
54+
ECHO 1 - Collection
55+
ECHO 2 - Command and Control
56+
ECHO 3 - Credential Access
57+
ECHO 4 - Defense Evasion
58+
ECHO 5 - Discovery
59+
ECHO 6 - Execution
60+
ECHO 7 - Lateral Movement
61+
ECHO 8 - Persistence
62+
ECHO 9 - Privilege Escalation
63+
ECHO E - EXIT
64+
ECHO.
65+
66+
SET /P M=Your selection (then press ENTER):
67+
IF %M%==0 SET list="collection" "command-and-control" "credential-access" "defense-evasion" "discovery" "execution" "lateral-movement" "persistence" "privilege-escalation"
68+
IF %M%==1 SET list="collection"
69+
IF %M%==2 SET list="command-and-control"
70+
IF %M%==3 SET list="credential-access"
71+
IF %M%==4 SET list="defense-evasion"
72+
IF %M%==5 SET list="discovery"
73+
IF %M%==6 SET list="execution"
74+
IF %M%==7 SET list="lateral-movement"
75+
IF %M%==8 SET list="persistence"
76+
IF %M%==9 SET list="privilege-escalation"
77+
IF %M%==e GOTO END
78+
IF %M%==E GOTO END
4879

49-
for %%i in (
50-
"collection"
51-
"command-and-control"
52-
"credential-access"
53-
"defense-evasion"
54-
"discovery"
55-
"execution"
56-
"lateral-movement"
57-
"persistence"
58-
"privilege-escalation"
59-
) do (
80+
:: Running all test sets
81+
for %%i in (%list%) do (
6082
ECHO.
6183
ECHO ###########################################################################
6284
ECHO RUNNING SET: %%i
6385
ECHO.
64-
for /f "delims=" %%x in ('dir /b /a-d .\test-sets\%%i\*.bat') do call ".\test-sets\%%i\%%x"
86+
for /f "delims=" %%x in ('dir /b /a-d .\test-sets\%%i\*.bat') do call ".\test-sets\%%i\%%x"
6587
)
66-
GOTO END
67-
68-
:END
69-
ECHO.
7088
ECHO ===========================================================================
7189
ECHO Finished!
7290
ECHO Check for errors and make sure you opened the command line as 'Administrator'
91+
PAUSE
92+
GOTO MENU
93+
94+
:END
7395
ECHO.
74-
pause
7596
color 07
7697
endlocal

build_pack.bat

+3-2
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ MKDIR %BUILD%
1010

1111
:: Script
1212
copy APTSimulator.bat %BUILD%
13+
copy welcome.txt %BUILD%
1314

1415
:: HELPERS
1516
del /Q %BUILD%\helpers\*.*
@@ -23,13 +24,13 @@ xcopy /S /Y .\test-sets %BUILD%\test-sets\
2324
:: Compress and encrypt toolset
2425
%ZIP% u -bb3 -t7z -r -mx=9 -mmt=4 -mhe=on -p%PASS% enc-toolset.7z ./toolset/
2526
:: Copy it to the build dir
26-
move enc-toolset.7z %BUILD%
27+
copy enc-toolset.7z %BUILD%
2728

2829
:: FILES
2930
:: Compress and encrypt workfiles
3031
%ZIP% u -bb3 -t7z -r -mx=9 -mmt=4 -mhe=on -p%PASS% enc-files.7z ./workfiles/
3132
:: Copy it to the build dir
32-
move enc-files.7z %BUILD%
33+
copy enc-files.7z %BUILD%
3334

3435
:: PACK
3536
ren build APTSimulator

welcome.txt

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
___ ____ ___________ _ __ __
2+
/ | / __ \/_ __/ ___/(_)___ ___ __ __/ /___ _/ /_____ _____
3+
/ /| | / /_/ / / / \__ \/ / __ `__ \/ / / / / __ `/ __/ __ \/ ___/
4+
/ ___ |/ ____/ / / ___/ / / / / / / / /_/ / / /_/ / /_/ /_/ / /
5+
/_/ |_/_/ /_/ /____/_/_/ /_/ /_/\__,_/_/\__,_/\__/\____/_/
6+
7+
Florian Roth, Nextron Systems, v0.5

0 commit comments

Comments
 (0)