Skip to content

Commit

Permalink
Fixed AmokSecurity set up
Browse files Browse the repository at this point in the history
Added the informaiton for amoksecurity.wtf to the build.
  • Loading branch information
secureideas authored and mgillam committed Oct 15, 2019
1 parent 7de7234 commit a0ade07
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 49 deletions.
49 changes: 1 addition & 48 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Vagrant.configure("2") do |config|
samuraiwtf.vm.provider "virtualbox" do |vb|
# Display the VirtualBox GUI when booting the machine
vb.gui = true
vb.name = "SamuraiWTF-4.2.0"
vb.name = "SamuraiWTF-4.2-next"
# Customize the amount of memory on the VM:
vb.memory = "4096"
vb.customize ["modifyvm", :id, "--vram", "128"]
Expand All @@ -39,51 +39,4 @@ Vagrant.configure("2") do |config|
end

end

#Additional build options. Sepearate virtual machines
#attack machine
# config.vm.define "userenv", autostart: false do |userenv|
# userenv.vm.host_name = "samuraiwtf"

# userenv.vm.provider "virtualbox" do |vb|
# # Display the VirtualBox GUI when booting the machine
# vb.gui = true
# vb.name = "SamuraiWTF User Environment"
# # Customize the amount of memory on the VM:
# vb.memory = "2048"
# vb.customize ["modifyvm", :id, "--vram", "16"]
# end

# userenv.vm.provision :shell, path: "install/shared_before.sh"
# userenv.vm.provision :shell, path: "install/userenv_bootstrap.sh"
# end

# #target server
# config.vm.define "target", autostart: false do |target|
# target.vm.host_name = "samuraitargets"
# #for debugging mainly
# target.vm.network "private_network", ip: "192.168.42.42"
# target.vm.hostname = "samurai-wtf"
# #config.hostsupdater.aliases = ["juice-shop.wtf","dojo-basic.wtf"]

# target.vm.provider "virtualbox" do |vb|
# vb.name = "Samurai Target Server"
# vb.memory = "2048"
# end

# target.vm.provision :shell, path: "install/shared_before.sh"
# target.vm.provision :shell, path: "install/target_bootstrap.sh"
# end

# forwarded port mapping
# currently none

# Private network
# currently none



# Provider-specific configuration


end
1 change: 1 addition & 0 deletions install/targets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
- import_tasks: targets/mutillidae/mutillidae-tasks.yml
- import_tasks: targets/samurai-dojo/samurai-dojo-tasks.yml
- import_tasks: targets/musashi/musashi-task.yml
- import_tasks: targets/amoksecurity/amoksecurity-tasks.yml


handlers:
Expand Down
28 changes: 28 additions & 0 deletions install/targets/amoksecurity/amoksecurity-tasks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@

- name: Setup hosts file entries
lineinfile:
dest: /etc/hosts
line: '127.0.0.1 amoksecurity.wtf'

- name: Create webroot for amoksecurity.wtf
file:
path: /var/www/amoksecurity
state: directory
owner: samurai
group: samurai
become: yes

- name: Setup nginx reverse-proxy config for amoksecurity
copy:
dest: /etc/nginx/conf.d/amoksecurity.conf
content: |
server {
listen 80;
server_name amoksecurity.wtf;
location / {
root /var/www/amoksecurity;
}
}
mode: 0744
notify:
- restart nginx
2 changes: 1 addition & 1 deletion install/targets/mutillidae/mutillidae-tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
state: started
enabled: yes

- name: Install Mutilldae docker container
- name: Install Mutillidae docker container
docker_container:
name: mutillidae
image: bit0pus/docker-mutillidae
Expand Down

0 comments on commit a0ade07

Please sign in to comment.