Assignments

Assignment 1

Extra resources

Assignment 2

Extra resources

Assignment 3

Extra resources

Initializing an array with a fixed value

The below code will initialize the whole of array with the value 0.

unsigned char array[SIZE] = {0};

Unfortunately, I was mistaken, and this only works for zero! Setting other values will only set that value for the first element and the rest will still be zero.

If you want to set a value on the whole array, try using memset:

memset(array, 0, SIZE);

Assignment 4

Extra resources

Thom’s hacking utilities

These scripts can help you do some menial stuff, like printing addresses in little-endian order, as demonstrated in the lecture. Follow the instructions in the README.md to install them.

Assignment 5

The last homework assignment will be a bit different from the previous ones. I have spent the last weeks creating a website to host “capture the flag” style hacking challenges, which is where I will run the graded challenges on. I demoed it a little bit in the lecture.

This week we traditionally have the remote buffer overflow challenge, which more or less asks of you to do the same thing as I did in the lecture. You can submit your write-up through the site as well.

Sign up at https://hackme.rded.nl. You will need to fill in your student number and you can only sign up once. Please terminate your running processes after you’re done with them. This weeks homework is completing the two challenges that are posted there.

Extra resources