cd cd cs31/weeklylabs mkdir week07 cd week07 pwd cp ~newhall/public/cs31/week07/mystery .
Run the mystery binary a few times and see what it is doing:
./mysterythere is really not a lot of information to guess the right input, and this executable was not compiled with -g so there is no C code information we can get from it when we run it in gdb.
Let's see if we can examine the assembly code to see if we can figure out what to enter.
First, let's review some tools for examining and debuging binary files from last week: Week 6 Wed lab
Let's try some of these tools, let's look at the code in ddd.
ddd ./mystery (gdb) break main (gdb) run (gdb) disass
(gdb) x/s base_addr_of_string
strings ./mystery