🔐
EAkl Blog
  • 👋Welcome!
  • 🐛Web Application Findings
    • Cisco BroadWorks Vulnerabilities CVE-2021–34785 & CVE-2021–34786
    • Authentication bypass using empty parameters.
    • IDOR at Login function leads to leak user’s PII data
  • ℹ️Recon automation, tips and tricks
    • Simple Recon Methodology
    • How to write a simple script to automate finding bugs
  • 🔐Hack The Box Machines
    • Feline Walkthrough
    • Reel2 Walkthrough
    • Active Walkthrough
    • PopCorn Walkthrough
    • Jewel Walkthrough
    • Passage Walkthrough
    • Time Walkthrough
    • Devel Walkthrough
    • Lame Walkthrough
    • Beep Walkthrough
    • Blue Walkthrough
    • Jerry Walkthrough
    • Optimum Walkthrough
    • Grandpa Walkthrough
    • Legacy Walkthrough
    • Mirai Walkthrough
    • Valentine Walkthrough
    • Shocker Walkthrough
    • Netmon Walkthrough
    • Bank Walkthrough
    • Granny Walkthrough
    • Tabby Walkthrough
    • Access Walkthrough
    • Swagshop Walkthrough
    • OpenAdmin Walkthrough
    • Remote Walkthrough
    • Sauna Walkthrough
    • FriendZone Walkthrough
    • Hack The Box — Networked
    • Hack The Box — Forest
    • Hack The Box — WriteUP
    • Hack The Box — Academy
    • Hack The Box — Luanne
  • 🏴‍☠️CTF Challenges
    • CTF CyberTalents  — Bypass the world Writeup
    • CTF CyberTalents — Admin Gate First
    • CTF CyberTalents — Inbox
    • CTFlearn — Inj3ction Time
    • CTF ringzer0ctf — Challenge Access List
    • CTF ringzer0ctf — Login portal 2
    • CTF ringzer0ctf — SQLi challenges — part 1
    • CTF ringZer0ctf — Login form
  • 🔴Red Teaming Tips & Tricks
    • MOTW Defensive and Bypass techniques
  • ☁️Cloud Security
    • [Azure] Real Example to know different types of app concepts in Azure
    • [Azure] What To Do If?
Powered by GitBook
On this page
  1. CTF Challenges

CTFlearn — Inj3ction Time

PreviousCTF CyberTalents — InboxNextCTF ringzer0ctf — Challenge Access List

Last updated 2 years ago

Inj3ction Time writeup from CTFlearn — SQL injection

CTF CTFlearn — Inj3ction Time

All right! back again with new challenge from CTFlearn website:)

Let’s start quickly with challenge informations

From the description you’ll notice that there’s SQLi and you’ll use UNION query, the injection here is UNION based. Nice !

Open the website

You’ll find that there’s input field ID and you should enter numbers and then you’ll see information about the users, if you try to insert words you won’t get anything

Ok now we understand that the balance query will be nothing

Balance query character is ‘ or “ or ‘) or “) or nothing, this character is used to balance the query while injection

So let’s try to know number of columns

nothing → id=1 order by 1- -

nothing → id=1 order by 2- -

nothing → id=1 order by 3- -

main page, good → id=1 order by 4- -

The next step is to know what’s the vulnerable columns by

union select 1,2,3,4 —

So we now know that the vulnerable columns is 1,2 and 3, we will start to print the database info in this columns like

union select table_name,2,3 from information_schema.tables —

Nice! there’s many of tables but we’re searching about unique name so at the end of this list you’ll find interesting name

Yes! That’s we’re searching for, let’s search for a unique column

union select column_name,2,3 from information_schema.columns —

Nice! at the end of this list you’ll find …

Now we’ve table_name and column_name so try to get the data from this column

union select column_name from table_name—

Great ! We’ve the flag now.

Good Luck ❤

Challenge link

ID=2
Nothing returned with string inputs
🏴‍☠️
https://ctflearn.com/challenge/149