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,

 

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

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!