Function at 0x4058f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42f190
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x43800c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [0x438430]
mov ebx, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [edi + 0x48]
test eax, eax
je 0x405958
cmp byte [edi + 1], 0
je 0x405958
mov byte [eax + 0x10], 0
mov esi, dword [edi + 0x48]
test esi, esi
je 0x405958
mov ecx, esi
call fcn.00423f50
mov eax, dword [0x438430]
test eax, eax
je 0x405952
dec dword [eax + 0xb4]
push esi
call ebx
add esp, 4
mov dword [edi + 0x48], 0
mov ecx, dword [edi + 0x3bf4]
test ecx, ecx
je 0x40599c
mov eax, dword [0x438430]
mov dword [edi + 0x3bf0], 0
mov dword [edi + 0x3bec], 0
test eax, eax
je 0x40598c
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x3bf4], 0
cmp byte [edi], 0
je 0x40634b
cmp byte [edi + 0x5a41], 0
je 0x405a08
mov esi, dword [edi + 0x20]
test esi, esi
je 0x405a08
mov eax, dword [0x438430]
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x10], 0
mov dword [eax + 0x5a44], 0
call fcn.004171f0
mov edx, 0x430fa0
mov dword [ebp - 0x14], eax
mov ecx, esi
call fcn.004042b0
mov esi, eax
test esi, esi
je 0x405a08
push esi
push dword [ebp - 0x10]
mov dword [ebp - 0x1c], 0
push 1
push dword [ebp - 0x14]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x14
xor esi, esi
cmp dword [edi + 0x5a78], esi
jle 0x405a4a
xor ecx, ecx
mov dword [ebp - 0x10], ecx
nop word [eax + eax]
mov edx, dword [edi + 0x5a80]
add edx, ecx
cmp dword [edx + 4], 6
jne 0x405a3b
mov eax, dword [edx + 0xc]
push edx
push edi
call eax
mov ecx, dword [ebp - 0x10]
add esp, 8
inc esi
add ecx, 0x14
mov dword [ebp - 0x10], ecx
cmp esi, dword [edi + 0x5a78]
jl 0x405a20
xor esi, esi
lea ecx, [edi + 0x3e08]
mov dword [ebp - 0x10], ecx
cmp dword [edi + 0x3e00], esi
jle 0x405a9b
nop dword [eax]
mov eax, dword [ecx]
mov eax, dword [eax + esi*4]
mov dword [ebp - 0x14], eax
test eax, eax
je 0x405a90
mov ecx, eax
call fcn.00406a90
mov eax, dword [0x438430]
test eax, eax
je 0x405a82
dec dword [eax + 0xb4]
push dword [ebp - 0x14]
call ebx
add esp, 4
lea ecx, [edi + 0x3e08]
inc esi
cmp esi, dword [edi + 0x3e00]
jl 0x405a60
jmp 0x405a9e
mov dword [ebp - 0x10], ecx
mov ecx, dword [ecx]
test ecx, ecx
je 0x405ad6
mov eax, dword [0x438430]
mov dword [edi + 0x3e04], 0
mov dword [edi + 0x3e00], 0
test eax, eax
je 0x405ac7
dec dword [eax + 0xb4]
push ecx
call ebx
mov eax, dword [ebp - 0x10]
add esp, 4
mov dword [eax], 0
mov ecx, dword [edi + 0x3e14]
test ecx, ecx
je 0x405b13
mov eax, dword [0x438430]
mov dword [edi + 0x3e10], 0
mov dword [edi + 0x3e0c], 0
test eax, eax
je 0x405b03
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x3e14], 0
mov ecx, dword [edi + 0x3e20]
test ecx, ecx
je 0x405b50
mov eax, dword [0x438430]
mov dword [edi + 0x3e1c], 0
mov dword [edi + 0x3e18], 0
test eax, eax
je 0x405b40
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x3e20], 0
mov dword [edi + 0x3e48], 0
mov ecx, dword [edi + 0x3e2c]
test ecx, ecx
je 0x405b97
mov eax, dword [0x438430]
mov dword [edi + 0x3e28], 0
mov dword [edi + 0x3e24], 0
test eax, eax
je 0x405b87
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x3e2c], 0
mov ecx, dword [edi + 0x3e38]
test ecx, ecx
je 0x405bd4
mov eax, dword [0x438430]
mov dword [edi + 0x3e34], 0
mov dword [edi + 0x3e30], 0
test eax, eax
je 0x405bc4
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x3e38], 0
lea ecx, [edi + 0x4560]
mov dword [edi + 0x47c8], 0
mov dword [edi + 0x3e50], 0
mov dword [edi + 0x3e4c], 0
mov dword [edi + 0x3ec4], 0
mov dword [edi + 0x3eb0], 0
mov dword [edi + 0x3e54], 0
call fcn.00401f70
mov ecx, dword [edi + 0x4760]
test ecx, ecx
je 0x405c58
mov eax, dword [0x438430]
mov dword [edi + 0x475c], 0
mov dword [edi + 0x4758], 0
test eax, eax
je 0x405c48
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4760], 0
mov ecx, dword [edi + 0x476c]
test ecx, ecx
je 0x405c95
mov eax, dword [0x438430]
mov dword [edi + 0x4768], 0
mov dword [edi + 0x4764], 0
test eax, eax
je 0x405c85
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x476c], 0
mov ecx, dword [edi + 0x4778]
test ecx, ecx
je 0x405cd2
mov eax, dword [0x438430]
mov dword [edi + 0x4774], 0
mov dword [edi + 0x4770], 0
test eax, eax
je 0x405cc2
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4778], 0
mov ecx, dword [edi + 0x47a8]
test ecx, ecx
je 0x405d0f
mov eax, dword [0x438430]
mov dword [edi + 0x47a4], 0
mov dword [edi + 0x47a0], 0
test eax, eax
je 0x405cff
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x47a8], 0
mov ecx, dword [edi + 0x47b4]
test ecx, ecx
je 0x405d4c
mov eax, dword [0x438430]
mov dword [edi + 0x47b0], 0
mov dword [edi + 0x47ac], 0
test eax, eax
je 0x405d3c
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x47b4], 0
xor ecx, ecx
lea edx, [edi + 0x47c4]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x14], edx
cmp dword [edi + 0x47bc], ecx
jle 0x405e17
mov eax, dword [edx]
mov esi, dword [eax + ecx*4]
test esi, esi
je 0x405e05
mov dword [ebp - 4], 0
mov eax, dword [esi + 0x30]
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x405da2
mov ecx, eax
call fcn.00401d30
mov eax, dword [0x438430]
test eax, eax
je 0x405d9a
dec dword [eax + 0xb4]
push dword [ebp - 0x1c]
call ebx
add esp, 4
mov eax, dword [esi + 0x34]
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x405dca
mov ecx, eax
call fcn.00401d30
mov eax, dword [0x438430]
test eax, eax
je 0x405dc2
dec dword [eax + 0xb4]
push dword [ebp - 0x1c]
call ebx
add esp, 4
push 0x4182b0
push 2
push 0xc
lea eax, [esi + 0x64]
mov byte [ebp - 4], 1
push eax
call fcn.0042dcbb
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x438430]
test eax, eax
je 0x405df6
dec dword [eax + 0xb4]
push esi
call ebx
mov ecx, dword [ebp - 0x10]
lea edx, [edi + 0x47c4]
add esp, 4
inc ecx
mov dword [ebp - 0x10], ecx
cmp ecx, dword [edi + 0x47bc]
jl 0x405d66
jmp 0x405e1a
mov dword [ebp - 0x14], edx
mov ecx, dword [edx]
test ecx, ecx
je 0x405e52
mov eax, dword [0x438430]
mov dword [edi + 0x47c0], 0
mov dword [edi + 0x47bc], 0
test eax, eax
je 0x405e43
dec dword [eax + 0xb4]
push ecx
call ebx
mov eax, dword [ebp - 0x14]
add esp, 4
mov dword [eax], 0
lea ecx, [edi + 0x4a54]
call fcn.00418310
mov ecx, dword [edi + 0x4a7c]
test ecx, ecx
je 0x405e9a
mov eax, dword [0x438430]
mov dword [edi + 0x4a78], 0
mov dword [edi + 0x4a74], 0
test eax, eax
je 0x405e8a
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4a7c], 0
mov ecx, dword [edi + 0x4a88]
test ecx, ecx
je 0x405ed7
mov eax, dword [0x438430]
mov dword [edi + 0x4a84], 0
mov dword [edi + 0x4a80], 0
test eax, eax
je 0x405ec7
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4a88], 0
xor esi, esi
lea eax, [edi + 0x4a00]
mov dword [ebp - 0x10], eax
cmp dword [edi + 0x49f8], esi
jle 0x405f36
xor ecx, ecx
mov dword [ebp - 0x14], ecx
nop
mov eax, dword [eax]
mov edx, dword [eax + ecx + 0x18]
test edx, edx
je 0x405f12
mov eax, dword [0x438430]
test eax, eax
je 0x405f09
dec dword [eax + 0xb4]
push edx
call ebx
mov ecx, dword [ebp - 0x14]
add esp, 4
inc esi
mov dword [ebp - 4], 0xffffffff
add ecx, 0x1c
lea eax, [edi + 0x4a00]
mov dword [ebp - 0x14], ecx
cmp esi, dword [edi + 0x49f8]
jl 0x405ef0
lea eax, [edi + 0x4a00]
jmp 0x405f39
mov dword [ebp - 0x10], eax
mov ecx, dword [eax]
test ecx, ecx
je 0x405f71
mov eax, dword [0x438430]
mov dword [edi + 0x49fc], 0
mov dword [edi + 0x49f8], 0
test eax, eax
je 0x405f62
dec dword [eax + 0xb4]
push ecx
call ebx
mov eax, dword [ebp - 0x10]
add esp, 4
mov dword [eax], 0
lea ecx, [edi + 0x4a18]
call fcn.004184b0
cmp dword [edi + 0x4a0c], 0
lea esi, [edi + 0x4a14]
mov dword [ebp - 0x14], 0
jle 0x405ff1
xor ecx, ecx
mov dword [ebp - 0x10], ecx
mov esi, dword [esi]
add esi, ecx
lea ecx, [esi + 0x10]
mov dword [ebp - 4], 3
call fcn.004238a0
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x405fc6
mov eax, dword [0x438430]
test eax, eax
je 0x405fc0
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov eax, dword [ebp - 0x14]
lea esi, [edi + 0x4a14]
mov dword [ebp - 4], 0xffffffff
inc eax
mov ecx, dword [ebp - 0x10]
add ecx, 0x68
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], ecx
cmp eax, dword [edi + 0x4a0c]
jl 0x405f97
lea esi, [edi + 0x4a14]
mov ecx, dword [esi]
test ecx, ecx
je 0x406026
mov eax, dword [0x438430]
mov dword [edi + 0x4a10], 0
mov dword [edi + 0x4a0c], 0
test eax, eax
je 0x40601a
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [esi], 0
mov ecx, dword [edi + 0x4a4c]
test ecx, ecx
je 0x406063
mov eax, dword [0x438430]
mov dword [edi + 0x4a48], 0
mov dword [edi + 0x4a44], 0
test eax, eax
je 0x406053
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4a4c], 0
mov ecx, dword [edi + 0x5a10]
test ecx, ecx
je 0x4060a0
mov eax, dword [0x438430]
mov dword [edi + 0x5a0c], 0
mov dword [edi + 0x5a08], 0
test eax, eax
je 0x406090
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5a10], 0
mov ecx, dword [edi + 0x5a1c]
test ecx, ecx
je 0x4060dd
mov eax, dword [0x438430]
mov dword [edi + 0x5a18], 0
mov dword [edi + 0x5a14], 0
test eax, eax
je 0x4060cd
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5a1c], 0
mov ecx, dword [edi + 0x4abc]
test ecx, ecx
je 0x40611a
mov eax, dword [0x438430]
mov dword [edi + 0x4ab8], 0
mov dword [edi + 0x4ab4], 0
test eax, eax
je 0x40610a
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4abc], 0
mov ecx, dword [edi + 0x4ac8]
test ecx, ecx
je 0x406157
mov eax, dword [0x438430]
mov dword [edi + 0x4ac4], 0
mov dword [edi + 0x4ac0], 0
test eax, eax
je 0x406147
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4ac8], 0
mov ecx, dword [edi + 0x4ad4]
test ecx, ecx
je 0x406194
mov eax, dword [0x438430]
mov dword [edi + 0x4ad0], 0
mov dword [edi + 0x4acc], 0
test eax, eax
je 0x406184
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x4ad4], 0
mov dword [edi + 0x591c], 0
mov ecx, dword [edi + 0x5928]
test ecx, ecx
je 0x4061db
mov eax, dword [0x438430]
mov dword [edi + 0x5924], 0
mov dword [edi + 0x5920], 0
test eax, eax
je 0x4061cb
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5928], 0
mov ecx, dword [edi + 0x5a68]
test ecx, ecx
je 0x406218
mov eax, dword [0x438430]
mov dword [edi + 0x5a64], 0
mov dword [edi + 0x5a60], 0
test eax, eax
je 0x406208
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5a68], 0
mov ecx, dword [edi + 0x5a5c]
test ecx, ecx
je 0x406255
mov eax, dword [0x438430]
mov dword [edi + 0x5a58], 0
mov dword [edi + 0x5a54], 0
test eax, eax
je 0x406245
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5a5c], 0
cmp dword [edi + 0x5aac], 0
je 0x406287
mov esi, dword [edi + 0x5aac]
push 1
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
cmp esi, eax
je 0x40627d
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
mov dword [edi + 0x5aac], 0
mov ecx, dword [edi + 0x5ab8]
test ecx, ecx
je 0x4062c4
mov eax, dword [0x438430]
mov dword [edi + 0x5ab4], 0
mov dword [edi + 0x5ab0], 0
test eax, eax
je 0x4062b4
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5ab8], 0
mov ecx, dword [edi + 0x5ae4]
test ecx, ecx
je 0x406301
mov eax, dword [0x438430]
mov dword [edi + 0x5ae0], 0
mov dword [edi + 0x5adc], 0
test eax, eax
je 0x4062f1
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5ae4], 0
mov ecx, dword [edi + 0x5af0]
test ecx, ecx
je 0x40633e
mov eax, dword [0x438430]
mov dword [edi + 0x5aec], 0
mov dword [edi + 0x5ae8], 0
test eax, eax
je 0x40632e
dec dword [eax + 0xb4]
push ecx
call ebx
add esp, 4
mov dword [edi + 0x5af0], 0
mov dword [edi + 0x5af4], 0
mov byte [edi], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret