Computer >> บทช่วยสอนคอมพิวเตอร์ >  >> ระบบเครือข่าย >> ความปลอดภัยเครือข่าย

Footprinting ในความปลอดภัยเครือข่าย: กระบวนการ เครื่องมือ และการป้องกัน

Footprinting (Reconnaissance) คืออะไร?

Footprinting (หรือ Reconnaissance / Information Gathering) เป็น ขั้นตอนแรกของ Kill Chain (MITRE ATT&CK: TA0043 Reconnaissance) ที่โจมตี (หรือ Penetration Tester) รวบรวมข้อมูลเกี่ยวกับเป้าหมาย (Target Organization) มากที่สุดเท่าที่จะทำได้ เพื่อวางแผนการโจมตีขั้นต่อไป (Scanning, Enumeration, Exploitation)

ข้อมูลที่รวบรวมใน Footprinting (What to Collect)

หมวดหมู่ข้อมูลเฉพาะแหล่งที่มา / เทคนิค
NetworkIP Ranges, ASN, Subdomains, DNS Records (A, MX, NS, TXT, SPF, DMARC), SSL Certs (CT Logs)Whois, Dig/nslookup, DNS Dumpster, SecurityTrails, Censys, Shodan, Crt.sh
Web/ApplicationTechnologies (Wappalyzer, BuiltWith), Directories, Files, Parameters, API Endpoints, JS Libraries, Git ReposCrawling (Burp, ZAP, Katana), Wayback Machine, GitHub/GitLab Search, Source Code Leaks
People/OrgEmployee Names, Emails, Roles, Phone, Social Media, Breached CredentialsLinkedIn, Hunter.io, Phonebook.cz, HaveIBeenPwned, Dehashed, Social-Analyzer
InfrastructureCloud Buckets (S3, Blob, GCS), Containers, Serverless, VPN/Remote Access Portals, Shadow ITCloud Enum, Grayhat Warfare, Shodan, Censys, Fofa, ZoomEye
Physical/SocialOffice Locations, Badge Systems, Waste (Dumpster Diving), Vendor RelationshipsOSINT, Physical Recon, Job Postings (Tech Stack), Tender Documents

ประเภทของ Footprinting

  • Passive Footprinting: ไม่ส่ง Traffic ตรงไปที่ Target — ใช้ Third-party Sources (Search Engines, DNS Archives, Certificate Transparency, Threat Intel Feeds, Social Media) — Stealthy, Hard to Detect
  • Active Footprinting: ส่ง Traffic ตรง Target — DNS Queries, HTTP Requests, Port Scans, Social Engineering Calls — Detectable by IDS/IPS/SIEM

เครื่องมือยอดนิยมสำหรับ Footprinting (Toolkit)

Passive / OSINT

  • Recon-ng, theHarvester, SpiderFoot, Maltego, OSINT Framework — Framework อัตโนมัติ
  • Shodan, Censys, Fofa, ZoomEye, BinaryEdge — Internet-wide Scanners (Internet Intelligence)
  • SecurityTrails, DNSDumpster, ViewDNS, Crt.sh, CertSpotter — DNS/SSL History
  • GitHub Dorks, GitLab Search, TruffleHog, GitLeaks — Source Code / Secrets Leaks
  • LinkedIn, Hunter.io, Phonebook.cz, RocketReach — People/Email Discovery

Active

  • Nmap (--script dns-*, ssl-*, http-*), Masscan (Fast Port Scan)
  • Gobuster, Feroxbuster, Dirsearch, Katana — Directory/File Bruteforce
  • Subfinder, Amass, Assetfinder, Findomain, Chaos — Subdomain Enumeration
  • Wappalyzer, BuiltWith, WhatRuns, Retire.js — Technology Fingerprinting

Footprinting ในมุมมองของ Penetration Tester / Red Teamer (Methodology)

  1. Scope Definition: Rules of Engagement (RoE), In-scope/Out-of-scope Assets
  2. Passive Recon: OSINT, Threat Intel, Public Records — Zero Touch
  3. Active Recon (Controlled): DNS Enum, Subdomain Enum, Port Scan (Top 1000/Full), Service Versioning
  4. Web App Recon: Crawl, Tech Stack, Directory Bruteforce, API Discovery, JS Analysis
  5. Cloud/Infra Recon: S3/Blob/GCS Enum, Kubernetes API, Metadata Services (IMDSv2)
  6. People Recon: Employee Enum, Breach Data, Social Media, Phishing Prep
  7. Documentation & Reporting: Attack Surface Map, Findings, Risk Rating, Recommendations

การป้องกันและลดทอน Attack Surface (Defense Against Footprinting)

Network & Infrastructure

  • จำกัด DNS Zone Transfer (AXFR) — อนุญาตเฉพาะ Authorized Secondary NS
  • ใช้ Split-Horizon DNS (Internal vs External Views) — ไม่ Expose Internal Hostnames
  • ลบ/ปิด DNS Records ที่ไม่จำเป็น (Internal Servers, Test/Dev/Staging Environments)
  • Monitor Certificate Transparency Logs (crt.sh, Facebook CT Monitor) → Alert หากมี Cert ใหม่สำหรับ Domain
  • Cloud Asset Inventory (Steampipe, CloudQuery, CloudSploit) → หา Public Resources ที่หลุด

Web Application

  • Robots.txt / Sitemap.xml — ไม่รายการ Admin/Debug/Internal Paths
  • Security Headers: Server: hidden, X-Powered-By: removed, CSP, HSTS
  • Error Pages: Generic (ไม่洩露 Stack Trace, Version, Path)
  • Rate Limiting / WAF Rules: บล็อก Automated Crawlers/Scanners (User-Agent, Behavior)
  • Remove .git, .svn, .env, backup files, test files จาก Production

People & Organization

  • Email Policy: ไม่ใช้ Format ที่เดาได้ง่าย (firstname.lastname@) → ใช้ Alias/Random
  • Social Media Policy: จำกัดข้อมูล Tech Stack, Internal Project, Badge Photos, Office Layout
  • Breach Monitoring: HaveIBeenPwned Domain Search, Dehashed, Commercial (SpyCloud, Intel 471)
  • Phishing Simulation + Training: ลดความเสี่ยง Social Engineering

Physical

  • Document Shredding / Secure Disposal
  • Visitor Management, Badge Control, Tailgating Prevention
  • Wi-Fi: Enterprise (802.1X) ไม่ใช่ PSK, Hidden SSID (Limited Value), NAC

Footprinting vs Fingerprinting

Footprinting (Reconnaissance)Fingerprinting (Service/OS Identification)
กว้าง: รวบรวมข้อมูลทั่วไปขององค์กรเฉพาะเจาะจง: ระบุ OS, Service Version, App Framework ของ Host/Service เดียว
Passive HeavyActive (Probes, Packets)
Output: Attack Surface MapOutput: CPE (Common Platform Enumeration), Version, Config Details

สรุป

Footprinting เป็น Foundation ของการโจมตีและการป้องกัน — ผู้ป้องกันต้องทำ Footprinting ให้กับตัวเอง (Continuous Attack Surface Management) เพื่อรู้ว่า "โจมตีเห็นอะไร" และลดทอนข้อมูลที่ไม่จำเป็นให้เหลือน้อยที่สุด เครื่องมือ: ASM Platforms (Randori, CyCognito, Hadrian, Ionix, Microsoft Defender EASM, Palo Alto Cortex Xpanse) + Manual OSINT + Automated Scanning + Human Analysis