Pentest & Audit 2026-10-10 9 min READ

Website Security: Complete Protection & Vulnerability Checklist for 2026

A comprehensive defense-in-depth security checklist for web applications in 2026. Hardening web servers, reverse proxies, APIs, databases, SSL/TLS, and modern frontend delivery.

S By Site Check Security Team

In 2026, web application security is no longer an afterthought solved by generic plugins or automated default TLS certificates. The threat landscape has evolved into an industrialized ecosystem of automated botnets, AI-assisted zero-day probes, and continuous reconnaissance engines that scan newly registered domains and deployments within minutes of DNS propagation.

True cyber resilience requires an architectural Defense-in-Depth approach: establishing redundant security barriers across network boundaries, reverse proxies, application runtimes, and persistence layers. If an attacker breaches one boundary, subsequent defensive layers must strictly contain lateral movement and prevent unauthorized data exfiltration.

1. Edge & Reverse Proxy Hardening (Nginx & Cloudflare)

Your edge reverse proxy represents the primary gateway to your digital infrastructure. Default web server configurations frequently expose system versions, directory indices, and critical administrative assets. A production-grade Nginx configuration must disable server version tokens, block directory traversal, and immediately terminate requests targeting hidden dotfiles.

Important Note: Always return HTTP 404 instead of 403 when blocking sensitive endpoints like /.env or /.git. Returning 403 confirms file existence to automated reconnaissance scanners, whereas 404 simulates complete absence.
Hardened perimeter block in Nginx
                  # /etc/nginx/conf.d/security.conf

# Terminate server version disclosures
server_tokens off;
autoindex off;

# Block access to hidden dotfiles (.env, .git, .aws, etc.)
location ~ /\.(?!well-known) {
    deny all;
    access_log off;
    log_not_found off;
    return 404;
}

# Reject requests with invalid HTTP methods
if ($request_method !~ ^(GET|HEAD|POST|PUT|DELETE|OPTIONS)$ ) {
    return 405;
}
                

2. Modern Transport Security (TLS 1.3 & HSTS Preloading)

Transport Layer Security must be tuned to eliminate obsolete cryptographic algorithms. Enforce TLS 1.2 and TLS 1.3 exclusively, deprecating vulnerable CBC ciphers and RSA key exchange in favor of forward-secret ECDHE suites. Enable HTTP Strict Transport Security (HSTS) with preloading to guarantee browsers never downgrade to unencrypted HTTP.

High-security SSL/TLS configuration directives
                  # Strict Transport Security & TLS 1.3 Ciphers
ssl_protocols TLSv1.2 TLSv1.3;
ssl_prefer_server_ciphers off;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305;

# HSTS header with 2-year duration and preload commitment
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;
                

3. Network Isolation & Database Port Exposure

A catastrophic pattern in modern cloud setups is binding database daemons (PostgreSQL on 5432, MongoDB on 27017, Redis on 6379) directly to 0.0.0.0. Persistence services must never listen on public network interfaces. Bind databases exclusively to 127.0.0.1 or isolated virtual private cloud (VPC) subnets with strict firewall rules.

Important Note: Docker by default modifies iptables rules directly, often bypassing local host firewall configurations (UFW). Verify your Docker Compose port mappings use '127.0.0.1:5432:5432' rather than '5432:5432' to prevent accidental public exposure.

4. Mandatory HTTP Security Headers

HTTP security headers provide immediate browser-level protection against Cross-Site Scripting (XSS), Clickjacking, and MIME-type confusion attacks. Deploy Content-Security-Policy (CSP), X-Frame-Options: DENY, X-Content-Type-Options: nosniff, and a restrictive Permissions-Policy to curtail unauthorized browser feature invocation.

Recommended baseline HTTP security headers
                  add_header X-Frame-Options "DENY" always;
add_header X-Content-Type-Options "nosniff" always;
add_header Referrer-Policy "strict-origin-when-cross-origin" always;
add_header Permissions-Policy "camera=(), microphone=(), geolocation=(), payment=()" always;
add_header Content-Security-Policy "default-src 'self'; script-src 'self' 'unsafe-inline' https:; style-src 'self' 'unsafe-inline'; img-src 'self' data: https:; font-src 'self' data:; connect-src 'self' https:; frame-ancestors 'none';" always;
                

5. Frontend Supply Chain & Client-Side Token Auditing

Modern single-page applications and static frontends frequently bundle sensitive third-party tokens during build time. Audit your compiled JavaScript artifacts to ensure no private OpenAI, Stripe secret, or database superuser keys leaked into public scripts. Strip source maps (*.map) from public production web roots.

Important Note: Integrate pre-commit hooks and CI/CD secret detection scanners (such as Gitleaks or TruffleHog) to block secrets from ever entering your Git repository history.

Developer Security Checklist

  • ✓ Enforce HTTP to HTTPS 301 redirection with HSTS preloading
  • ✓ Block public HTTP access to dotfiles (/.env, /.git, /.aws) returning 404
  • ✓ Bind database services strictly to localhost (127.0.0.1) or internal VPC networks
  • ✓ Deploy Content-Security-Policy (CSP) with restrictive script-src and frame-ancestors directives
  • ✓ Disable verbose stack traces and debug banners in production environments
  • ✓ Run regular non-destructive vulnerability scans with Site Check

Security Auditor Synthesis & Key Takeaways

When shipping production web applications and vibe-coded projects built on modern stacks (Next.js, Astro, React, Supabase), perimeter security cannot be an afterthought. Over 85% of customer data leaks and database compromises do not stem from sophisticated zero-day exploits, but rather from trivial misconfigurations: orphaned staging endpoints, exposed environment files, overly permissive CORS policies, and disabled Row Level Security (RLS) rules.

Automated perimeter scanning with Site Check proactively catches these signatures across 36 critical attack vectors, equipping engineering teams and vibe-coders with immediate actionable remediation guides before automated scanning botnets discover the exposed endpoints.