EC-Council
312-92 · Question #96
What type of problem or error will result from the following statement? void f2b(void arg, size_t len) { char buffer[100]; long val = ...; long ptr = ...; extern void (f)(); memcpy(buff, arg, len)…
The correct answer is A. Pointer subterfuge. See the full explanation below for the reasoning.
Question
What type of problem or error will result from the following statement? void f2b(void * arg, size_t len) { char buffer[100]; long val = ...; long *ptr = ...; extern void (*f)(); memcpy(buff, arg, len); *ptr = val; f(); return; }
Options
- APointer subterfuge
- BHeap smashing
- CVirtual pointer smashing
- DSign error
How the community answered
(13 responses)- A85% (11)
- B8% (1)
- D8% (1)
Community Discussion
No community discussion yet for this question.