FlashGenius Logo FlashGenius
GWAPT Objectives 2 & 3 • SANS SEC542

Reconnaissance, Mapping
& Configuration Testing

Passive and active recon, web crawling, HTTP security headers, SSL/TLS testing, CORS, and configuration flaws β€” everything for the GIAC Web Application Penetration Tester exam.

82
Exam Questions
71%
Passing Score
3 hrs
Exam Duration
4 yrs
Cert Validity
Page 2 of 8 Objectives

GWAPT Exam Overview

This page covers Objectives 2 & 3 of 8 GWAPT exam objectives: Reconnaissance & Mapping, and Web Application Configuration Testing. Know before you attack β€” reconnaissance defines your target surface; configuration testing reveals the low-hanging fruit that poor setup leaves behind.

Exam Profile

GWAPT
Certification
82
Questions
3 hrs
Duration
71%
Pass Score
4 yrs
Validity
SEC542
SANS Training

CyberLive Format

GWAPT uses GIAC's CyberLive format β€” a live lab environment with real tools alongside traditional multiple-choice questions. You will use real web application penetration testing tools during the exam. Practice with actual tools, not just theory.

All 8 GWAPT Exam Objectives

#ObjectiveThis Page
1Web Application Overviewβ€”
β˜… 2Reconnaissance and Mappingβœ“ Covered
β˜… 3Web Application Configuration Testingβœ“ Covered
4Web Application Authentication Attacksβ€”
5Web Application Session Managementβ€”
6Web Application SQL Injection Attacksβ€”
7Cross-Site Request Forgery, XSS & Client Injection Attacksβ€”
8Web Application Testing Toolsβ€”

What This Page Teaches

πŸ” Passive Reconnaissance

WHOIS, DNS enumeration, Google dorking, Shodan, Certificate Transparency logs, Wayback Machine, and OSINT techniques β€” all without touching the target.

⚑ Active Reconnaissance

Port scanning with nmap, service fingerprinting, web crawling with Burp Suite, directory brute-forcing with Gobuster/FFuF, and application flow mapping.

πŸ›‘οΈ HTTP Security Headers

X-Frame-Options, X-Content-Type-Options, Content-Security-Policy, HSTS, Referrer-Policy β€” testing for presence, correctness, and common misconfigurations.

πŸ” SSL/TLS & Config Flaws

Weak protocol versions (POODLE, BEAST), weak cipher suites, testssl.sh, default credentials, directory listing, CORS misconfiguration, and sensitive file exposure.

πŸ’‘ Study Strategy for Objectives 2 & 3

These objectives are foundational to every subsequent attack phase. Memorize the Google dork operators, know the DNS record types cold, and practice the curl commands for testing headers. The CyberLive component means you must be comfortable running testssl.sh, gobuster, and dig commands hands-on.

Objective 2

Reconnaissance and Mapping

A1 β€” Passive Reconnaissance

Passive recon gathers information about the target without making any direct contact. All techniques below are legal even without written authorization β€” you are only observing publicly available data.

WHOIS Lookup

Queries domain registration databases for registrant name, organization, email, registrar, name servers, and creation/expiry dates.

  • Command: whois target.com
  • Reveals: registrant contact info, name servers (NS records), registration dates
  • Privacy-protected registrations (e.g., Domains By Proxy) may hide personal data

DNS Enumeration

  • A β€” IPv4 address mapping
  • AAAA β€” IPv6 address mapping
  • MX β€” Mail exchange servers (reveals email provider)
  • NS β€” Authoritative name servers
  • TXT β€” SPF, DKIM, domain verification tokens
  • CNAME β€” Canonical name alias (e.g., www β†’ app.target.com)
  • SOA β€” Start of Authority, zone information
  • Zone Transfer (AXFR): dig axfr @ns1.target.com target.com β€” if the server is misconfigured, returns ALL DNS records at once. A critical finding.
  • Subdomain discovery tools: dnsenum, sublist3r, amass, dnsrecon

Google Dorking (Google Hacking)

Advanced search operators to find sensitive information indexed by Google without touching the target server.

  • site:target.com filetype:pdf β€” find exposed documents
  • site:target.com inurl:admin β€” find admin pages
  • site:target.com intitle:"index of" β€” find directory listings
  • site:target.com ext:sql OR ext:bak β€” find backup/database files
  • "target.com" "password" β€” find leaked credentials
  • Mnemonic: SIFIE β€” Site, Inurl, Filetype, Intitle, Ext

