Question: 12) Consider the following C code fragment. ( int func (int i, double *aatal, double data2) { } double p datal; double *vec [10];

12) Consider the following C code fragment. ( int func (int i, double *aatal, double data2) { } double p datal; double *vec [10]; if ((i 10)) return; vec[i] datal; *p data2; a) Explain why this code is vulnerable to a control hijacking attack. Briefly explain how your attack works. b) If this code is compiled with Stackguard, will the overflow attack be prevented? c) If this code is compiled with Stackshield, will the overflow attack be prevented? d) If this code is compiled with Libsafe, will the overflow attack be prevented?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
