This feed contains pages with tag "valgrind".
Getting started.
copy the files from /fcs/courses/cs2023/tutorial4 to some directory underneath your home directory.
Valgrind and dynamic array overflow
compile heapover.c with
gcc -o heapover -g heapover.c
run it.
now run it with
valgrind ./heapover
finally run it with
valgrind --db-attach=yes ./heapover
repeat these steps with shadow.c. What do you observe about the ability of valgrind to localize uninitialized variable use, compared to illegal writes?
GCC stack protector
compile stackover.c with
gcc -o stackover -g stackover.c
run it.
now compile with
gcc -o stackover -g -fstack-protector-all stackover.c
run it again