The problem

A public store attracts attacks and login abuse, and each release can take it offline. Behind a proxy, the server can also lose track of the real visitor, so login limits fail.

What I did

  • Configured Cloudflare DDoS protection and restricted the server to Cloudflare traffic
  • Verified the real visitor behind the proxy and limited login-code attempts
  • Split storefront, API and worker processes; a failed build never restarts them

Security controls by layer.

  1. Edge
    CloudflareDDoS protection · request filtering
  2. Origin
    Restrict origin accessTrusted proxy · HTTPS · origin restrictions
  3. Request identity
    Verify signed assertionsBackend checks the signed IP, site, and timestamp
  4. Account protection
    Limit email-code requestsIP + email limits · cooldown · attempts · expiry
Edge filtering and origin restrictions protect the entry points. The backend verifies signed request identity, while email-code requests have their own limits and expiry checks.

Need the same?