Skip to content
Web Design & Development

Web Application Security Basics: The Decisions That Matter

The defenses every web application needs regardless of what it does: input handling, output encoding, authentication, authorization, transport security and dependency hygiene.

MediaScaleUp Editorial Team 2 min read 13 views
Web Application Security Basics: The Decisions That Matter

Why does it matter?

The commonest breaches exploit well-documented, decades-old categories of mistake, which means most of the risk is addressable with known, boring measures rather than novel ones.

What are the numbers?

  • Reference list the OWASP Top Ten, revised periodically
  • Transport HTTPS everywhere, with HSTS once you are confident
  • Injection defense parameterised queries, never string concatenation
  • Cross-site scripting defense contextual output encoding, plus a Content Security Policy
  • Cross-site request forgery defense anti-forgery tokens and SameSite cookies
  • Dependency risk known vulnerabilities in third-party packages

What should I do?

  1. Parameterise every database query without exception
  2. Encode output for the context it lands in rather than sanitizing input once and hoping
  3. Check authorization on the server for every request, not just in the interface
  4. Keep dependencies patched and know what you are running
  5. Set security headers, including a Content Security Policy you have actually tested
What to do and what to avoid with web application security basics, side by side
Good practice against the usual mistakes, from the sources listed below.

What should I avoid?

Avoid:

  • Trusting anything the client sends, including hidden fields and prices
  • Rolling your own authentication or cryptography
  • Leaving debug mode on in production, which prints credentials into error pages
  • Treating a penetration test as a substitute for secure defaults

When should I get help?

Short answer Bring in help immediately after any suspected breach, before handling payments or special category personal data, or when dependencies have gone unpatched long enough that nobody knows what is exposed.

Where this comes from

The figures and practices above come from the sources listed.

Working on something like this?

We take on Web Design & Development work for teams who want it done once, properly. Tell us what you are building and we will tell you honestly whether we are the right studio for it. Start a project.

Where to go next

Spotted something wrong? Report an error on this page. We correct on the page and say what changed.

All services

The work behind this article, and what it costs.

MediaScaleUp Editorial Team

Articles here are researched, written and checked by the MediaScaleUp studio team before they are published, and dated when they are reviewed.

Keep reading

More in Web Design & Development