-
Notifications
You must be signed in to change notification settings - Fork 0
/
splunk_dataload1.sh
38 lines (31 loc) · 985 Bytes
/
splunk_dataload1.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/bash
echo "Begin: Splunk data loading..."
echo "**Begin: Loading virtual environment..."
cd /home/ec2-user/attack_data
pwd
virtualenv venv
source venv/bin/activate
echo "**End: Loading virtual environment."
echo "**Begin: Execute Malware Replay Files."
echo "****Loading: replay_malware1"
python bin/replay.py -c bin/replay_malware1.yml
WAIT="$(( RANDOM %= 10 ))m"
echo "****Sleeping $WAIT minutes..."
sleep $WAIT
echo "****Loading: replay_malware2"
python bin/replay.py -c bin/replay_malware2.yml
WAIT="$(( RANDOM %= 10 ))m"
echo "****Sleeping $WAIT minutes..."
sleep $WAIT
echo "****Loading: replay_malware3"
python bin/replay.py -c bin/replay_malware3.yml
WAIT="$(( RANDOM %= 10 ))m"
echo "****Sleeping $WAIT minutes..."
sleep $WAIT
echo "****Loading: replay_malware4"
python bin/replay.py -c bin/replay_malware4.yml
WAIT="$(( RANDOM %= 10 ))m"
echo "****Sleeping $WAIT minutes..."
sleep $WAIT
echo "**End: Execute Malware Replay Files."
echo "End: Splunk data load."