Q13 of 24 · Security
How does rigorous boundary and negative testing form a layer of security validation?
Short answer
Short answer: Injection and overflow vulnerabilities are triggered at the edges of expected input. A QA team that practises thorough boundary testing — minimum/maximum lengths, type boundaries, unexpected characters, null inputs — is simultaneously performing a partial security test without needing security expertise.
Detail
The overlap between quality testing and security testing is significant at the input validation layer. Both disciplines test what happens when the application receives unexpected input — they just have different goals (quality wants a graceful error; security wants to confirm the input doesn't bypass a control or trigger a vulnerability).
Boundary tests that double as security tests:
- Field length limits: a text field with no maximum length can accept a 10 MB string, potentially causing a Denial of Service or a buffer overflow in downstream processing. Assert a reasonable maximum is enforced.
- Type confusion: submitting a number field with a string value, a date field with SQL syntax, a boolean field with a long string. Each exercises the server's input parsing under unexpected conditions.
- Character sets: submitting Unicode, null bytes (
%00), newlines (in form fields can inject HTTP headers), and special characters (angle brackets, quotes) reveals whether the application handles them safely. - Integer boundaries: submitting
-1,0,2147483647(INT_MAX), and2147483648(INT_MAX + 1) for numeric IDs and quantities. Negative quantities in a shopping cart should not result in a refund.
The framing for the interview: boundary testing is not just about handling edge cases gracefully — it's about validating that the application's input processing is safe under all inputs, not just expected ones. A QA engineer who thinks about "what would happen if I submitted 10,000 characters here?" is thinking like a security tester.