Friday, August 12, 2016

So, you wanna play with the Samurai web targets from Kali?

I wanted to play with the Samurai webapp targets from Kali (because I'm more familiar with Kali, of course), but I couldn't figure out how. They just didn't want to play nicely. Thanks to a good friend of mine that works for company undisclosed, errr, uhhhh...with Kevin Johnson, I got some tips on how to make this work.

Now, if you're a website admin, you probably know this already. I'm not.

Here's the fix:

On the Samurai VM, go to /etc/apache2/sites-available/ and get into the configs of each webapp. Inside you'll see something like this:


The "VirtualHost *IP address:port*" is where you'll change to your IP address you want. 

*EDIT:* You will also need to add the line: 

     ServerName <servername>

as well to the config file...I put mine after DocumentRoot.

Of course, you'll probably want to give yourself a static IP so that it doesn't change. VMware Workstation/Player can be a little finicky at times.

You should also notice that there are two different VirtualHosts here...one for port 80 and one for port 443. Change the IP on both.

Now, on your Kali box (or whatever you want to pentest/play with the webapps from), you'll need to set the hosts file up to point that webapp name to the IP address you placed in the file.

Voila! You're done.

Stay classy.
Aaron

No comments: