Skip to content

Latest commit

 

History

History

assembly-0

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

assembly-0

Points: 150

Category

Reversing

Question

What does asm0(0xc9,0xb0) return? Submit the flag as a hexadecimal value (starting with '0x'). NOTE: Your submission for this question will NOT be in the normal flag format. Source located in the directory at /problems/assembly-0_4_0f197369bfc00a9211504cf65ac31994.

Hint

basical assembly tutorial

assembly registers

Solution

In assembly, the return value is always eax

asm0:
	push	ebp
	mov	ebp,esp
	mov	eax,DWORD PTR [ebp+0x8]
	mov	ebx,DWORD PTR [ebp+0xc]
	mov	eax,ebx
	mov	esp,ebp
	pop	ebp	
	ret

eax has value 0xc9 and ebx has value 0xb0. As the value of eax is replaced with ebx when mov eax,ebx is executed, the returned value is 0xb0.

Flag

0xb0