← QA Library
Chapter 10 / 19 · 8 min read

Security testing basics

The most common web vulnerabilities, how a QA engineer can check for them safely, and where professional penetration testing begins.

Security is a quality characteristic like any other, and many serious vulnerabilities are found by ordinary testers who simply ask “what if I'm not supposed to be able to do this?”. You don't need to be a hacker to catch the most common problems — you need curiosity, DevTools and a clear understanding of what the system should forbid.

Only test systems you are authorised to test, and only in test environments. Security checks against someone else's production system without permission are illegal in most countries.

The most common weaknesses

The OWASP Top 10 is a widely used list of the most critical web application risks. In everyday QA work, these are the ones you meet most often:

RiskWhat goes wrongA simple tester's check
Broken access controlUsers reach data or actions that aren't theirsChange an ID in the URL or API request; open admin URLs as a regular user
InjectionUser input is executed as code or a queryEnter quotes, <script> tags and SQL fragments in fields; check they are shown as text
Authentication failuresWeak login, sessions that never expireBrute-force limits, logout really ends the session, password reset links expire
Sensitive data exposureSecrets or personal data leakLook at API responses in DevTools for extra fields: password hashes, emails of others, tokens
Security misconfigurationDebug pages, default passwords, verbose errorsTrigger errors and check no stack traces or server versions appear
Vulnerable componentsOld libraries with known holesAsk whether dependency scanning runs in CI

Access control: the tester's favourite

Most applications check permissions in the interface but forget to check them on the server. Hiding a button is not security. A practical routine:

  1. Prepare two users with different roles (for example, a customer and an admin) and two customers with their own data.
  2. As user A, perform an action and copy the request from DevTools (right-click → Copy as cURL).
  3. Replay it with user B's session, or change the object ID to one that belongs to user A.
  4. Expected result: 403 or 404 and no data. Anything else is a critical bug.

Input handling

Every field that accepts text is a potential entry point. Try values like these and check that the application stores and shows them literally, without breaking the page or the query:

<script>alert(1)</script>
"><img src=x onerror=alert(1)>
' OR '1'='1
Robert'); DROP TABLE students;--
../../etc/passwd
{{7*7}}

If an alert pops up, the page layout breaks, or {{7*7}} turns into 49, report it immediately. These are signs that input reaches places where it is interpreted as code.

Sessions, cookies and headers

  • Session cookies should have HttpOnly, Secure and a sensible SameSite value
  • After logout, pressing Back or replaying an old request must not show private data
  • Changing a password should end other active sessions
  • Responses should include basic security headers such as Content-Security-Policy, Strict-Transport-Security and X-Content-Type-Options
  • Error pages must not reveal stack traces, SQL queries or server versions

Tools

ToolUse
Browser DevToolsInspect requests, cookies, storage, headers
OWASP ZAPFree proxy and scanner for web applications
Burp Suite (Community)Intercept and modify requests
Dependency scanners (npm audit, Dependabot, Snyk)Known vulnerabilities in libraries
Security headers checkersQuick review of HTTP response headers

Where QA ends and pentesting begins

Testers cover the basics continuously: access control, input handling, sessions, configuration. Systems that handle payments, health or other sensitive data also need regular professional penetration tests and code audits. The two complement each other — everyday checks catch regressions between audits.

The most valuable security question a tester can ask is simple: “Should this user be able to do this?” Then check that the server, not just the interface, says no.