Last active
February 22, 2022 21:37
-
-
Save 2xyo/c570eb3bb3bf0a481417f5e5e6933ba2 to your computer and use it in GitHub Desktop.
SPLUNK - attack_range_local - WSL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# doc https://www.vagrantup.com/docs/other/wsl & https://www.vagrantup.com/downloads | |
# https://github.com/splunk/attack_range_local/wiki/Ubuntu-18.04-Installation | |
$ lsb_release -a | |
No LSB modules are available. | |
Distributor ID: Ubuntu | |
Description: Ubuntu 20.04.4 LTS | |
Release: 20.04 | |
Codename: focal | |
$ uname -a | |
Linux home 5.10.16.3-microsoft-standard-WSL2 #1 SMP Fri Apr 2 22:23:49 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux | |
$ curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add - | |
$ sudo apt-add-repository "deb [arch=amd64] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | |
$ sudo apt update | |
$ sudo apt full-upgrade | |
$ sudo apt install -y python3-dev linux-headers-generic unzip python3-pip vagrant python3-virtualenv git | |
$ sudo gem install winrm-elevated | |
$ sudo gem install winrm | |
$ vagrant --version | |
Vagrant 2.2.19 | |
$ vagrant plugin install virtualbox_WSL2 | |
$ echo "* 0.0.0.0/0 ::/0" | sudo tee -a /etc/vbox/networks.conf | |
$ export VAGRANT_WSL_ENABLE_WINDOWS_ACCESS="1" | |
$ export PATH="$PATH:/mnt/c/Program Files/Oracle/VirtualBox" | |
$ git clone https://github.com/splunk/attack_range_local.git | |
$ cd attack_range_local | |
$ python3 -m venv --prompt "attack-range" venv | |
$ source ./venv/bin/activate | |
$ python -m pip install --upgrade pip | |
$ pip install --upgrade wheel setuptools | |
$ pip install -r requirements.txt | |
$ pip install markupsafe==2.0.1 # Fix "Remove soft_unicode, which was previously deprecated. Use soft_str instead. #261" https://markupsafe.palletsprojects.com/en/2.1.x/changes/#version-2-1-0 | |
$ ansible-galaxy collection install community.windows | |
$ python3 attack_range_local.py -a build | |
# If it's fail : | |
# Windows VM: Add a rule for winrm : 0.0.0.0:5985 | |
$ cd vagrant | |
$ vagrant provision |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment