Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Bomb Lab I have a bomb lab that requires an input string that needs to pass the cmp's and jumps where needed to skip over

Bomb Lab I have a bomb lab that requires an input string that needs to pass the cmp's and jumps where needed to skip over the ignite_bomb. I would like some help on. From what I have figured out so far, the input doesn't matter, it just matters what the size of the input is (I think...). Dump of assembler code for function phase_4: 0x0000000000401334 <+0>: sub $0xd8,%rsp 0x000000000040133b <+7>: mov %rdi,%rsi 0x000000000040133e <+10>: mov $0x97db1bdc,%eax 0x0000000000401343 <+15>: mov %rax,0x50(%rsp) 0x0000000000401348 <+20>: movw $0xc40,0x3c(%rsp) 0x000000000040134f <+27>: movw $0x7ad,0x3e(%rsp) 0x0000000000401356 <+34>: movl $0x6ee30ae,0x38(%rsp) 0x000000000040135e <+42>: movb $0xf,0x40(%rsp) 0x0000000000401363 <+47>: movq $0x0,0x48(%rsp) 0x000000000040136c <+56>: movw $0x6f74,0x20(%rsp) 0x0000000000401373 <+63>: movb $0x0,0x22(%rsp) 0x0000000000401378 <+68>: lea 0x20(%rsp),%rdi 0x000000000040137d <+73>: callq 0x40119e 0x0000000000401382 <+78>: movzwl 0x3e(%rsp),%eax 0x0000000000401387 <+83>: cmp $0x5b72,%ax 0x000000000040138b <+87>: je 0x401392 0x000000000040138d <+89>: callq 0x401b42 0x0000000000401392 <+94>: movzbl 0x40(%rsp),%eax 0x0000000000401397 <+99>: cmp $0x45,%al 0x0000000000401399 <+101>: je 0x4013a0 0x000000000040139b <+103>: callq 0x401b42 0x00000000004013a0 <+108>: mov 0x50(%rsp),%rdx 0x00000000004013a5 <+113>: mov $0x97db1bdc,%eax 0x00000000004013aa <+118>: cmp %rax,%rdx 0x00000000004013ad <+121>: je 0x4013b4 0x00000000004013af <+123>: callq 0x401b42 0x00000000004013b4 <+128>: mov 0x48(%rsp),%rax 0x00000000004013b9 <+133>: test %rax,%rax 0x00000000004013bc <+136>: je 0x4013c3 0x00000000004013be <+138>: callq 0x401b42 0x00000000004013c3 <+143>: movzwl 0x3c(%rsp),%eax 0x00000000004013c8 <+148>: mov 0x38(%rsp),%edx 0x00000000004013cc <+152>: movzwl %ax,%eax 0x00000000004013cf <+155>: shl $0x9,%eax 0x00000000004013d2 <+158>: add %edx,%eax 0x00000000004013d4 <+160>: cmp $0x3e87ab72,%eax 0x00000000004013d9 <+165>: sete %al 0x00000000004013dc <+168>: movzbl %al,%eax 0x00000000004013df <+171>: add $0xd8,%rsp 0x00000000004013e6 <+178>: retq Then when the callq@+73 enters the function strcat, this is the code: Dump of assembler code for function strcat: 0x000000000040119e <+0>: mov %rdi,%rax 0x00000000004011a1 <+3>: cmpb $0x0,(%rdi) 0x00000000004011a4 <+6>: je 0x4011b4 0x00000000004011a6 <+8>: mov %rdi,%rdx 0x00000000004011a9 <+11>: add $0x1,%rdx 0x00000000004011ad <+15>: cmpb $0x0,(%rdx) 0x00000000004011b0 <+18>: jne 0x4011a9 0x00000000004011b2 <+20>: jmp 0x4011b7 0x00000000004011b4 <+22>: mov %rdi,%rdx 0x00000000004011b7 <+25>: movzbl (%rsi),%ecx 0x00000000004011ba <+28>: test %cl,%cl 0x00000000004011bc <+30>: je 0x4011d0 0x00000000004011be <+32>: add $0x1,%rdx 0x00000000004011c2 <+36>: add $0x1,%rsi 0x00000000004011c6 <+40>: mov %cl,-0x1(%rdx) 0x00000000004011c9 <+43>: movzbl (%rsi),%ecx 0x00000000004011cc <+46>: test %cl,%cl 0x00000000004011ce <+48>: jne 0x4011be 0x00000000004011d0 <+50>: movb $0x0,(%rdx) 0x00000000004011d3 <+53>: retq

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Management An Organizational Perspective

Authors: Richard T. Watson

1st Edition

0471305340, 978-0471305347

More Books

Students also viewed these Databases questions

Question

Using FIFO, what is the ending balance in inventory

Answered: 1 week ago