Function at 0x40a4c4
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffee0
push ebx
push esi
push edi
mov ebx, eax
lea esi, [ebp - 0xf8]
mov eax, 0x49cfe4
call fcn.0047a12c
xor edx, edx
xor ecx, ecx
mov dword [ebp - 0xfc], edx
mov dword [ebp - 0x100], ecx
xor eax, eax
xor edx, edx
mov dword [ebp - 0x104], eax
mov dword [ebp - 0x108], edx
mov word [esi + 0x10], 8
mov edx, str.Starting_Flash_read
lea eax, [ebp - 4]
call fcn.00485c64
mov edx, eax
inc dword [esi + 0x1c]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 4]
mov edx, 2
call fcn.00485dbc
call sub.KERNEL32.DLL_GetCurrentProcess
mov dword [ebp - 0x11c], eax
mov ecx, dword [0x4a5984]
mov eax, dword [ecx + 0x40c]
mov dl, 6
call fcn.00469e04
push 0x80
mov ecx, dword [ebp - 0x11c]
push ecx
call sub.KERNEL32.DLL_SetPriorityClass
push 0
push 0x8000000
push 2
push 0
push 0
push 0x40000000
mov word [esi + 0x10], 0x14
xor eax, eax
mov dword [ebp - 8], eax
lea edx, [ebp - 8]
inc dword [esi + 0x1c]
mov ecx, dword [0x4a5984]
mov eax, dword [ecx + 0x3bc]
call fcn.00440ffc
cmp dword [ebp - 8], 0
je 0x40a59f
mov edx, dword [ebp - 8]
jmp 0x40a5a4
mov edx, 0x49c06e
push edx
call sub.KERNEL32.DLL_CreateFileA
mov dword [ebx + 0x10050], eax
dec dword [esi + 0x1c]
lea eax, [ebp - 8]
mov edx, 2
call fcn.00485dbc
mov eax, dword [0x4a5984]
mov eax, dword [eax + 0x3fc]
mov edx, dword [eax]
call dword [edx + 0xb4]
cmp al, 1
jne 0x40a5f0
mov eax, dword [0x4a5984]
mov edi, dword [eax + 0x444]
mov eax, dword [eax + 0x448]
mov dword [ebp - 0x120], eax
jmp 0x40a60d
mov edx, dword [0x4a5984]
mov eax, dword [edx + 0x440]
mov edx, dword [ebx + 0x100e8]
dec edx
mov edi, eax
add eax, edx
mov dword [ebp - 0x120], eax
mov eax, edi
mov ecx, edi
shr eax, 0x18
mov edx, edi
and al, 0xff
mov byte [ebx + 0x30], al
mov eax, edi
shr ecx, 0x10
shr eax, 8
and cl, 0xff
mov byte [ebx + 0x31], cl
and al, 0xff
mov byte [ebx + 0x32], al
and dl, 0xff
mov byte [ebx + 0x33], dl
lea edx, [ebx + 0x30]
mov eax, ebx
mov ecx, 4
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
mov eax, dword [ebp - 0x120]
shr eax, 0x18
and al, 0xff
mov byte [ebx + 0x30], al
mov edx, dword [ebp - 0x120]
shr edx, 0x10
and dl, 0xff
mov byte [ebx + 0x31], dl
lea edx, [ebx + 0x30]
mov ecx, dword [ebp - 0x120]
shr ecx, 8
and cl, 0xff
mov byte [ebx + 0x32], cl
mov ecx, 4
mov al, byte [ebp - 0x120]
and al, 0xff
mov byte [ebx + 0x33], al
mov eax, ebx
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
mov dword [ebp - 0xfc], edi
lea edi, [ebx + 0x100cc]
push 0
push edi
lea eax, [ebp - 0xfc]
push 4
push eax
mov edx, dword [ebx + 0x10050]
push edx
call sub.KERNEL32.DLL_WriteFile
mov ecx, dword [ebp - 0x120]
lea eax, [ebp - 0xfc]
inc ecx
mov dword [ebp - 0xfc], ecx
push 0
push edi
push 4
push eax
mov edx, dword [ebx + 0x10050]
push edx
call sub.KERNEL32.DLL_WriteFile
cmp dword [ebx + 0x10050], 0xffffffff
je 0x40b1c8
mov byte [ebx + 0x8038], 0xde
lea edx, [ebx + 0x8038]
mov ecx, 1
mov eax, ebx
call fcn.0040b6dc
mov dword [ebx + 0x100c8], eax
mov al, byte [ebx + 0x8038]
cmp al, 0x21
je 0x40a721
cmp al, 0x15
je 0x40a721
cmp dword [ebx + 0x100d8], 0
je 0x40a6f2
cmp dword [ebx + 0x100d8], 0
jne 0x40acfb
cmp byte [ebx + 0x8038], 0x21
jne 0x40acfb
mov edx, dword [ebp - 0x104]
add dword [ebp - 0xfc], edx
xor edi, edi
lea edx, [ebx + 0x8038]
mov ecx, 2
mov eax, ebx
call fcn.0040b6dc
mov dword [ebx + 0x100c8], eax
cmp dword [ebx + 0x100c8], 2
je 0x40a773
cmp dword [ebx + 0x100d8], 0
je 0x40a749
xor eax, eax
xor edx, edx
mov al, byte [ebx + 0x8038]
mov dl, byte [ebx + 0x8039]
shl eax, 8
add eax, edx
mov dword [ebp - 0x10c], eax
cmp dword [ebp - 0x108], 0
jne 0x40a82b
cmp dword [ebp - 0x10c], 0
je 0x40a802
mov ecx, dword [0x4a5984]
mov eax, dword [ecx + 0x3fc]
mov edx, dword [eax]
call dword [edx + 0xb4]
cmp al, 1
jne 0x40a7e7
mov ecx, dword [0x4a5984]
mov edx, dword [ebp - 0x10c]
dec edx
mov eax, dword [ecx + 0x448]
sub eax, dword [ecx + 0x444]
add eax, edx
xor edx, edx
div dword [ebp - 0x10c]
mov dword [ebp - 0x108], eax
jmp 0x40a802
mov eax, dword [ebp - 0x10c]
dec eax
add eax, dword [ebx + 0x100e8]
xor edx, edx
div dword [ebp - 0x10c]
mov dword [ebp - 0x108], eax
mov eax, dword [0x4a5984]
mov edx, dword [ebp - 0x108]
mov eax, dword [eax + 0x2f4]
call fcn.00456998
mov ecx, dword [0x4a5984]
xor edx, edx
mov eax, dword [ecx + 0x2f4]
call fcn.004569a8
xor ecx, ecx
xor eax, eax
mov cl, byte [ebx + 0x8038]
mov al, byte [ebx + 0x8039]
add di, cx
add di, ax
lea edx, [ebx + 0x8038]
mov ecx, 4
mov eax, ebx
call fcn.0040b6dc
mov dword [ebx + 0x100c8], eax
cmp dword [ebx + 0x100c8], 4
je 0x40a86b
cmp dword [ebx + 0x100d8], 0
je 0x40a841
xor edx, edx
xor ecx, ecx
mov cl, byte [ebx + 0x8039]
mov dl, byte [ebx + 0x8038]
shl ecx, 0x10
xor eax, eax
shl edx, 0x18
mov al, byte [ebx + 0x803a]
shl eax, 8
add edx, ecx
xor ecx, ecx
add edx, eax
mov cl, byte [ebx + 0x803b]
xor eax, eax
add edx, ecx
xor ecx, ecx
mov dword [ebp - 0xfc], edx
xor edx, edx
mov dl, byte [ebx + 0x8038]
mov al, byte [ebx + 0x8039]
add di, dx
xor edx, edx
add di, ax
mov dl, byte [ebx + 0x803a]
add di, dx
mov cl, byte [ebx + 0x803b]
add di, cx
xor eax, eax
mov dword [ebp - 0x110], 0x4000
mov dword [ebp - 0x114], eax
mov eax, ebx
mov byte [ebx + 0x30], 0x21
mov ecx, 1
lea edx, [ebx + 0x30]
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
mov edx, dword [ebp - 0x114]
add edx, dword [ebp - 0x110]
cmp edx, dword [ebp - 0x10c]
jbe 0x40a91d
mov ecx, dword [ebp - 0x10c]
sub ecx, dword [ebp - 0x114]
mov dword [ebp - 0x110], ecx
mov edx, dword [ebp - 0x114]
mov ecx, dword [ebp - 0x110]
add edx, ebx
mov eax, ebx
add edx, 0x8038
call fcn.0040b6dc
mov dword [ebx + 0x100c8], eax
mov eax, dword [ebx + 0x100c8]
add dword [ebp - 0x114], eax
mov edx, dword [ebp - 0x114]
cmp edx, dword [ebp - 0x10c]
jae 0x40a961
cmp dword [ebx + 0x100d8], 0
je 0x40a8f7
mov byte [ebx + 0x30], 0x21
lea edx, [ebx + 0x30]
mov ecx, 1
mov eax, ebx
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
lea edx, [ebp - 0x116]
mov ecx, 2
mov eax, ebx
call fcn.0040b6dc
mov dword [ebx + 0x100c8], eax
cmp dword [ebx + 0x100c8], 0
jne 0x40a9a4
cmp dword [ebx + 0x100d8], 0
je 0x40a97a
xor edx, edx
xor eax, eax
mov dl, byte [ebp - 0x116]
mov al, byte [ebp - 0x115]
shl edx, 8
add dx, ax
xor ecx, ecx
mov dword [ebx + 0x100c8], ecx
jmp 0x40a9d5
movzx eax, byte [ebx + eax + 0x8038]
add di, ax
inc dword [ebx + 0x100c8]
mov eax, dword [ebx + 0x100c8]
cmp eax, dword [ebp - 0x114]
jb 0x40a9c4
cmp dx, di
je 0x40ab55
mov word [esi + 0x10], 0x20
lea eax, [ebp - 0x10]
mov edx, dword [ebp - 0x100]
call fcn.00485d34
push eax
inc dword [esi + 0x1c]
mov edx, str.Re_reading_block
lea eax, [ebp - 0xc]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0x14], ecx
lea ecx, [ebp - 0x14]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea eax, [ebp - 0x14]
push eax
mov edx, 0x49c081
lea eax, [ebp - 0x18]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x1c], eax
lea edx, [ebp - 0x18]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x1c]
push edx
lea eax, [ebp - 0x20]
mov edx, dword [ebp - 0x108]
call fcn.00485d34
mov edx, eax
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x24], eax
lea ecx, [ebp - 0x24]
inc dword [esi + 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x24]
push edx
mov edx, 0x49c084
lea eax, [ebp - 0x28]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x2c], eax
lea edx, [ebp - 0x28]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x2c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x2c]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x20]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x1c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x18]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x14]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x10]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xc]
mov edx, 2
call fcn.00485dbc
mov byte [ebx + 0x30], 0x15
lea edx, [ebx + 0x30]
mov ecx, 1
mov eax, ebx
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
jmp 0x40ae5f
inc dword [ebp - 0x100]
mov eax, dword [0x4a5984]
mov eax, dword [eax + 0x2f4]
mov edi, dword [ebp - 0x100]
mov edx, edi
call fcn.004569a8
mov word [esi + 0x10], 0x2c
lea eax, [ebp - 0x34]
mov edx, edi
call fcn.00485d34
push eax
inc dword [esi + 0x1c]
mov edx, str.Reading_block
lea eax, [ebp - 0x30]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0x38], ecx
lea ecx, [ebp - 0x38]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea eax, [ebp - 0x38]
push eax
mov edx, 0x49c095
lea eax, [ebp - 0x3c]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x40], eax
lea edx, [ebp - 0x3c]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x40]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x40]
push edx
lea eax, [ebp - 0x44]
mov edx, dword [ebp - 0x108]
call fcn.00485d34
mov edx, eax
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x48], eax
lea ecx, [ebp - 0x48]
inc dword [esi + 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x48]
push edx
mov edx, 0x49c098
lea eax, [ebp - 0x4c]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x50], eax
lea edx, [ebp - 0x4c]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x50]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x50]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0x50]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x4c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x48]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x44]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x40]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x3c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x38]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x34]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x30]
mov edx, 2
call fcn.00485dbc
lea ecx, [ebx + 0x100cc]
push 0
push ecx
lea edx, [ebx + 0x8038]
mov eax, dword [ebp - 0x114]
push eax
push edx
mov ecx, dword [ebx + 0x10050]
push ecx
call sub.KERNEL32.DLL_WriteFile
mov byte [ebx + 0x30], 0x21
lea edx, [ebx + 0x30]
mov ecx, 1
mov eax, ebx
call fcn.0040b65c
mov dword [ebx + 0x100cc], eax
jmp 0x40ae5f
cmp dword [ebx + 0x100d8], 0
jne 0x40ae5f
mov word [esi + 0x10], 0x38
lea eax, [ebp - 0x58]
mov edx, dword [ebp - 0x100]
call fcn.00485d34
push eax
inc dword [esi + 0x1c]
mov edx, str.Lost_sync_with_target
lea eax, [ebp - 0x54]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0x5c], ecx
lea ecx, [ebp - 0x5c]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea eax, [ebp - 0x5c]
push eax
mov edx, 0x49c0b1
lea eax, [ebp - 0x60]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x64], eax
lea edx, [ebp - 0x60]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x64]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x64]
push edx
lea eax, [ebp - 0x68]
mov edx, dword [ebp - 0x108]
call fcn.00485d34
mov edx, eax
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x6c], eax
lea ecx, [ebp - 0x6c]
inc dword [esi + 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x6c]
push edx
mov edx, 0x49c0b4
lea eax, [ebp - 0x70]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x74], eax
lea edx, [ebp - 0x70]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x74]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x74]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0x74]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x70]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x6c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x68]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x64]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x60]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x5c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x58]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x54]
mov edx, 2
call fcn.00485dbc
mov ecx, dword [ebp - 0x108]
mov dword [ebp - 0x100], ecx
mov eax, dword [ebp - 0x100]
cmp eax, dword [ebp - 0x108]
jae 0x40ae7a
cmp dword [ebx + 0x100d8], 0
je 0x40a6eb
mov edx, dword [ebp - 0x100]
cmp edx, dword [ebp - 0x108]
jne 0x40b018
mov word [esi + 0x10], 0x44
lea eax, [ebp - 0x7c]
mov edx, dword [ebp - 0x100]
call fcn.00485d34
push eax
inc dword [esi + 0x1c]
mov edx, str.Read_successful
lea eax, [ebp - 0x78]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0x80], ecx
lea ecx, [ebp - 0x80]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea eax, [ebp - 0x80]
push eax
mov edx, 0x49c0c7
lea eax, [ebp - 0x84]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x88], eax
lea edx, [ebp - 0x84]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x88]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x88]
push edx
lea eax, [ebp - 0x8c]
mov edx, dword [ebp - 0x108]
call fcn.00485d34
mov edx, eax
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x90], eax
lea ecx, [ebp - 0x90]
inc dword [esi + 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x90]
push edx
mov edx, 0x49c0ca
lea eax, [ebp - 0x94]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0x98], eax
lea edx, [ebp - 0x94]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0x98]
pop eax
call fcn.00485e14
lea edx, [ebp - 0x98]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0x98]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x94]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x90]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x8c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x88]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x84]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x80]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x7c]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x78]
mov edx, 2
call fcn.00485dbc
jmp 0x40b1b7
mov word [esi + 0x10], 0x50
lea eax, [ebp - 0xa0]
mov edx, dword [ebp - 0x100]
call fcn.00485d34
push eax
inc dword [esi + 0x1c]
mov edx, str.Read_failed
lea eax, [ebp - 0x9c]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0xa4], ecx
lea ecx, [ebp - 0xa4]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea eax, [ebp - 0xa4]
push eax
mov edx, 0x49c0d9
lea eax, [ebp - 0xa8]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0xac], eax
lea edx, [ebp - 0xa8]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0xac]
pop eax
call fcn.00485e14
lea edx, [ebp - 0xac]
push edx
lea eax, [ebp - 0xb0]
mov edx, dword [ebp - 0x108]
call fcn.00485d34
mov edx, eax
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0xb4], eax
lea ecx, [ebp - 0xb4]
inc dword [esi + 0x1c]
pop eax
call fcn.00485e14
lea edx, [ebp - 0xb4]
push edx
mov edx, 0x49c0dc
lea eax, [ebp - 0xb8]
call fcn.00485c64
inc dword [esi + 0x1c]
xor eax, eax
mov dword [ebp - 0xbc], eax
lea edx, [ebp - 0xb8]
inc dword [esi + 0x1c]
lea ecx, [ebp - 0xbc]
pop eax
call fcn.00485e14
lea edx, [ebp - 0xbc]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0xbc]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xb8]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xb4]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xb0]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xac]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xa8]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xa4]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xa0]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0x9c]
mov edx, 2
call fcn.00485dbc
mov ecx, dword [ebx + 0x10050]
push ecx
call sub.KERNEL32.DLL_CloseHandle
jmp 0x40b321
mov word [esi + 0x10], 0x5c
xor eax, eax
mov dword [ebp - 0xc4], eax
lea edx, [ebp - 0xc4]
inc dword [esi + 0x1c]
mov ecx, dword [0x4a5984]
mov eax, dword [ecx + 0x3bc]
call fcn.00440ffc
lea edx, [ebp - 0xc4]
push edx
mov edx, 0x49c0de
lea eax, [ebp - 0xc0]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0xc8], ecx
lea ecx, [ebp - 0xc8]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
lea edx, [ebp - 0xc8]
mov eax, ebx
call fcn.0040758c
dec dword [esi + 0x1c]
lea eax, [ebp - 0xc8]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xc4]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xc0]
mov edx, 2
call fcn.00485dbc
push 0x10
xor ecx, ecx
mov word [esi + 0x10], 0x68
mov dword [ebp - 0xd0], ecx
lea edx, [ebp - 0xd0]
inc dword [esi + 0x1c]
mov eax, dword [0x4a5984]
mov eax, dword [eax + 0x3bc]
call fcn.00440ffc
lea edx, [ebp - 0xd0]
push edx
mov edx, str.Could_not_write_to_file._n
lea eax, [ebp - 0xcc]
call fcn.00485c64
inc dword [esi + 0x1c]
xor ecx, ecx
mov dword [ebp - 0xd4], ecx
lea ecx, [ebp - 0xd4]
inc dword [esi + 0x1c]
pop edx
call fcn.00485e14
cmp dword [ebp - 0xd4], 0
je 0x40b2d2
mov edx, dword [ebp - 0xd4]
jmp 0x40b2d7
mov edx, 0x49c118
mov ecx, str.ERROR
mov eax, dword [0x4a5584]
mov eax, dword [eax]
call fcn.00485b9c
dec dword [esi + 0x1c]
lea eax, [ebp - 0xd4]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xd0]
mov edx, 2
call fcn.00485dbc
dec dword [esi + 0x1c]
lea eax, [ebp - 0xcc]
mov edx, 2
call fcn.00485dbc
mov ecx, dword [0x4a5984]
mov dl, 4
mov eax, dword [ecx + 0x40c]
call fcn.00469e04
push 0x20
mov ecx, dword [ebp - 0x11c]
push ecx
call sub.KERNEL32.DLL_SetPriorityClass
mov eax, dword [esi]
mov dword fs:[0], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret