Question Detail

COS 102 test topic Objective Question

Question

What is the primary vulnerability associated with using unbounded string read functions like `gets()` in C?
Options
A Buffer overflow
Correct Answer
B Memory fragmentation
C Integer underflow
D Type mismatch
Correct Answer

Option A is the correct answer.

Detailed Explanation

Unbounded string functions do not check input boundaries against buffer limits, enabling malicious or accidental memory overwrites.

Hint

No hint available

Question Info