Common Vulnerabilities: OWASP Top 10

Learn the most common web application risks, how attackers exploit them and the standard defenses.

Intermediate · about 8 hours · difficulty 3/5

Learn first: Writing SQL Queries, Authorization: Roles and Permissions

The OWASP Top 10 is a regularly updated list of the most critical web application security risks. It is the shared vocabulary of security reviews and interviews.

The risks you must be able to explain and prevent

  • Broken access control: IDOR, missing checks on admin routes. Defense: deny by default, server-side checks, tests.
  • Injection (SQL, NoSQL, OS command, LDAP): user input interpreted as code. Defense: parameterized queries, avoid shelling out, validate input.
  • Cross-site scripting (XSS): attacker script runs in other users' browsers. Defense: output encoding, templating that escapes by default, CSP.
  • Cryptographic failures: plain HTTP, weak hashing, secrets in code.
  • Security misconfiguration: default credentials, verbose error pages with stack traces, open cloud buckets.
  • Vulnerable and outdated components: old dependencies with known CVEs. Defense: npm audit, Dependabot or Renovate, and actually merging updates.
  • Identification and authentication failures: no rate limiting, weak password policies, broken session handling.
  • SSRF (server-side request forgery): your server fetches a URL the attacker controls, reaching internal services like cloud metadata endpoints. Defense: allowlists, block private IP ranges.
  • Insecure design, integrity failures (unsigned updates, unsafe deserialization) and logging and monitoring failures.

Habits that prevent most issues

Validate input at boundaries, encode output, use proven libraries, keep dependencies current, apply least privilege and log security-relevant events.

You are ready to move on when you can exploit and then fix SQL injection, XSS and IDOR in a deliberately vulnerable practice app such as OWASP Juice Shop.

Key concepts

  • Broken access control
  • Injection attacks
  • Cross-site scripting (XSS)
  • SSRF
  • Dependency scanning
  • Security misconfiguration
  • Unsafe deserialization
  • OWASP Juice Shop practice

Mini project

Run OWASP Juice Shop locally, complete five beginner challenges, then audit your own project against the Top 10 and fix at least two findings.

Check yourself

Your service fetches a user-supplied image URL. What could an attacker do with that, and how do you prevent it?

Free resources