Function at 0x40945f
Capabilities:
Read file on windows

Disassembly:
push ebp
sub esp, 0x84
lea ebp, [esp - 4]
mov eax, dword [0x45a90c]
xor eax, ebp
mov dword [ebp + 0x84], eax
push 0xc0
mov eax, 0x448635
call fcn.00433228
mov eax, dword [ebp + 0x98]
mov edi, dword [ebp + 0x94]
xor ebx, ebx
push ebx
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x18], eax
call dword [sym.imp.ole32.dll_CoInitialize]
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x3e8
mov dword [edi], ebx
call esi
lea ecx, [ebp - 0x6c]
call fcn.004093bd
lea ecx, [ebp - 0x6c]
mov dword [ebp - 4], ebx
call fcn.0040927b
test eax, eax
jne 0x40950c
push 0x40f
push dword [ebp - 0x18]
call fcn.00403c89
push 0x3ee
push dword [ebp - 0x18]
mov esi, eax
call fcn.00403c89
add esp, 0x10
push 0x10
mov edi, eax
push edi
push esi
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
push esi
call fcn.00430bc7
push edi
call fcn.00430bc7
pop ecx
pop ecx
call dword [sym.imp.ole32.dll_CoUninitialize]
jmp 0x409d52
lea ecx, [ebp - 0x48]
call fcn.004093df
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 1
call fcn.004092cb
test eax, eax
jne 0x409569
push 0x411
push dword [ebp - 0x18]
call fcn.00403c89
push 0x3ee
push dword [ebp - 0x18]
mov esi, eax
call fcn.00403c89
add esp, 0x10
push 0x10
mov edi, eax
push edi
push esi
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
push esi
call fcn.00430bc7
push edi
call fcn.00430bc7
pop ecx
pop ecx
call dword [sym.imp.ole32.dll_CoUninitialize]
jmp 0x409d47
push 2
lea eax, [ebp]
push eax
lea ecx, [ebp - 0x48]
call fcn.0040dc4c
mov dword [ebp - 0x74], ebx
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x9c]
mov byte [ebp - 4], 2
call fcn.00409431
mov eax, dword [ebp + 0x90]
cmp eax, ebx
mov byte [ebp - 4], 3
jl 0x4095b3
inc eax
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x74]
push eax
lea ecx, [ebp - 0x9c]
call fcn.0040934a
dec dword [ebp - 0x2c]
jne 0x40959f
lea eax, [ebp - 0x74]
push eax
lea ecx, [ebp - 0x48]
call fcn.00409310
push dword [ebp - 0x48]
lea ecx, [ebp - 0x64]
call fcn.0040939e
mov dword [ebp - 0x1c], ebx
push 0xc8
mov dword [ebp - 0x54], ebx
mov dword [ebp - 0x50], ebx
mov dword [edi], 1
mov dword [ebp - 0x7c], 2
call esi
lea eax, [ebp - 0x54]
push eax
push ebx
push 0x1012
push ebx
mov byte [ebp - 4], 6
call dword [sym.imp.ole32.dll_StgCreateDocfile]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x40961e
mov dword [ebp - 0xa0], str.Failed_Creating_temp
push 0x45408c
lea eax, [ebp - 0xa0]
push eax
call fcn.00432dc3
mov dword [edi], 2
mov dword [ebp - 0x3c], ebx
mov eax, dword [ebp - 0x3c]
cmp eax, 0x64
jge 0x40965d
mov dword [ebp - 0x24], ebx
add eax, 0x1388
push eax
push dword [ebp - 0x18]
mov byte [ebp - 4], 7
call fcn.00403d4b
mov esi, eax
pop ecx
pop ecx
cmp esi, ebx
jne 0x4096a4
mov eax, dword [ebp - 0x24]
mov byte [ebp - 4], 6
cmp eax, ebx
je 0x40965d
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
push 0xc8
mov dword [edi], 3
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 0x50]
push eax
push ebx
push 0x1012
push ebx
call dword [sym.imp.ole32.dll_StgCreateDocfile]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x409791
mov dword [ebp - 0xa8], str.Failed_Creating_tempboot
push 0x45408c
lea eax, [ebp - 0xa8]
jmp 0x409618
push 0x44baf7
push esi
call fcn.004342e0
pop ecx
pop ecx
test eax, eax
je 0x40964c
push esi
call fcn.0040922f
pop ecx
lea edx, [ebp - 0x24]
push edx
push ebx
push ebx
mov edi, eax
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax]
push 0x1011
push edi
push eax
call dword [ecx + 0xc]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x4096f4
mov dword [ebp - 0xb0], str.Failed_creating_stream
push 0x45408c
lea eax, [ebp - 0xb0]
jmp 0x409618
push esi
call fcn.00430bc7
push edi
call fcn.00430bc7
lea eax, [ebp - 0x30]
push eax
mov eax, dword [ebp - 0x3c]
add eax, 0x13ec
push eax
push dword [ebp - 0x18]
call fcn.00403d80
add esp, 0x14
push ebx
push ebx
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 4
pop edi
mov dword [ebp - 0x2c], edi
xor esi, esi
cmp esi, dword [ebp - 0x30]
jge 0x409775
push ebx
lea eax, [ebp - 0x2c]
push eax
push edi
lea eax, [ebp - 0x58]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax]
add esi, 4
cmp esi, dword [ebp - 0x30]
lea edx, [ebp - 0x80]
push edx
jle 0x409768
mov edx, dword [ebp - 0x30]
and edx, 0x80000003
jns 0x409765
dec edx
or edx, 0xfffffffc
inc edx
push edx
jmp 0x40976b
push dword [ebp - 0x2c]
lea edx, [ebp - 0x58]
push edx
push eax
call dword [ecx + 0x10]
jmp 0x40972c
mov eax, dword [ebp - 0x24]
mov byte [ebp - 4], 6
cmp eax, ebx
je 0x409786
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
inc dword [ebp - 0x3c]
mov edi, dword [ebp - 0x78]
jmp 0x409627
mov eax, dword [ebp - 0x50]
mov ecx, dword [eax]
lea edx, [ebp - 0x1c]
push edx
push ebx
push ebx
push 0x1011
push str.bootimg
push eax
call dword [ecx + 0xc]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x4097cb
mov dword [ebp - 0xac], str.Failed_creating_stream
push 0x45408c
lea eax, [ebp - 0xac]
jmp 0x409618
mov esi, 0x1400000
push esi
mov dword [ebp - 0x2c], 4
mov dword [ebp - 0x24], ebx
call fcn.00430ca4
push 1
push esi
push eax
mov dword [ebp - 0x80], eax
call fcn.0040c5a9
add esp, 0x10
mov dword [ebp - 0x30], eax
push 0x271a
lea eax, [ebp - 0x40]
push eax
push dword [0x45c068]
push dword [ebp - 0x18]
push dword [ebp - 0x30]
call fcn.0040d167
add esp, 0x14
cmp dword [ebp - 0x40], 0x168000
jbe 0x40988b
lea eax, [ebp - 0x24]
push eax
push 0x2717
push dword [ebp - 0x18]
call fcn.00403d80
add esp, 0xc
push ebx
push ebx
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [ebp - 0x7c], 4
xor esi, esi
cmp esi, dword [ebp - 0x24]
jge 0x40988b
push ebx
lea eax, [ebp - 0x2c]
push eax
push 4
lea eax, [ebp - 0x58]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax]
add esi, 4
cmp esi, dword [ebp - 0x24]
lea edx, [ebp - 0x3c]
push edx
jle 0x40987e
mov edx, dword [ebp - 0x24]
and edx, 0x80000003
jns 0x40987b
dec edx
or edx, 0xfffffffc
inc edx
push edx
jmp 0x409881
push dword [ebp - 0x2c]
lea edx, [ebp - 0x58]
push edx
push eax
call dword [ecx + 0x10]
jmp 0x409841
cmp dword [ebp - 0x30], ebx
je 0x40989a
mov ecx, dword [ebp - 0x30]
mov eax, dword [ecx]
push 1
call dword [eax + 0x1c]
mov esi, dword [ebp - 0x80]
xor eax, eax
cmp eax, dword [ebp - 0x40]
jae 0x4098e2
lea ecx, [eax + 4]
cmp ecx, dword [ebp - 0x40]
mov dword [ebp - 0x30], ecx
mov ecx, dword [ebp - 0x1c]
jbe 0x4098cb
mov edx, dword [ebp - 0x40]
lea esi, [ebp - 0x3c]
push esi
mov esi, dword [ebp - 0x80]
and edx, 3
push edx
add eax, esi
push eax
mov eax, dword [ecx]
push ecx
call dword [eax + 0x10]
jmp 0x4098dd
mov ecx, dword [ecx]
lea edx, [ebp - 0x3c]
push edx
push dword [ebp - 0x2c]
add eax, esi
push eax
push dword [ebp - 0x1c]
call dword [ecx + 0x10]
mov eax, dword [ebp - 0x30]
jmp 0x40989f
push esi
call fcn.00430bc7
mov eax, dword [ebp - 0x24]
add dword [ebp - 0x40], eax
pop ecx
cmp dword [ebp - 0x1c], ebx
je 0x4098fe
push ebx
lea eax, [ebp - 0x1c]
push eax
call fcn.004091fe
mov eax, dword [ebp - 0x50]
mov ecx, dword [eax]
lea edx, [ebp - 0x1c]
push edx
push ebx
push 0x10
push ebx
push str.bootimg
push eax
call dword [ecx + 0x10]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x409935
mov dword [ebp - 0xb4], str.Failed_Opening_BootStream
push 0x45408c
lea eax, [ebp - 0xb4]
jmp 0x409618
mov eax, dword [ebp - 0x64]
lea edx, [ebp - 0x20]
push edx
mov dword [ebp - 0x20], ebx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x1c]
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
lea edx, [ebp - 0x4c]
push edx
push eax
call dword [ecx + 0x2c]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
lea edx, [ebp - 0xa4]
push edx
lea edx, [ebp - 0xc8]
push edx
xor esi, esi
inc esi
push esi
push eax
call dword [ecx + 0xc]
cmp eax, ebx
jne 0x409a86
push 8
lea eax, [ebp - 0x38]
push ebx
push eax
call fcn.00432990
mov eax, dword [ebp - 0xc4]
add esp, 0xc
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x20]
push esi
mov dword [ebp - 0x38], esi
mov ecx, dword [eax]
push eax
call dword [ecx + 0xc]
cmp dword [ebp - 0x34], 4
mov dword [ebp - 0x28], eax
jne 0x4099ce
push 2
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
mov eax, esi
push edx
mov word [ebp - 0x8c], ax
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
push esi
push eax
call dword [ecx + 0x10]
cmp dword [ebp - 0x34], 5
jne 0x4099f5
mov eax, dword [ebp - 0x20]
push 2
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
push esi
mov dword [ebp - 0x8c], str.Miray
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
cmp dword [ebp - 0x34], 6
jne 0x409a18
mov eax, dword [ebp - 0x20]
push 2
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
push esi
mov byte [ebp - 0x8c], bl
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
cmp dword [ebp - 0x34], 7
jne 0x409a3e
mov al, byte [ebp - 0x7c]
push 2
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
mov byte [ebp - 0x8c], al
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
push esi
push eax
call dword [ecx + 0x10]
cmp dword [ebp - 0x34], 8
jne 0x409952
mov eax, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x1c]
mov esi, dword [ecx]
lea edx, [ebp - 0x84]
push edx
lea edx, [ebp - 0x5c]
push edx
xor edx, edx
push edx
push eax
push dword [ebp - 0x8c]
push ecx
call dword [esi + 0x1c]
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
push 2
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
push 1
push eax
call dword [ecx + 0x10]
jmp 0x409952
mov eax, dword [ebp - 0x64]
push dword [ebp - 0x20]
mov ecx, dword [eax]
push eax
call dword [ecx + 0x20]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x409ab3
mov dword [ebp - 0xb8], str.Failed_SetJolietProperties
push 0x45408c
lea eax, [ebp - 0xb8]
jmp 0x409618
mov eax, dword [ebp - 0x64]
mov ecx, dword [eax]
lea edx, [ebp - 0x20]
push edx
push eax
call dword [ecx + 0x1c]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
lea edx, [ebp - 0x4c]
push edx
push eax
call dword [ecx + 0x2c]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
lea edx, [ebp - 0xa4]
push edx
lea edx, [ebp - 0xc8]
push edx
push esi
push eax
call dword [ecx + 0xc]
cmp eax, ebx
jne 0x409b2a
push 8
lea eax, [ebp - 0x38]
push ebx
push eax
call fcn.00432990
mov eax, dword [ebp - 0xc4]
add esp, 0xc
lea edx, [ebp - 0x94]
push edx
lea edx, [ebp - 0x38]
push edx
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x20]
push esi
mov dword [ebp - 0x38], esi
mov ecx, dword [eax]
push eax
call dword [ecx + 0xc]
mov dword [ebp - 0x28], eax
jmp 0x409ad9
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x64]
push esi
push dword [ebp - 0x54]
mov dword [edi], 4
mov ecx, dword [eax]
push eax
call dword [ecx + 0x18]
cmp eax, ebx
mov dword [ebp - 0x28], eax
jge 0x409b67
mov dword [ebp - 0xbc], str.Failed_AddData
push 0x45408c
lea eax, [ebp - 0xbc]
jmp 0x409618
mov eax, dword [ebp - 0x50]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
push 5
pop eax
push esi
mov dword [edi], eax
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x48]
mov ecx, dword [eax]
push ebx
push eax
call dword [ecx + 0x34]
mov dword [edi], 6
mov byte [ebp - 0x11], 1
cmp eax, ebx
je 0x409c82
cmp byte [ebp + 0x9c], bl
je 0x409c42
mov eax, dword [ebp - 0x48]
mov dword [edi], ebx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x38]
call dword [sym.imp.ole32.dll_CoUninitialize]
push 0x2710
call dword [sym.imp.KERNEL32.dll_Sleep]
push ebx
push dword [ebp - 0x18]
push edi
push dword [ebp + 0x90]
call fcn.0040945f
add esp, 0x10
mov byte [ebp - 0x11], al
mov eax, dword [ebp - 0x1c]
mov byte [ebp - 4], 4
cmp eax, ebx
je 0x409bed
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x64]
mov byte [ebp - 4], 3
cmp eax, ebx
je 0x409bfe
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x9c]
mov byte [ebp - 4], 2
cmp eax, ebx
je 0x409c12
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 1
call fcn.00404df5
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], bl
call fcn.00409401
mov eax, dword [ebp - 0x6c]
or dword [ebp - 4], 0xffffffff
cmp eax, ebx
je 0x409c3a
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov al, byte [ebp - 0x11]
jmp 0x409d65
push 0x40e
push dword [ebp - 0x18]
call fcn.00403c89
push 0x3ee
push dword [ebp - 0x18]
mov esi, eax
call fcn.00403c89
add esp, 0x10
push 0x10
mov edi, eax
push edi
push esi
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
push esi
call fcn.00430bc7
push edi
call fcn.00430bc7
mov edi, dword [ebp - 0x78]
pop ecx
pop ecx
mov byte [ebp - 0x11], bl
mov eax, dword [ebp - 0x48]
mov dword [edi], 6
mov ecx, dword [eax]
push eax
call dword [ecx + 0x38]
call dword [sym.imp.ole32.dll_CoUninitialize]
jmp 0x409bdc
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], bl
call fcn.00409401
mov eax, dword [ebp - 0x6c]
or dword [ebp - 4], 0xffffffff
cmp eax, ebx
je 0x409d63
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x84]
xor ecx, ebp
call fcn.0043242d
add ebp, 0x88
leave
ret