Function at 0x402220
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5dbd57
mov eax, dword fs:[0]
push eax
sub esp, 0x178
mov eax, dword [0x65b4e4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x15c], ecx
lea eax, [ebp - 0xe8]
push eax
call fcn.00404950
mov ecx, eax
call fcn.004092f0
mov dword [ebp - 0x160], eax
mov ecx, dword [ebp - 0x160]
mov dword [ebp - 0x164], ecx
mov dword [ebp - 4], 0
push 0x6298f4
mov edx, dword [ebp - 0x164]
push edx
lea eax, [ebp - 0x104]
push eax
call fcn.00404a40
add esp, 0xc
mov dword [ebp - 0x168], eax
mov ecx, dword [ebp - 0x168]
mov dword [ebp - 0x16c], ecx
mov byte [ebp - 4], 1
push 0x6298f0
mov edx, dword [ebp - 0x16c]
push edx
lea eax, [ebp - 0x2c]
push eax
call fcn.00404a40
add esp, 0xc
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x104]
call fcn.0040c050
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xe8]
call fcn.0040c050
push str.actionp2p.log
lea ecx, [ebp - 0x2c]
call fcn.004024c0
mov ecx, dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x4c]
call fcn.0040c070
mov byte [ebp - 4], 5
push 0x629908
lea ecx, [ebp - 0x2c]
call fcn.0040bf30
push eax
call fcn.005b0ac9
add esp, 8
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
je 0x402485
lea edx, [ebp - 0x120]
push edx
call fcn.004fffc0
add esp, 4
mov dword [ebp - 0x170], eax
mov eax, dword [ebp - 0x170]
mov dword [ebp - 0x174], eax
mov byte [ebp - 4], 6
mov ecx, dword [ebp - 0x174]
call fcn.0040bf30
push eax
call sub.KERNEL32.dll_GetCurrentThreadId
push eax
push str._ThreadId_lu__t__s__r_n
push 0x80
lea ecx, [ebp - 0xcc]
push ecx
call fcn.005b0ba7
add esp, 0x14
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x120]
call fcn.0040c050
lea edx, [ebp - 0xcc]
mov dword [ebp - 0x178], edx
mov eax, dword [ebp - 0x178]
add eax, 1
mov dword [ebp - 0x17c], eax
mov ecx, dword [ebp - 0x178]
mov dl, byte [ecx]
mov byte [ebp - 0x17d], dl
add dword [ebp - 0x178], 1
cmp byte [ebp - 0x17d], 0
jne 0x40239e
mov eax, dword [ebp - 0x178]
sub eax, dword [ebp - 0x17c]
mov dword [ebp - 0x184], eax
mov ecx, dword [ebp - 0x30]
push ecx
push 1
mov edx, dword [ebp - 0x184]
push edx
lea eax, [ebp - 0xcc]
push eax
call fcn.005b0d41
add esp, 0x10
push 0x629924
lea ecx, [ebp - 0x13c]
call fcn.0040bf50
mov byte [ebp - 4], 7
push 0x629928
lea ecx, [ebp - 0x158]
call fcn.0040bf50
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x13c]
push ecx
lea edx, [ebp - 0x158]
push edx
lea eax, [ebp - 0x4c]
push eax
call fcn.004fb430
add esp, 0xc
mov byte [ebp - 4], 7
lea ecx, [ebp - 0x158]
call fcn.0040c050
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x13c]
call fcn.0040c050
lea ecx, [ebp - 0x4c]
call fcn.0040bf30
push eax
push 0x62992c
mov ecx, dword [ebp - 0x30]
push ecx
call fcn.005b0dc3
add esp, 0xc
mov edx, dword [ebp - 0x30]
push edx
push 1
push 2
push 0x629930
call fcn.005b0d41
add esp, 0x10
mov eax, dword [ebp - 0x30]
push eax
call fcn.005b0f84
add esp, 4
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x4c]
call fcn.0040c050
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.0040c050
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005b0968
mov esp, ebp
pop ebp
ret 4