A baseline methodology for assessing a web application's security posture, from reconnaissance through reporting. Suitable as a starting point for most black-box or grey-box web app engagements.
Enumerate subdomains, exposed endpoints, and technologies in use before any active testing begins.
1. Run subdomain enumeration against the target's apex domain (Gobuster DNS mode or equivalent). 2. Resolve each discovered subdomain and record live hosts. 3. Fingerprint technologies (framework, server, CMS) via response headers and page source. 4. Check certificate transparency logs for additional subdomains missed by brute force. 5. Document the full attack surface: hosts, ports, and technologies identified.
Brute-force hidden directories, files, and API routes not linked from the visible application.
1. Run directory brute-forcing against the target with a standard wordlist (Gobuster dir mode). 2. Repeat with common backup/config file extensions (.bak, .old, .env, .git). 3. Check for exposed API documentation (Swagger/OpenAPI, GraphQL introspection). 4. Manually crawl the application to capture endpoints missed by automated tools. 5. Compile a full endpoint inventory for use in later testing phases.
Test the login flow for weak lockout policy, credential enumeration, and MFA bypass.
1. Attempt login with an invalid username and observe the error message for enumeration leakage. 2. Test account lockout policy with repeated failed attempts (Hydra, low thread count, non-destructive). 3. Check password reset flow for token predictability or user enumeration. 4. If MFA is present, test for bypass via response manipulation or backup-code brute force. 5. Verify password complexity and history requirements are enforced server-side.
Check session token entropy, fixation, and secure cookie flags.
1. Capture a session token post-login and assess length/entropy. 2. Test for session fixation: set a token pre-login, confirm it's not reused post-login. 3. Verify Secure, HttpOnly, and SameSite flags are set on session cookies. 4. Confirm session invalidation on logout (token rejected after logout, not just cleared client-side). 5. Check for session timeout after a reasonable period of inactivity.
Test all input points for SQL injection, XSS, and command injection.
1. Identify all input points: form fields, URL parameters, headers, and JSON body fields. 2. Test each for SQL injection using both error-based and time-based blind payloads (SQLmap). 3. Test each for reflected and stored XSS using standard payload sets. 4. Test any input reaching a shell/OS command for command injection. 5. Confirm findings manually before recording - automated scanners produce false positives.
Test functionality that fetches remote resources for SSRF against internal services and cloud metadata endpoints.
1. Identify features that accept a URL or trigger a server-side fetch. 2. Test with an internal IP (127.0.0.1, 169.254.169.254) to check for SSRF. 3. If cloud-hosted, attempt to reach the cloud metadata endpoint for credential exposure. 4. Test for protocol smuggling (file://, gopher://) where the fetcher isn't scheme-restricted. 5. Document any internal service or metadata reachable from the vulnerable input.
Verify horizontal and vertical privilege boundaries between user roles.
1. Create two accounts of the same role and attempt to access each other's resources by ID. 2. Create accounts of different roles and attempt to access higher-privilege functionality. 3. Test direct object references (IDs in URLs/APIs) for sequential guessability. 4. Verify server-side enforcement, not just UI-level hiding of restricted actions. 5. Test API endpoints independently of the UI - access control gaps often differ between the two.
Test REST/GraphQL endpoints for broken object-level authorization, mass assignment, and injection.
1. Enumerate all API endpoints via documentation, introspection, or crawling. 2. Test each endpoint for authentication/authorization bypass (BOLA). 3. Attempt mass assignment by adding unexpected fields (e.g. "role": "admin") to write requests. 4. If GraphQL, test introspection exposure and nested query depth abuse. 5. Verify rate limiting is enforced on sensitive endpoints (login, password reset, OTP).
Check CORS policy, CSP, HSTS, and other response security headers.
1. Send a request with an arbitrary Origin header and check if it's reflected in Access-Control-Allow-Origin. 2. If reflected with Allow-Credentials: true, confirm this as a real cross-origin data exposure. 3. Review Content-Security-Policy for overly permissive directives (unsafe-inline, wildcard sources). 4. Confirm HSTS is set with an adequate max-age on all HTTPS responses. 5. Check X-Content-Type-Options, X-Frame-Options/frame-ancestors are present.
Test for workflow bypasses, race conditions, and price/quantity manipulation.
1. Map the intended business workflow (e.g. cart -> checkout -> payment -> confirmation). 2. Attempt to skip or reorder steps in the workflow directly via API calls. 3. Test for race conditions by sending concurrent requests to state-changing endpoints (e.g. redeem-once coupons). 4. Test for negative values, decimal quantities, or currency manipulation in pricing fields. 5. Document any logic flaw that produces an outcome the application didn't intend to allow.
Review JavaScript for exposed secrets and vulnerable third-party dependencies.
1. Review all loaded JavaScript files for hardcoded API keys, tokens, or internal URLs. 2. Identify third-party libraries in use and check their versions against known CVEs. 3. Review source maps if exposed - they can reveal unminified source and comments. 4. Check for sensitive data exposed in client-side storage (localStorage, sessionStorage). 5. Document any secret or vulnerable dependency found, with its exact location.
Consolidate all findings with evidence, severity, and remediation guidance.
1. Compile all confirmed findings from the above items into a single report. 2. Assign a severity to each finding (Critical/High/Medium/Low/Info) based on impact and exploitability. 3. Attach evidence (screenshots, request/response pairs) for each finding. 4. Write remediation guidance specific to each finding, not generic advice. 5. Review the report for false positives before delivery.