Shodan

Search engine for internet-connected devices. Indexes banners, service versions, open ports, and TLS certificates. Use hostname:target.com to find exposed services without probing directly.

  • Reveals: open ports, server software versions, exposed IoT devices, vulnerable systems
  • Can find staging/dev servers not publicly linked

Certificate Transparency (CT) Logs β€” crt.sh

Every SSL/TLS certificate issued by a public CA must be logged in Certificate Transparency logs. crt.sh lets you search these logs by domain, revealing all issued certificates and β€” critically β€” all subdomains the organization has certificates for.

  • Query: https://crt.sh/?q=%.target.com
  • Reveals subdomains including internal, staging, and test servers

Wayback Machine / Archive.org

Historical snapshots of web pages. Find removed functionality, old endpoints, credentials committed to old config files, former staff directories, and legacy API versions.

  • Pentest use: find endpoints that were removed from the live site but may still be active on the server

Job Postings & LinkedIn/GitHub

Job postings reveal technology stack ("experience with AWS RDS PostgreSQL"). LinkedIn reveals employee names, roles, and potential usernames. GitHub searches may expose API keys, credentials in code, or internal architecture details.


A2 β€” Active Reconnaissance

Authorization Required

Active reconnaissance makes direct contact with the target. Always obtain written authorization (Rules of Engagement) before proceeding. Unauthorized port scanning can violate laws including the CFAA.

Port Scanning with nmap

  • nmap -sV -p- target.com β€” all 65535 ports, version detection
  • nmap -sC -sV -p 80,443,8080,8443,8888 target.com β€” common web ports with default scripts
  • nmap --script http-enum target.com β€” web enumeration NSE script
  • Common web ports: 80 (HTTP), 443 (HTTPS), 8080 (alt HTTP/proxy), 8443 (alt HTTPS), 3000 (Node.js), 8888 (Jupyter)
  • nmap -O β€” OS detection via TCP/IP stack fingerprinting

Service Fingerprinting

