Skip to content
Docker container for DVWA
Branch: master
Clone or download
Latest commit 4ec6823 Jun 6, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
Dockerfile Add php-gd Jun 5, 2018 Update Sep 23, 2014


Docker container for Damn Vulnerable Web Application (DVWA)

Quick start

Pull image: docker pull citizenstig/dvwa

Start with random mysql password: docker run -d -p 80:80 citizenstig/dvwa

Or specify it as environment variable: sudo docker run -d -p 80:80 -p 3306:3306 -e MYSQL_PASS="Chang3ME!" citizenstig/dvwa

Additional information about parent image

About DVWA

alt text


Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is damn vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, help web developers better understand the processes of securing web applications and aid teachers/students to teach/learn web application security in a class room environment.


Damn Vulnerable Web App is damn vulnerable! Do not upload it to your hosting provider's public html folder or any working web server as it will be hacked. I recommend downloading and installing XAMPP onto a local machine inside your LAN which is used solely for testing.

We do not take responsibility for the way in which any one uses Damn Vulnerable Web App (DVWA). We have made the purposes of the application clear and it should not be used maliciously. We have given warnings and taken measures to prevent users from installing DVWA on to live web servers. If your web server is compromised via an installation of DVWA it is not our responsibility it is the responsibility of the person/s who uploaded and installed it.


This file is part of Damn Vulnerable Web App (DVWA).

Damn Vulnerable Web App (DVWA) is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

Damn Vulnerable Web App (DVWA) is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with Damn Vulnerable Web App (DVWA). If not, see


DVWA is available either as a package that will run on your own web server or as a Live CD


Default username = admin

Default password = password

Installation video:

The easiest way to install DVWA is to download and install 'XAMPP' if you do not already have a web server setup.

XAMPP is a very easy to install Apache Distribution for Linux, Solaris, Windows and Mac OS X. The package includes the Apache web server, MySQL, PHP, Perl, a FTP server and phpMyAdmin.

XAMPP can be downloaded from:

Simply unzip, place the unzipped files in your public html folder, then point your browser to

Database Setup

To set up the database, simply click on the Setup button in the main menu, then click on the 'Create / Reset Database' button. This will create / reset the database for you with some data in.

If you receive an error while trying to create your database, make sure your database credentials are correct within /config/

The variables are set to the following by default:

$_DVWA[ 'db_user' ] = 'root';
$_DVWA[ 'db_password' ] = '';
$_DVWA[ 'db_database' ] = 'dvwa';


For the latest troubleshooting information please visit:

+Q. SQL Injection wont work on PHP version 5.2.6.

-A.If you are using PHP version 5.2.6 you will need to do the following in order for SQL injection and other vulnerabilities to work.

In .htaccess:


  <IfModule mod_php5.c>
    php_flag magic_quotes_gpc off
    #php_flag allow_url_fopen on
    #php_flag allow_url_include on


  <IfModule mod_php5.c>
    magic_quotes_gpc = Off
    allow_url_fopen = On
    allow_url_include = On

+Q. Command execution won't work.

-A. Apache may not have high enough priviledges to run commands on the web server. If you are running DVWA under linux make sure you are logged in as root. Under Windows log in as Administrator.

+Q. My XSS payload won't run in IE.

-A. If your running IE8 or above IE actively filters any XSS. To disable the filter you can do so by setting the HTTP header 'X-XSS-Protection: 0' or disable it from internet options. There may also be ways to bypass the filter.



Project Home:

Created by the DVWA team

You can’t perform that action at this time.