Function at 0x4bd0c5
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x65c
mov eax, dword [0x58a06c]
xor eax, esp
mov dword [esp + 0x658], eax
cmp dword [ebp + 0x14], 3
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, ecx
je 0x4bd389
cmp dword [ebp + 0x14], 2
je 0x4bd101
cmp dword [ebp + 0x14], 1
jne 0x4bd3a9
cmp dword [esi + 4], 0xffffffff
je 0x4bd10e
mov ecx, dword [esi]
call fcn.004bc7b3
mov eax, dword [esi]
or dword [esi + 4], 0xffffffff
mov ebx, dword [ebp + 8]
cmp ebx, dword [eax + 4]
jge 0x4bd3a9
cmp dword [eax + 0x10], ebx
jle 0x4bd13a
mov ecx, eax
call fcn.004bc139
jmp 0x4bd135
mov ecx, dword [esi]
call fcn.004bc170
mov eax, dword [esi]
cmp dword [eax + 0x10], ebx
jl 0x4bd12e
lea eax, [esp + 0x20]
mov ecx, esi
push eax
push ebx
call fcn.004bc9e8
test byte [esp + 0x22c], 0x10
je 0x4bd18c
cmp dword [ebp + 0x14], 1
je 0x4bd403
movzx eax, word [edi]
cmp eax, 0x2f
je 0x4bd17e
cmp eax, 0x5c
je 0x4bd17e
test ax, ax
je 0x4bd176
cmp word [edi + 2], 0x3a
je 0x4bd17e
lea ecx, [esi + 0x244]
jmp 0x4bd180
xor ecx, ecx
mov edx, edi
call fcn.004bcf99
jmp 0x4bd403
xor ebx, ebx
cmp dword [ebp + 0x14], 1
je 0x4bd2b6
movzx eax, word [edi]
mov edx, edi
mov ecx, edi
mov dword [esp + 0x1c], 0x2f
mov dword [esp + 0x14], 0x5c
jmp 0x4bd1c8
cmp ax, word [esp + 0x1c]
je 0x4bd1bf
cmp ax, word [esp + 0x14]
jne 0x4bd1c2
lea edx, [ecx + 2]
add ecx, 2
movzx eax, word [ecx]
test ax, ax
jne 0x4bd1b1
lea eax, [esp + 0x250]
mov ecx, edi
sub eax, edi
mov ebx, eax
movzx eax, word [ecx]
mov word [ebx + ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x4bd1da
push 0
pop ebx
cmp edx, edi
jne 0x4bd1fc
xor eax, eax
mov word [esp + 0x250], ax
jmp 0x4bd23e
mov eax, edx
sub eax, edi
and eax, 0xfffffffe
cmp eax, 0x208
jae 0x4bd439
xor ecx, ecx
mov word [esp + eax + 0x250], cx
mov ax, word [esp + 0x250]
cmp ax, word [esp + 0x1c]
je 0x4bd266
cmp ax, word [esp + 0x14]
je 0x4bd266
test ax, ax
je 0x4bd23e
cmp word [esp + 0x252], 0x3a
je 0x4bd266
push edx
lea eax, [esp + 0x254]
push eax
lea edi, [esi + 0x244]
push edi
lea eax, [esp + 0x464]
push str._s_s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x14
jmp 0x4bd287
push edx
lea eax, [esp + 0x254]
push eax
lea eax, [esp + 0x460]
push str._s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
mov edi, ebx
lea edx, [esp + 0x250]
mov ecx, edi
call fcn.004bcf99
push ebx
push dword [esp + 0x230]
lea eax, [esp + 0x460]
push 2
push ebx
push ebx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
invalid
mov edi, eax
cmp edi, 0xffffffff
jne 0x4bd2c5
mov eax, 0x200
jmp 0x4bd422
mov edx, dword [esi + 0x23c]
mov ecx, dword [esi]
call fcn.004bc40c
cmp dword [esi + 0x240], ebx
jne 0x4bd2eb
push 0x4000
call fcn.005008e0
pop ecx
mov dword [esi + 0x240], eax
mov edx, dword [esi + 0x240]
lea eax, [esp + 0x13]
mov ecx, dword [esi]
push eax
push 0x4000
call fcn.004bc55d
mov dword [esp + 0x20], eax
pop ecx
pop ecx
cmp eax, 0xffffff96
je 0x4bd369
test eax, eax
js 0x4bd33a
jle 0x4bd32f
push ebx
lea ecx, [esp + 0x18]
push ecx
push eax
push dword [esi + 0x240]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4bd341
mov eax, dword [esp + 0x18]
cmp byte [esp + 0x13], 0
jne 0x4bd348
test eax, eax
jne 0x4bd2eb
mov ebx, 0x5000000
jmp 0x4bd36e
mov ebx, 0x400
jmp 0x4bd36e
lea eax, [esp + 0x240]
push eax
lea eax, [esp + 0x234]
push eax
lea eax, [esp + 0x240]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
jmp 0x4bd36e
mov ebx, 0x1000
cmp dword [ebp + 0x14], 1
je 0x4bd37b
push edi
call dword [0x53e34c]
mov ecx, dword [esi]
call fcn.004bc7b3
mov eax, ebx
jmp 0x4bd422
mov ebx, dword [ebp + 8]
cmp ebx, dword [esi + 4]
je 0x4bd3d8
cmp dword [esi + 4], 0xffffffff
je 0x4bd39e
mov ecx, dword [esi]
call fcn.004bc7b3
mov ecx, dword [esi]
or dword [esi + 4], 0xffffffff
cmp ebx, dword [ecx + 4]
jl 0x4bd3b0
mov eax, 0x10000
jmp 0x4bd422
cmp dword [ecx + 0x10], ebx
jle 0x4bd3c8
call fcn.004bc139
jmp 0x4bd3c3
mov ecx, dword [esi]
call fcn.004bc170
mov ecx, dword [esi]
cmp dword [ecx + 0x10], ebx
jl 0x4bd3bc
mov edx, dword [esi + 0x23c]
call fcn.004bc40c
mov dword [esi + 4], ebx
mov ecx, dword [esi]
lea eax, [esp + 0x13]
push eax
push dword [ebp + 0x10]
mov edx, edi
call fcn.004bc55d
mov edi, eax
pop ecx
pop ecx
test edi, edi
jg 0x4bd3fc
mov ecx, dword [esi]
call fcn.004bc7b3
or dword [esi + 4], 0xffffffff
cmp byte [esp + 0x13], 0
je 0x4bd407
xor eax, eax
jmp 0x4bd422
test edi, edi
jle 0x4bd412
mov eax, 0x600
jmp 0x4bd422
cmp edi, 0xffffff96
mov eax, 0x5000000
mov ecx, 0x1000
cmove eax, ecx
mov ecx, dword [esp + 0x664]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.005000f2
mov esp, ebp
pop ebp
ret 0x10
call fcn.00500805
int3