Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Binary Bomb Lab - Phase 2: (x86 assembly) I know that this stage takes an input of 6 numbers (ex. 1 2 3 4 5

Binary Bomb Lab - Phase 2: (x86 assembly)

I know that this stage takes an input of 6 numbers (ex. 1 2 3 4 5 6). The first number is one. I get confused reading the assembly and can't figure out the other steps using the gdb. Could someone translate the assembly and explain the code in simple terms for me, please?

image text in transcribed

read_six_numbers function:

image text in transcribed

400f73: 400f74: 400f77 400f79: 400f7a push mov push push sub Lea callq pl je callq lea lea mov add p je callq 48 89 e5 41 54 53 48 83 ec 20 48 8d 75 de %rbp %rsp, %rbp %r12 %rbx $6x29 , % rsp -0x39 (%rbp) ,%rsi 40f82 : 40f87 : 400f8b: 400f8d: 400f92: 400f96: 400f9a: 400f9c 400f9e: 400fal: 400fa3: 400fa8: 400fac: 400faf: 400fbl: 400fb5: 400fb6: 400fb8: 400fb9: 4016a4 $8x1,-9x39 (%rbp) 488f92 74 05 e8 dc 06 00 00 48 8d 5d de 4c 8d 63 14 40166e -9x39 (%rbp), %rbx 6x14(%rbx ) ,%r12 (%rbx) ,%eax %eax, %eax %eax,6x4 (%rbx) 400fa8 39 43 04 74 05 40166e add $0x4, srbx 48 83 c3 4 4c 39 e3 75 e9 48 83 c4 2 5b 41 5c 5d C3 %r12 ,%rbx 400f9a $8x29 , % rsp cmp jne add pop pop pop retq %r12 400f73: 400f74: 400f77 400f79: 400f7a push mov push push sub Lea callq pl je callq lea lea mov add p je callq 48 89 e5 41 54 53 48 83 ec 20 48 8d 75 de %rbp %rsp, %rbp %r12 %rbx $6x29 , % rsp -0x39 (%rbp) ,%rsi 40f82 : 40f87 : 400f8b: 400f8d: 400f92: 400f96: 400f9a: 400f9c 400f9e: 400fal: 400fa3: 400fa8: 400fac: 400faf: 400fbl: 400fb5: 400fb6: 400fb8: 400fb9: 4016a4 $8x1,-9x39 (%rbp) 488f92 74 05 e8 dc 06 00 00 48 8d 5d de 4c 8d 63 14 40166e -9x39 (%rbp), %rbx 6x14(%rbx ) ,%r12 (%rbx) ,%eax %eax, %eax %eax,6x4 (%rbx) 400fa8 39 43 04 74 05 40166e add $0x4, srbx 48 83 c3 4 4c 39 e3 75 e9 48 83 c4 2 5b 41 5c 5d C3 %r12 ,%rbx 400f9a $8x29 , % rsp cmp jne add pop pop pop retq %r12

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

Relational Database Design With Microcomputer Applications

Authors: Glenn A. Jackson

1st Edition

0137718411, 978-0137718412

More Books

Students also viewed these Databases questions

Question

Classify delivery styles by type.

Answered: 1 week ago