June 10, 2023, 11:46 a.m. | Sakis bal

DEV Community dev.to

Cover image by Pete Linforth





Table of Contents




  1. What is SQL injection


    1. A practical example of SQL injection




  2. SQLMap: Automated SQLi testing


    1. Routes protected by authorization

    2. Slowing down queries

    3. Enumerating the database




  3. Protecting against SQLi


    1. Prepared query

    2. Sanitize and escape user input



  4. Legally test SQLMap on intentionally injectable websites





What is SQL injection


SQL injection is a way for attackers to change the queries that interact with the database and "inject" their own queries. A typical example is a query …

applications authorization automated beginners database down escape injection input protecting query security sql sqli sql injection sqlmap test testing web web applications websites what is

Security Analysis Senior Analyst

@ NTT DATA | Bengaluru, KA, IN

SAP NS2 SIEM Engineering Manager - Herndon (Hybrid)

@ SAP | Herndon, VA, US, 20171

Security Architect - Infrastructure

@ Yorkshire Water | Bradford, GB

Information System Security Officer, Journeyman (Secret)

@ Resource Management Concepts, Inc. | Patuxent River, Maryland, United States

Technology Information Security GRC Senior

@ KPMG India | Gurgaon, Haryana, India

Principal CyberSecurity Engineer

@ DTCC | Dallas, TX, United States