nmap -sV sends version probes to identify server software and versions. Banner grabbing (reading the server's initial response) also works: curl -I https://target.com. Look for headers like Server: Apache/2.4.41 and X-Powered-By: PHP/7.4.3.


A3 β€” Web Crawling and Spidering

robots.txt and sitemap.xml

  • robots.txt: instructs crawlers which paths to avoid (Disallow:). For pentesters, disallowed paths are highly interesting β€” they often contain admin panels, staging areas, or sensitive functionality
  • sitemap.xml: site structure map revealing all intended public pages

Burp Suite Crawler

Automated discovery of links, forms, API endpoints, and hidden parameters. Enable the Burp proxy first so all manual browsing is captured. Burp's Spider follows links within scope settings.

Directory and File Brute Force

  • Gobuster: gobuster dir -u http://target.com -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt
  • FFuF: fast fuzzer, supports multiple wordlist dimensions
  • DirBuster: GUI-based, Java tool from OWASP
  • Common interesting paths: /admin, /login, /api, /backup, /.git, /config, /phpinfo.php, /wp-admin

A4 β€” Application Flow Mapping

Entry Points to Map

  • URL parameters
  • Form fields (GET and POST)
  • HTTP headers and cookies
  • File upload endpoints
  • API endpoints (REST/GraphQL)
  • WebSocket connections

Technology Fingerprinting

  • Server: header β€” web server
  • X-Powered-By: β€” framework
  • Cookie names: PHPSESSID (PHP), JSESSIONID (Java), ASP.NET_SessionId (.NET), connect.sid (Node.js)
  • Error pages, comments, meta tags
  • Wappalyzer (browser extension)
  • BuiltWith β€” detailed stack analysis

Session Token Initial Analysis

  • Identify session mechanism: cookies vs. URL parameters vs. localStorage vs. JWT
  • Examine Set-Cookie flags: HttpOnly, Secure, SameSite, domain/path scope
  • Check for token predictability: sequential values, timestamp-based, short length
  • Burp Sequencer: capture many tokens, analyze statistical entropy/randomness

Objective 3

Web Application Configuration Testing

B1 β€” HTTP Security Headers

Test with: curl -I https://target.com β€” check for presence and correct values of each header.

X-Frame-Options

Prevents clickjacking by controlling whether the page can be embedded in an iframe.

  • DENY β€” no embedding anywhere
  • SAMEORIGIN β€” only same-origin embedding
  • Superseded by CSP frame-ancestors but still widely tested on the exam

X-Content-Type-Options: nosniff

Prevents the browser from MIME-type sniffing β€” the browser must use the declared Content-Type. Prevents certain XSS attacks via file upload (e.g., uploading a JS file declared as image/png).

Content-Security-Policy (CSP)

Defines allowed sources for scripts, styles, images, fonts, frames, etc. β€” the most powerful XSS mitigation header.

  • script-src 'self' β€” only same-origin scripts
  • default-src 'none' β€” deny everything not explicitly allowed
  • Misconfigurations to flag: 'unsafe-inline', 'unsafe-eval', wildcard sources (*)
  • CSP bypass research: check csp-evaluator.withgoogle.com

HSTS (Strict-Transport-Security)

Forces browsers to connect only via HTTPS for the specified duration. Prevents SSL stripping attacks.

  • Full value: max-age=31536000; includeSubDomains; preload
  • Without HSTS: an attacker can strip HTTPS from the first request (SSLstrip)
  • Without preload: only protects after the user visits once via HTTPS

Other Security Headers

  • Referrer-Policy: controls Referer header content sent to other origins (prevents leaking paths/tokens)
  • Permissions-Policy (formerly Feature-Policy): restricts browser API access (camera, geolocation, microphone)
  • X-XSS-Protection: legacy header, deprecated in modern browsers; value: 1; mode=block. Don't rely on it.

B2 β€” SSL/TLS Testing

Testing Tools

  • testssl.sh: comprehensive CLI TLS scanner β€” testssl.sh target.com. Tests protocols, ciphers, certificates, and known vulnerabilities.
  • SSLyze: Python-based SSL/TLS scanner with JSON output
  • Qualys SSL Labs: online scanner, grades A–F (not available during authorized testing without disclosing scan)

Issues to Test For

  • Expired or self-signed certificates β€” no browser trust, MITM possible
  • SSLv2 / SSLv3 (POODLE) β€” both should be disabled; SSLv3 enables POODLE attack
  • TLS 1.0 (POODLE for TLS) β€” deprecated in 2020, still vulnerable
  • TLS 1.1 β€” deprecated, should not be offered
  • Weak ciphers: RC4 (BEAST/broken), DES/3DES (SWEET32), NULL ciphers, export ciphers (FREAK/LOGJAM), anonymous DH ciphers (no server auth)
  • Missing HSTS: enables SSL stripping
  • Certificate chain issues: missing intermediate certs, wrong CN/SAN mismatch

B3 β€” Default Credentials and Admin Interfaces

Common Admin Paths

  • /admin, /administrator
  • /wp-admin (WordPress)
  • /phpmyadmin (MySQL admin)
  • /manager/html (Apache Tomcat)
  • /console (JBoss/WildFly)
  • /actuator (Spring Boot)

Default Credentials to Test

  • admin / admin
  • admin / password
  • admin / 123456
  • root / root
  • tomcat / tomcat
  • Credential list: SecLists /Passwords/Default-Credentials/

B4 β€” Directory Listing

How It's Enabled (and How to Test)

  • Apache: Options +Indexes in .htaccess β€” enables browsing the file system
  • Nginx: autoindex on directive
  • Test: navigate to a directory without an index file β€” if a file listing is shown, it's a misconfiguration
  • Risk: exposes backup files, configuration files, source code, and log files to unauthenticated users

B5 β€” Verbose Error Messages

What Errors Reveal

  • Stack traces: framework name/version, file paths (e.g., /var/www/html/app.php:42), database type
  • Database errors: DB type, table/column names, full SQL query structure
  • Internal IP addresses leaked in error messages
  • Test: submit a single quote ('), invalid data types, extra-long inputs β€” observe responses
  • Mitigation: custom error pages, disable debug mode in production (APP_DEBUG=false)

B6 β€” HTTP Method Testing

Methods to Test

  • curl -X OPTIONS https://target.com -i β€” check Allow: response header
  • curl -X TRACE https://target.com -i β€” TRACE should be disabled (Cross-Site Tracing / XST attack)
  • PUT enabled: potential for unauthorized file write (upload a web shell)
  • DELETE enabled: unauthorized deletion of files
  • WebDAV methods: PROPFIND, MKCOL β€” if WebDAV is enabled, often exploitable for file upload

B7 β€” Sensitive File Exposure

Files and Paths to Check

  • Backup extensions: .bak, .old, .orig, ~ (Unix backup), .swp (vim swap) β€” e.g., index.php.bak
  • Source code exposure: /.git/HEAD, /.git/config β€” if .git directory is publicly accessible, full source code can be reconstructed
  • Config files: config.php, web.config, .env, database.yml, settings.py, application.properties
  • Log files: error.log, access.log, debug.log
  • Mnemonic: Backup Old Environments Git Swap (.bak, .old, .env, .git, .swp)

B8 β€” CORS Misconfiguration

Cross-Origin Resource Sharing Vulnerabilities

  • Wildcard origin: Access-Control-Allow-Origin: * β€” browsers block cookies with wildcard, but API-key authenticated APIs can still be abused
  • Reflected origin: server echoes back whatever Origin: header it receives β€” allows any site to make credentialed requests (most severe)
  • Null origin: Access-Control-Allow-Origin: null β€” an iframe in sandbox mode can send a null origin and gain access
  • CORS test: send Origin: https://attacker.com header and check if response contains Access-Control-Allow-Origin: https://attacker.com and Access-Control-Allow-Credentials: true
Mnemonics & Mental Models

Memory Hooks

Six high-yield hooks that collapse complex topics into memorable patterns. Each maps to testable exam content.

πŸ‘οΈ
Hook 1 β€” Recon Types
Passive = looking through windows without touching the door
Active = knocking and listening for a response. Passive recon uses only publicly available data (WHOIS, Google, Shodan, CT logs). Active recon sends packets to the target β€” always requires written authorization. The distinction is critical for the GWAPT exam.
πŸ”Ž
Hook 2 β€” Google Dork Operators
SIFIE: Site, Inurl, Filetype, Intitle, Ext
Site β€” restrict to domain | Inurl β€” find in URL path | Filetype β€” find file extensions | Intitle β€” search page titles | Ext β€” alternate for filetype. Combine: site:target.com ext:sql finds exposed database dumps.
πŸ›‘οΈ
Hook 3 β€” Security Headers
eXtra Careful Headers Reduce Risk
X-Frame-Options (clickjacking) | X-Content-Type-Options (MIME sniff) | Content-Security-Policy (script/style sources) | HSTS (force HTTPS) | Referrer-Policy (URL leakage). Test with curl -I and check for absence of each.
🐩
Hook 4 β€” Weak TLS Protocols
SSL3 POODLEs TLS1 Too
SSLv2 (broken), SSLv3 (POODLE attack), TLS 1.0 (POODLE-variant), TLS 1.1 (deprecated) β€” all should be disabled. Only TLS 1.2 and TLS 1.3 are currently acceptable. testssl.sh checks all of these automatically.
πŸͺž
Hook 5 β€” CORS Reflected Origin
Mirror Mirror on the wall, who's the most vulnerable of all?
When the server echoes back whatever Origin header it receives (Access-Control-Allow-Origin: https://attacker.com + Access-Control-Allow-Credentials: true), any attacker site can read the response. The mirror metaphor: if the server just reflects your origin back, it trusts anyone.
πŸ’Ύ
Hook 6 β€” Sensitive File Extensions
Backup Old Environments Git Swap
Backup (.bak) | Old (.old) | Environments (.env) | Git (/.git/) | Swap (.swp vim swap files). Always test these extensions on any discovered filename. index.php.bak exposing source code is a classic finding.

Exam Tip: Frameworks and Cookie Names

Memorize: PHPSESSID = PHP, JSESSIONID = Java, ASP.NET_SessionId = .NET, connect.sid = Node.js/Express. These appear in scenario questions asking you to identify the technology stack from an HTTP response.

10 Vignette Questions

Scenario Quiz

GWAPT-style scenario questions covering Objectives 2 & 3. Each question mirrors real exam phrasing. Read the scenario carefully before selecting.

8 Flip Cards

Flashcards

Click any card to flip it and reveal the answer.

DNS Zone Transfer (AXFR)
What does it reveal, and when is it a finding?
↩ tap to flip
A zone transfer replicates all DNS records from the primary name server. When misconfigured to allow transfers from any host, running dig axfr @ns1.target.com target.com reveals all DNS records at once β€” subdomains, internal IPs, mail servers, staging hosts. A successful unauthenticated AXFR is a critical finding.
robots.txt
What is the security implication for pentesters?
↩ tap to flip
robots.txt lists paths that crawlers are instructed to skip. The irony: disallowed paths are exactly what pentesters want to find β€” they often contain admin panels, staging environments, old APIs, or sensitive functionality the developer didn't want indexed. Always check /robots.txt early in recon.
Content-Security-Policy (CSP)
Purpose and most common misconfiguration?
↩ tap to flip
CSP defines which origins can serve scripts, styles, images, and other resources β€” the primary XSS mitigation header. The most dangerous misconfigurations: 'unsafe-inline' (allows inline scripts, negating XSS protection), 'unsafe-eval' (allows eval()), and wildcard * sources (allows any origin). A CSP with these is essentially no protection.
HSTS (Strict-Transport-Security)
What attack does it prevent, and how?
↩ tap to flip
HSTS prevents SSL stripping attacks (SSLstrip). Once a browser receives an HSTS header (max-age=31536000), it will refuse to connect via plain HTTP for that domain for the specified duration. Without HSTS, an attacker can MITM the first HTTP request and strip the HTTPS redirect. includeSubDomains extends protection to all subdomains; preload bakes it into the browser binary.
CORS Reflected Origin Vulnerability
How do you identify it, and what's the impact?
↩ tap to flip
Send a request with Origin: https://attacker.com. If the response includes Access-Control-Allow-Origin: https://attacker.com AND Access-Control-Allow-Credentials: true, the server reflects origins without validation. Impact: a malicious site can make credentialed cross-origin requests and read responses β€” effectively bypassing the Same-Origin Policy for authenticated API calls.
X-Frame-Options
Which attack does it prevent, and what are its values?
↩ tap to flip
X-Frame-Options prevents clickjacking β€” an attack where a transparent iframe overlays a legitimate page, tricking users into clicking on hidden controls. Values: DENY (no iframe embedding at all) or SAMEORIGIN (only same-origin pages can embed it). Superseded by CSP frame-ancestors but still widely deployed and tested.
testssl.sh
What does it test, and how do you use it?
↩ tap to flip
testssl.sh target.com β€” comprehensive TLS/SSL scanner that tests: supported protocol versions (SSLv2/3, TLS 1.0–1.3), cipher suite strength, certificate validity and chain, known vulnerabilities (POODLE, BEAST, HEARTBLEED, FREAK, LOGJAM, ROBOT, SWEET32), HSTS presence, and more. Output is color-coded: green = OK, yellow = warn, red = critical.
Certificate Transparency Logs (crt.sh)
How do pentesters use this for recon?
↩ tap to flip
Every publicly trusted TLS certificate must be logged in Certificate Transparency logs. Searching crt.sh for %.target.com reveals every subdomain with a certificate β€” including internal, staging, dev, and test servers the organization may have forgotten about. This is passive recon (no direct contact) that often reveals more attack surface than any active scan.
Topic Readiness

Study Advisor

Select a topic category to see key points, exam traps, and a self-reported readiness tracker.

Passive Reconnaissance Techniques

  • WHOIS reveals registrant, registrar, name servers, and dates β€” no packets sent to target
  • DNS record types: A, AAAA, MX, NS, TXT, CNAME, SOA β€” know each purpose cold
  • Zone transfer (AXFR): dig axfr @ns1.target.com target.com β€” if it works, critical finding
  • Subdomain tools: amass, dnsenum, sublist3r, dnsrecon
  • Google dork mnemonic: SIFIE β€” Site, Inurl, Filetype, Intitle, Ext
  • Shodan: find exposed services by hostname without touching target (hostname:target.com)
  • crt.sh: CT log search β€” reveals all subdomains with SSL certs, completely passive
  • Wayback Machine: find removed endpoints still active on the server
  • GitHub/LinkedIn OSINT: find tech stack hints, employee usernames, leaked credentials
Self-reported readiness
0%

Active Recon & Web Crawling

  • nmap: -sV = version detection, -sC = default scripts, -p- = all ports, -O = OS detection
  • Common web ports: 80, 443, 8080 (alt HTTP/proxy), 8443, 3000 (Node.js), 8888 (Jupyter)
  • nmap --script http-enum: NSE script for web enumeration β€” finds common paths
  • Burp Suite: enable proxy before manual browsing; Spider follows links within scope
  • robots.txt disallowed paths = interesting targets for pentesters
  • Gobuster: gobuster dir -u http://target.com -w wordlist.txt
  • Technology identification: Server header, X-Powered-By, cookie names (PHPSESSID, JSESSIONID, ASP.NET_SessionId, connect.sid)
  • Burp Sequencer: statistical entropy analysis of session tokens
  • Map all entry points: URL params, forms, headers, cookies, file uploads, APIs, WebSockets
Self-reported readiness
0%

HTTP Security Headers

  • Test command: curl -I https://target.com β€” check for absence of security headers
  • X-Frame-Options: DENY or SAMEORIGIN β€” prevents clickjacking
  • X-Content-Type-Options: nosniff β€” prevents MIME sniffing XSS
  • CSP: most powerful; look for unsafe-inline, unsafe-eval, * as bypasses
  • HSTS: prevents SSL stripping; check for includeSubDomains and preload
  • Referrer-Policy: prevents URL/token leakage via Referer header
  • Permissions-Policy: restricts browser API access (camera, geo, mic)
  • X-XSS-Protection: legacy and deprecated β€” don't rely on it
  • Mnemonic: eXtra Careful Headers Reduce Risk (XFO, XCTO, CSP, HSTS, Referrer)
Self-reported readiness
0%

SSL/TLS Configuration Testing

  • testssl.sh target.com β€” comprehensive TLS scanner, color-coded output
  • SSLyze β€” Python-based, JSON output, good for automation
  • Weak protocols: SSLv2 (broken), SSLv3 (POODLE), TLS 1.0 (POODLE-TLS), TLS 1.1 (deprecated)
  • Acceptable: TLS 1.2 (with strong ciphers) and TLS 1.3
  • Weak ciphers: RC4 (BEAST), DES/3DES (SWEET32), NULL, export ciphers (FREAK/LOGJAM), anon DH
  • Mnemonic: SSL3 POODLEs TLS1 Too
  • Certificate issues: expired, self-signed, wrong CN/SAN, missing intermediate cert
  • HSTS not set = SSL stripping attack possible
  • Know the attack names: POODLE, BEAST, FREAK, LOGJAM, SWEET32, HEARTBLEED, ROBOT
Self-reported readiness
0%

Configuration Flaws

  • Default credentials: admin/admin, admin/password, tomcat/tomcat β€” check SecLists
  • Admin paths: /admin, /wp-admin, /phpmyadmin, /manager/html, /actuator
  • Directory listing: Apache Options +Indexes or Nginx autoindex on β€” browse without index file to test
  • Verbose errors: submit single quote or invalid input and observe stack traces
  • HTTP TRACE: curl -X TRACE should return 405 Method Not Allowed, not a 200
  • PUT/DELETE enabled: potential for web shell upload or file deletion
  • Sensitive files: mnemonic Backup Old Environments Git Swap
  • CORS: reflected origin + credentials = any site can read your API responses
  • Null CORS origin: iframe in sandbox mode can exploit this
Self-reported readiness
0%
Official & Reference Links

Resources

Curated references for GWAPT Objectives 2 & 3. Verify all links directly β€” URLs can change.

CyberLive Prep

For the live lab component, practice these exact commands until they are second nature: dig axfr, nmap -sV -sC, gobuster dir, curl -I, curl -X OPTIONS, curl -X TRACE, and testssl.sh. The exam environment will have these tools available.

FlashGenius Study Platform

Ready to Pass GWAPT?

Join FlashGenius for the full GWAPT series β€” all 8 objectives with vignette quizzes, flashcards, and hands-on command references.

Start Free → Official GWAPT Page