Function at 0x51baa0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x561c30
push eax
mov dword fs:[0], esp
sub esp, 0x10
mov eax, dword [0x6bb530]
push ebx
push esi
push edi
mov edi, eax
mov ecx, dword [edi + 0x48]
test ecx, ecx
je 0x51bc0b
cmp byte [edi + 1], 0
je 0x51bc0b
mov byte [ecx + 0x10], 0
mov esi, dword [edi + 0x48]
test esi, esi
je 0x51bc0b
mov ecx, esi
mov dword [ebp - 4], 0
call fcn.0053c7f0
mov ecx, esi
call fcn.0053c900
xor ebx, ebx
lea ecx, [esi + 0x44]
mov dword [ebp - 0x10], ecx
cmp dword [esi + 0x3c], ebx
jle 0x51bb49
nop dword [eax + eax]
mov eax, dword [ecx]
mov eax, dword [eax + ebx*4]
mov dword [ebp - 0x14], eax
test eax, eax
je 0x51bb41
mov ecx, eax
call fcn.0053eba0
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bb32
dec dword [eax + 0xb4]
push dword [ebp - 0x14]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
lea ecx, [esi + 0x44]
inc ebx
cmp ebx, dword [esi + 0x3c]
jl 0x51bb10
jmp 0x51bb4c
mov dword [ebp - 0x10], ecx
mov ecx, dword [ecx]
test ecx, ecx
je 0x51bb82
mov eax, dword [0x6bb530]
mov dword [esi + 0x40], 0
mov dword [esi + 0x3c], 0
test eax, eax
je 0x51bb6f
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [ebp - 0x10]
add esp, 4
mov dword [eax], 0
mov byte [esi + 0x18], 0
mov ecx, dword [esi + 0x5c]
test ecx, ecx
je 0x51bba6
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bb9c
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov ecx, dword [esi + 0x50]
test ecx, ecx
je 0x51bbc6
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bbbc
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov ecx, dword [esi + 0x44]
test ecx, ecx
je 0x51bbe6
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bbdc
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bbfc
dec dword [eax + 0xb4]
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [0x6bb530]
add esp, 4
mov dword [edi + 0x48], 0
mov ecx, dword [edi + 0x3bf4]
test ecx, ecx
je 0x51bc53
mov dword [edi + 0x3bf0], 0
mov dword [edi + 0x3bec], 0
test eax, eax
je 0x51bc3a
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [0x6bb530]
add esp, 4
mov dword [edi + 0x3bf4], 0
cmp byte [edi], 0
je 0x51c58b
cmp byte [edi + 0x5a41], 0
je 0x51bcb7
mov esi, dword [edi + 0x20]
test esi, esi
je 0x51bcb7
lea ecx, [ebp - 0x10]
mov dword [eax + 0x5a44], 0
mov dword [ebp - 0x10], 0
call fcn.0052e8a0
mov edx, 0x56ec44
mov ecx, esi
mov ebx, eax
call fcn.00518900
mov esi, eax
test esi, esi
je 0x51bcb7
push esi
push dword [ebp - 0x10]
mov dword [ebp - 0x14], 0
push 1
push ebx
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
mov edx, 6
mov ecx, edi
call fcn.0051c5b0
lea ecx, [edi + 0x3e00]
call fcn.0052fd30
mov ecx, dword [edi + 0x3e14]
test ecx, ecx
je 0x51bd0f
mov eax, dword [0x6bb530]
mov dword [edi + 0x3e10], 0
mov dword [edi + 0x3e0c], 0
test eax, eax
je 0x51bcfb
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x3e14], 0
mov ecx, dword [edi + 0x3e20]
test ecx, ecx
je 0x51bd50
mov eax, dword [0x6bb530]
mov dword [edi + 0x3e1c], 0
mov dword [edi + 0x3e18], 0
test eax, eax
je 0x51bd3c
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x3e20], 0
mov dword [edi + 0x3e48], 0
mov ecx, dword [edi + 0x3e2c]
test ecx, ecx
je 0x51bd9b
mov eax, dword [0x6bb530]
mov dword [edi + 0x3e28], 0
mov dword [edi + 0x3e24], 0
test eax, eax
je 0x51bd87
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x3e2c], 0
mov ecx, dword [edi + 0x3e38]
test ecx, ecx
je 0x51bddc
mov eax, dword [0x6bb530]
mov dword [edi + 0x3e34], 0
mov dword [edi + 0x3e30], 0
test eax, eax
je 0x51bdc8
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
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.005164f0
mov ecx, dword [edi + 0x4760]
test ecx, ecx
je 0x51be64
mov eax, dword [0x6bb530]
mov dword [edi + 0x475c], 0
mov dword [edi + 0x4758], 0
test eax, eax
je 0x51be50
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4760], 0
mov ecx, dword [edi + 0x476c]
test ecx, ecx
je 0x51bea5
mov eax, dword [0x6bb530]
mov dword [edi + 0x4768], 0
mov dword [edi + 0x4764], 0
test eax, eax
je 0x51be91
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x476c], 0
mov ecx, dword [edi + 0x4778]
test ecx, ecx
je 0x51bee6
mov eax, dword [0x6bb530]
mov dword [edi + 0x4774], 0
mov dword [edi + 0x4770], 0
test eax, eax
je 0x51bed2
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4778], 0
mov ecx, dword [edi + 0x47a8]
test ecx, ecx
je 0x51bf27
mov eax, dword [0x6bb530]
mov dword [edi + 0x47a4], 0
mov dword [edi + 0x47a0], 0
test eax, eax
je 0x51bf13
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x47a8], 0
mov ecx, dword [edi + 0x47b4]
test ecx, ecx
je 0x51bf68
mov eax, dword [0x6bb530]
mov dword [edi + 0x47b0], 0
mov dword [edi + 0x47ac], 0
test eax, eax
je 0x51bf54
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x47b4], 0
xor ebx, ebx
cmp dword [edi + 0x47bc], ebx
jle 0x51c033
nop word [eax + eax]
mov eax, dword [edi + 0x47c4]
mov esi, dword [eax + ebx*4]
test esi, esi
je 0x51c026
mov dword [ebp - 4], 4
mov eax, dword [esi + 0x30]
mov dword [ebp - 0x14], eax
test eax, eax
je 0x51bfc4
mov ecx, eax
call fcn.00516280
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bfb8
dec dword [eax + 0xb4]
push dword [ebp - 0x14]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov eax, dword [esi + 0x34]
mov dword [ebp - 0x14], eax
test eax, eax
je 0x51bff0
mov ecx, eax
call fcn.00516280
mov eax, dword [0x6bb530]
test eax, eax
je 0x51bfe4
dec dword [eax + 0xb4]
push dword [ebp - 0x14]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
push 0x52f650
push 2
push 0xc
lea eax, [esi + 0x64]
mov byte [ebp - 4], 5
push eax
call fcn.0055ec38
mov dword [ebp - 4], 0xffffffff
mov eax, dword [0x6bb530]
test eax, eax
je 0x51c01c
dec dword [eax + 0xb4]
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
inc ebx
cmp ebx, dword [edi + 0x47bc]
jl 0x51bf80
mov ecx, dword [edi + 0x47c4]
test ecx, ecx
je 0x51c074
mov eax, dword [0x6bb530]
mov dword [edi + 0x47c0], 0
mov dword [edi + 0x47bc], 0
test eax, eax
je 0x51c060
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x47c4], 0
lea ecx, [edi + 0x4a54]
call fcn.0052f6a0
mov ecx, dword [edi + 0x4a7c]
test ecx, ecx
je 0x51c0c0
mov eax, dword [0x6bb530]
mov dword [edi + 0x4a78], 0
mov dword [edi + 0x4a74], 0
test eax, eax
je 0x51c0ac
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4a7c], 0
mov ecx, dword [edi + 0x4a88]
test ecx, ecx
je 0x51c101
mov eax, dword [0x6bb530]
mov dword [edi + 0x4a84], 0
mov dword [edi + 0x4a80], 0
test eax, eax
je 0x51c0ed
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4a88], 0
xor esi, esi
cmp dword [edi + 0x49f8], esi
jle 0x51c14a
xor ebx, ebx
nop dword [eax]
mov eax, dword [edi + 0x4a00]
mov ecx, dword [eax + ebx + 0x18]
test ecx, ecx
je 0x51c137
mov eax, dword [0x6bb530]
test eax, eax
je 0x51c12d
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
inc esi
mov dword [ebp - 4], 0xffffffff
add ebx, 0x1c
cmp esi, dword [edi + 0x49f8]
jl 0x51c110
mov ecx, dword [edi + 0x4a00]
test ecx, ecx
je 0x51c18b
mov eax, dword [0x6bb530]
mov dword [edi + 0x49fc], 0
mov dword [edi + 0x49f8], 0
test eax, eax
je 0x51c177
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4a00], 0
lea ecx, [edi + 0x4a18]
call fcn.0052f840
xor ebx, ebx
cmp dword [edi + 0x4a0c], ebx
jle 0x51c1f5
xor ecx, ecx
mov dword [ebp - 0x10], ecx
mov esi, dword [edi + 0x4a14]
add esi, ecx
lea ecx, [esi + 0x10]
mov dword [ebp - 4], 7
call fcn.0053c090
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x51c1dc
mov eax, dword [0x6bb530]
test eax, eax
je 0x51c1d2
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [ebp - 4], 0xffffffff
inc ebx
mov ecx, dword [ebp - 0x10]
add ecx, 0x68
mov dword [ebp - 0x10], ecx
cmp ebx, dword [edi + 0x4a0c]
jl 0x51c1a5
mov ecx, dword [edi + 0x4a14]
test ecx, ecx
je 0x51c236
mov eax, dword [0x6bb530]
mov dword [edi + 0x4a10], 0
mov dword [edi + 0x4a0c], 0
test eax, eax
je 0x51c222
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4a14], 0
mov ecx, dword [edi + 0x4a4c]
test ecx, ecx
je 0x51c277
mov eax, dword [0x6bb530]
mov dword [edi + 0x4a48], 0
mov dword [edi + 0x4a44], 0
test eax, eax
je 0x51c263
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4a4c], 0
mov ecx, dword [edi + 0x5a10]
test ecx, ecx
je 0x51c2b8
mov eax, dword [0x6bb530]
mov dword [edi + 0x5a0c], 0
mov dword [edi + 0x5a08], 0
test eax, eax
je 0x51c2a4
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5a10], 0
mov ecx, dword [edi + 0x5a1c]
test ecx, ecx
je 0x51c2f9
mov eax, dword [0x6bb530]
mov dword [edi + 0x5a18], 0
mov dword [edi + 0x5a14], 0
test eax, eax
je 0x51c2e5
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5a1c], 0
mov ecx, dword [edi + 0x4abc]
test ecx, ecx
je 0x51c33a
mov eax, dword [0x6bb530]
mov dword [edi + 0x4ab8], 0
mov dword [edi + 0x4ab4], 0
test eax, eax
je 0x51c326
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4abc], 0
mov ecx, dword [edi + 0x4ac8]
test ecx, ecx
je 0x51c37b
mov eax, dword [0x6bb530]
mov dword [edi + 0x4ac4], 0
mov dword [edi + 0x4ac0], 0
test eax, eax
je 0x51c367
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4ac8], 0
mov ecx, dword [edi + 0x4ad4]
test ecx, ecx
je 0x51c3bc
mov eax, dword [0x6bb530]
mov dword [edi + 0x4ad0], 0
mov dword [edi + 0x4acc], 0
test eax, eax
je 0x51c3a8
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x4ad4], 0
mov dword [edi + 0x591c], 0
mov ecx, dword [edi + 0x5928]
test ecx, ecx
je 0x51c407
mov eax, dword [0x6bb530]
mov dword [edi + 0x5924], 0
mov dword [edi + 0x5920], 0
test eax, eax
je 0x51c3f3
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5928], 0
mov ecx, dword [edi + 0x5a68]
test ecx, ecx
je 0x51c448
mov eax, dword [0x6bb530]
mov dword [edi + 0x5a64], 0
mov dword [edi + 0x5a60], 0
test eax, eax
je 0x51c434
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5a68], 0
mov ecx, dword [edi + 0x5a5c]
test ecx, ecx
je 0x51c489
mov eax, dword [0x6bb530]
mov dword [edi + 0x5a58], 0
mov dword [edi + 0x5a54], 0
test eax, eax
je 0x51c475
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5a5c], 0
cmp dword [edi + 0x5aac], 0
je 0x51c4bb
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 0x51c4b1
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 0x51c4fc
mov eax, dword [0x6bb530]
mov dword [edi + 0x5ab4], 0
mov dword [edi + 0x5ab0], 0
test eax, eax
je 0x51c4e8
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5ab8], 0
mov ecx, dword [edi + 0x5ae4]
test ecx, ecx
je 0x51c53d
mov eax, dword [0x6bb530]
mov dword [edi + 0x5ae0], 0
mov dword [edi + 0x5adc], 0
test eax, eax
je 0x51c529
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5ae4], 0
mov ecx, dword [edi + 0x5af0]
test ecx, ecx
je 0x51c57e
mov eax, dword [0x6bb530]
mov dword [edi + 0x5aec], 0
mov dword [edi + 0x5ae8], 0
test eax, eax
je 0x51c56a
dec dword [eax + 0xb4]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov dword [edi + 0x5af0], 0
mov dword [edi + 0x5af4], 0
mov byte [edi], 0
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret