WPScan is a WordPress vulnerability scanner written in Ruby. It is sponsored by Sucuri and hosted on github. Using its security vulnerability database for WordPress core, plugins and themes it will provide a report on your site’s known security problems which can be exploited by hackers.
You should check the updated guide for Ubuntu 18.04!
If you ever wondered how a hacker knows your WordPress username and is trying to guess the password by brute force, WPScan is probably the explanation. I will be explaining how this works and how to prevent it in upcoming posts.
Install WPScan dependencies for Ubuntu 16.04
Install the WPScan dependencies for WPScan.
sudo apt update
sudo apt install curl git libcurl4-openssl-dev make zlib1g-dev gawk g++ gcc libreadline6-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 autoconf libgdbm-dev libncurses5-dev automake libtool bison pkg-config ruby ruby-bundler ruby-dev -y
Enter your home directory and use git to pull the latest WPScan release.
cd ~
git clone https://github.com/wpscanteam/wpscan.git
Enter the WPScan folder and install the ruby dependencies.
cd wpscan
bundle install --without test
You should see something like this
Fetching source index from https://rubygems.org/
Resolving dependencies..............................
Installing addressable 2.4.0
Installing ffi 1.9.10 with native extensions
Installing mini_portile2 2.0.0
Installing ruby-progressbar 1.8.0
Installing terminal-table 1.4.5
Installing yajl-ruby 1.2.1 with native extensions
Using bundler 1.12.3
Installing ethon 0.9.0
Installing nokogiri 1.6.7.2 with native extensions
Installing typhoeus 1.0.2
Bundle complete! 10 Gemfile dependencies, 10 gems now installed.
Gems in the group test were not installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.
Now you have a wpscan.rb in ~/wpscan/
You can now run WPScan by being in the ~/wpscan/
folder.
Update the WP Scan vulnerability database first with this command
ruby wpscan.rb --update
You will see output like this
_______________________________________________________________
__ _______ _____
\ \ / / __ \ / ____|
\ \ /\ / /| |__) | (___ ___ __ _ _ __
\ \/ \/ / | ___/ \___ \ / __|/ _` | '_ \
\ /\ / | | ____) | (__| (_| | | | |
\/ \/ |_| |_____/ \___|\__,_|_| |_|
WordPress Security Scanner by the WPScan Team
Version 2.9.1
Sponsored by Sucuri - https://sucuri.net
@_WPScan_, @ethicalhack3r, @erwan_lr, pvdl, @_FireFart_
_______________________________________________________________
[i] Updating the Database ...
[i] Update completed.
Now scan your website with WPScan.
ruby wpscan.rb --url https://wp-bullet.com
You will see quite a lot of information. I will be posting a series of tutorials for nginx, Apache and Varnish that show how to block a lot of the information that WPScan gathers by making some configuration changes. Stay tuned!