Function at 0x539c04
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ecx, 0x2f
push 0
push 0
dec ecx
jne 0x539c0d
push ecx
xchg dword [ebp - 4], ecx
push ebx
push esi
push edi
mov dword [ebp - 8], ecx
mov dword [ebp - 4], edx
mov esi, eax
lea eax, [ebp - 4]
call fcn.00404eac
lea eax, [ebp - 8]
call fcn.00404eac
lea eax, [ebp + 8]
call fcn.00404eac
xor eax, eax
push ebp
push 0x53a41e
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 8]
xor edx, edx
call fcn.00404c1c
jne 0x539c6f
push 0
mov cx, word [0x53a434]
xor edx, edx
mov eax, 0x53a43c
call fcn.00494ac0
jmp 0x53a336
cmp byte [esi + 0x459], 0
je 0x539c9e
mov eax, dword [ebp + 8]
xor edx, edx
call fcn.00404c1c
jne 0x539c9e
push 0
mov cx, word [0x53a434]
xor edx, edx
mov eax, 0x53a470
call fcn.00494ac0
jmp 0x53a336
lea eax, [ebp - 0xf0]
mov edx, 0xcc
call fcn.0040780c
mov eax, dword [ebp + 8]
push eax
lea eax, [ebp - 0xf0]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.00536dd4
mov edi, eax
xor ebx, ebx
test edi, edi
jne 0x539cd5
mov bl, 1
jmp 0x539d5e
push 0
lea eax, [ebp - 0x100]
push eax
lea edx, [ebp - 0x10c]
mov eax, edi
call fcn.004c0594
mov eax, dword [ebp - 0x10c]
mov dword [ebp - 0x108], eax
mov byte [ebp - 0x104], 0xb
lea edx, [ebp - 0x108]
xor ecx, ecx
mov eax, 0x53a564
call fcn.0040a8c8
mov edx, dword [ebp - 0x100]
lea eax, [ebp - 0xfc]
call fcn.0040441c
mov eax, dword [ebp - 0xfc]
lea edx, [ebp - 0xf8]
call fcn.00537c9c
mov edx, dword [ebp - 0xf8]
lea eax, [ebp - 0xf4]
call fcn.00404a78
mov eax, dword [ebp - 0xf4]
mov cx, word [0x53a65c]
mov dl, 3
call fcn.00494ac0
cmp eax, 6
jne 0x539d5e
mov bl, 1
test bl, bl
je 0x53a336
cmp byte [esi + 0x45a], 0
je 0x539d7f
mov edx, 0x53a664
mov eax, dword [esi + 0x41c]
call fcn.004933fc
cmp byte [esi + 0x45b], 0
je 0x539e17
cmp byte [esi + 0x45a], 0
je 0x539dc5
lea edx, [ebp - 0x110]
mov ebx, dword [esi + 0x41c]
mov eax, ebx
call fcn.004933cc
lea eax, [ebp - 0x110]
mov edx, 0x53a6a4
call fcn.00404b10
mov edx, dword [ebp - 0x110]
mov eax, ebx
call fcn.004933fc
lea edx, [ebp - 0x114]
mov ebx, dword [esi + 0x41c]
mov eax, ebx
call fcn.004933cc
lea eax, [ebp - 0x114]
mov edx, 0x53a6ac
call fcn.00404b10
mov edx, dword [ebp - 0x114]
mov eax, ebx
call fcn.004933fc
lea edx, [ebp - 0x118]
mov eax, dword [esi + 0x468]
call fcn.00486498
mov edx, dword [ebp - 0x118]
mov eax, dword [esi + 0x41c]
call fcn.004933ac
mov eax, dword [esi + 0x41c]
mov edx, dword [eax]
call dword [edx + 0x3c]
test al, al
je 0x53a336
lea edx, [ebp - 0x10]
mov eax, dword [esi + 0x41c]
call fcn.004932f0
cmp byte [esi + 0x45a], 0
je 0x53a143
mov eax, dword [esi + 0x41c]
call fcn.004351f0
dec eax
jne 0x53a143
lea edx, [ebp - 0x120]
mov eax, dword [ebp - 0x10]
call fcn.004864d0
mov eax, dword [ebp - 0x120]
lea edx, [ebp - 0x11c]
call fcn.00485f80
mov eax, dword [ebp - 0x11c]
mov edx, 0x53a6d8
call fcn.00404c1c
je 0x539e95
lea eax, [ebp - 0x10]
mov edx, 0x53a6d8
call fcn.00404b10
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x128]
mov edx, dword [esi + 0x45c]
call fcn.00404a78
mov eax, dword [ebp - 0x128]
lea edx, [ebp - 0x124]
call fcn.00486338
lea eax, [ebp - 0x124]
push eax
lea ecx, [ebp - 0x134]
mov dx, 0x20
mov eax, dword [esi + 0x460]
call fcn.00532fb0
mov eax, dword [ebp - 0x134]
lea ecx, [ebp - 0x130]
mov dx, 0x2f
call fcn.00532fb0
mov eax, dword [ebp - 0x130]
lea ecx, [ebp - 0x12c]
mov dx, 0x5c
call fcn.00532fb0
mov edx, dword [ebp - 0x12c]
pop eax
call fcn.00404b10
mov eax, dword [ebp - 0x124]
mov dword [ebp - 0x108], eax
mov byte [ebp - 0x104], 0xf
lea edx, [ebp - 0x108]
xor ecx, ecx
mov eax, 0x53a6e8
call fcn.0040a8c8
cmp byte [esi + 0x458], 0
je 0x53a002
mov eax, dword [ebp + 8]
push eax
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.005399d0
xor eax, eax
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x14]
mov edx, 0x53a74c
call fcn.00404b10
mov eax, dword [ebp - 0x24]
call fcn.00404454
mov edi, eax
test edi, edi
jle 0x53a0bc
mov ebx, 1
mov eax, dword [ebp - 0x24]
movzx eax, byte [eax + ebx - 1]
lea ecx, [ebp - 0x140]
mov edx, 2
call fcn.00409650
mov eax, dword [ebp - 0x140]
lea edx, [ebp - 0x13c]
call fcn.00408d8c
mov edx, dword [ebp - 0x13c]
lea eax, [ebp - 0x138]
call fcn.00404a78
mov edx, dword [ebp - 0x138]
lea eax, [ebp - 0x14]
call fcn.00404b10
mov eax, dword [ebp - 0x24]
call fcn.00404454
cmp ebx, eax
je 0x539ff9
lea eax, [ebp - 0x14]
mov edx, 0x53a768
call fcn.00404b10
inc dword [ebp - 0xc]
cmp dword [ebp - 0xc], 0x14
jle 0x539ff9
lea eax, [ebp - 0x14]
mov edx, 0x53a770
call fcn.00404b10
xor eax, eax
mov dword [ebp - 0xc], eax
inc ebx
dec edi
jne 0x539f7d
jmp 0x53a0bc
lea eax, [ebp - 0x144]
push eax
mov al, byte [0x53a778]
push eax
push 0
lea eax, [ebp - 0x158]
push eax
lea edx, [ebp - 0x15c]
mov eax, dword [esi + 0x3b0]
call fcn.0048fbec
mov eax, dword [ebp - 0x15c]
mov ecx, 0x53a780
mov edx, 0x53a78c
call fcn.00485fec
mov eax, dword [ebp - 0x158]
mov dword [ebp - 0x154], eax
mov byte [ebp - 0x150], 0xf
mov al, byte [0x53a778]
push eax
push 0
lea eax, [ebp - 0x160]
push eax
lea edx, [ebp - 0x164]
mov eax, dword [esi + 0x304]
call fcn.004903c0
mov eax, dword [ebp - 0x164]
mov ecx, 0x53a780
mov edx, 0x53a78c
call fcn.00485fec
mov eax, dword [ebp - 0x160]
mov dword [ebp - 0x14c], eax
mov byte [ebp - 0x148], 0xf
lea edx, [ebp - 0x154]
mov ecx, 1
mov eax, 0x53a794
call fcn.0040a8c8
mov edx, dword [ebp - 0x144]
lea eax, [ebp - 0x14]
call fcn.00404b10
cmp byte [esi + 0x446], 0
je 0x53a0f3
mov dl, 1
mov eax, dword [0x483844]
call fcn.004849a4
mov ebx, eax
mov edx, dword [ebp - 0x14]
mov eax, ebx
mov ecx, dword [eax]
call dword [ecx + 0x2c]
mov edx, dword [ebp - 0x10]
mov eax, ebx
mov ecx, dword [eax]
call dword [ecx + 0x78]
mov eax, ebx
call fcn.00403334
jmp 0x53a336
mov dl, 1
mov eax, dword [0x41adb4]
call fcn.00403304
mov ebx, eax
lea eax, [ebp - 0x168]
mov edx, dword [ebp - 0x14]
call fcn.0040441c
mov edx, dword [ebp - 0x168]
mov eax, ebx
mov ecx, dword [eax]
call dword [ecx + 0x2c]
lea eax, [ebp - 0x16c]
mov edx, dword [ebp - 0x10]
call fcn.0040441c
mov edx, dword [ebp - 0x16c]
mov eax, ebx
mov ecx, dword [eax]
call dword [ecx + 0x74]
mov eax, ebx
call fcn.00403334
jmp 0x53a336
cmp byte [esi + 0x45b], 0
je 0x53a15c
mov eax, dword [esi + 0x41c]
call fcn.004351f0
cmp eax, 2
je 0x53a17b
cmp byte [esi + 0x45a], 0
jne 0x53a336
mov eax, dword [esi + 0x41c]
call fcn.004351f0
dec eax
jne 0x53a336
cmp byte [esi + 0x458], 0
je 0x53a1e7
mov eax, dword [ebp + 8]
push eax
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.005399d0
push 0
push 2
push 0x80
push 0
mov eax, dword [ebp - 0x10]
call fcn.00404af4
xor ecx, ecx
mov edx, 0x40000000
call fcn.00486ff0
mov edi, eax
cmp edi, 0xffffffff
je 0x53a336
push 0
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [ebp - 0x24]
call fcn.00404454
push eax
mov eax, dword [ebp - 0x24]
push eax
push edi
call sub.kernel32.dll_WriteFile_1
push edi
call sub.kernel32.dll_CloseHandle
jmp 0x53a336
push 0
push 2
push 0x80
push 0
mov eax, dword [ebp - 0x10]
call fcn.00404af4
mov ebx, eax
mov eax, ebx
xor ecx, ecx
mov edx, 0x40000000
call fcn.00486ff0
mov edi, eax
cmp edi, 0xffffffff
je 0x53a29b
cmp byte [esi + 0x446], 0
je 0x53a25e
mov word [ebp - 0x16], 0xfeff
push 0
lea eax, [ebp - 0x1c]
push eax
push 2
lea eax, [ebp - 0x16]
push eax
push edi
call sub.kernel32.dll_WriteFile_1
lea eax, [ebp - 0x20]
mov edx, 0x53a7c8
call fcn.00404900
push 0
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [ebp - 0x20]
call fcn.00404b04
add eax, eax
push eax
mov eax, dword [ebp - 0x20]
push eax
push edi
call sub.kernel32.dll_WriteFile_1
push edi
call sub.kernel32.dll_CloseHandle
push ebx
mov eax, dword [ebp - 4]
call fcn.00404af4
push eax
push 0x53a800
push 0x53a80c
call sub.kernel32.dll_WritePrivateProfileStringW
push ebx
mov eax, dword [ebp - 8]
call fcn.00404af4
push eax
push 0x53a840
push 0x53a80c
call sub.kernel32.dll_WritePrivateProfileStringW
jmp 0x53a336
lea eax, [ebp - 0x174]
push eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x154], eax
mov byte [ebp - 0x150], 0xf
call sub.kernel32.dll_GetLastError
lea edx, [ebp - 0x178]
call fcn.0040d078
mov eax, dword [ebp - 0x178]
mov dword [ebp - 0x14c], eax
mov byte [ebp - 0x148], 0xb
lea eax, [ebp - 0x154]
push eax
lea edx, [ebp - 0x180]
mov eax, 0x53a850
call fcn.00537c9c
mov edx, dword [ebp - 0x180]
lea eax, [ebp - 0x17c]
call fcn.00404a78
mov eax, dword [ebp - 0x17c]
mov ecx, 1
pop edx
call fcn.0040a8c8
mov edx, dword [ebp - 0x174]
lea eax, [ebp - 0x170]
call fcn.0040441c
mov ecx, dword [ebp - 0x170]
mov dl, 1
mov eax, dword [0x407ee0]
call fcn.0040d880
call fcn.00403b00
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x53a428
lea eax, [ebp - 0x180]
call fcn.00404184
lea eax, [ebp - 0x17c]
call fcn.004048a0
lea eax, [ebp - 0x178]
call fcn.00404184
lea eax, [ebp - 0x174]
call fcn.004048a0
lea eax, [ebp - 0x170]
mov edx, 3
call fcn.004041a8
lea eax, [ebp - 0x164]
mov edx, 4
call fcn.004048b8
lea eax, [ebp - 0x144]
call fcn.004048a0
lea eax, [ebp - 0x140]
mov edx, 2
call fcn.004041a8
lea eax, [ebp - 0x138]
mov edx, 0xb
call fcn.004048b8
lea eax, [ebp - 0x10c]
call fcn.00404184
lea eax, [ebp - 0x100]
call fcn.004048a0
lea eax, [ebp - 0xfc]
mov edx, 2
call fcn.004041a8
lea eax, [ebp - 0xf4]
call fcn.004048a0
lea eax, [ebp - 0x24]
call fcn.00404184
lea eax, [ebp - 0x20]
call fcn.004048a0
lea eax, [ebp - 0x14]
mov edx, 2
call fcn.004048b8
lea eax, [ebp - 8]
mov edx, 2
call fcn.004048b8
lea eax, [ebp + 8]
call fcn.004048a0
ret