Function at 0x10004360
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
mov eax, dword [0x10054278]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_HeapAlloc]
push edi
push 0xc10
push 8
push eax
mov dword [ebp - 8], 0xc00
call esi
mov edi, eax
test edi, edi
je 0x1000439a
push 0xc10
push 0
push edi
call sub.ntdll.dll_memset
add esp, 0xc
mov dword [ebp - 0xc], edi
mov dword [ebp - 0x48], str.CLOSED
mov dword [ebp - 0x44], str.LISTEN
mov dword [ebp - 0x40], str.SYN_SENT
mov dword [ebp - 0x3c], str.SYN_RCVD
mov dword [ebp - 0x38], str.ESTAB
mov dword [ebp - 0x34], str.FIN_WAIT1
mov dword [ebp - 0x30], str.FIN_WAIT2
mov dword [ebp - 0x2c], str.CLOSE_WAIT
mov dword [ebp - 0x28], str.CLOSING
mov dword [ebp - 0x24], str.LAST_ACK
mov dword [ebp - 0x20], str.TIME_WAIT
mov dword [ebp - 0x1c], str.DELETE_TCB
test edi, edi
je 0x100046ba
push ebx
push 1
lea ecx, [ebp - 8]
push ecx
push edi
call dword [sym.imp.IPHLPAPI.DLL_GetTcpTable]
cmp eax, 0x7a
jne 0x10004476
mov edx, dword [0x10054278]
push edi
push 0
push edx
call dword [sym.imp.KERNEL32.dll_HeapValidate]
test eax, eax
je 0x1000442f
mov eax, dword [0x10054278]
push edi
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov edi, dword [ebp - 8]
xor ebx, ebx
test edi, edi
je 0x1000445c
mov ecx, dword [0x10054278]
add edi, 0x13
and edi, 0xfffffff0
push edi
push 8
push ecx
call esi
mov ebx, eax
test ebx, ebx
je 0x1000445c
push edi
push 0
push ebx
call sub.ntdll.dll_memset
add esp, 0xc
mov dword [ebp - 0xc], ebx
test ebx, ebx
je 0x100046b9
push 1
lea edx, [ebp - 8]
push edx
push ebx
call dword [sym.imp.IPHLPAPI.DLL_GetTcpTable]
mov edi, ebx
test eax, eax
je 0x100044aa
mov eax, dword [0x10054278]
push edi
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapValidate]
test eax, eax
je 0x100046b9
mov ecx, dword [0x10054278]
push edi
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
mov ebx, dword [edi]
imul ebx, ebx, 0x64
add ebx, 0x96
mov dword [ebp - 0x18], ebx
je 0x1000455d
mov edx, dword [0x10054278]
add ebx, 0x13
and ebx, 0xfffffff0
push ebx
push 8
push edx
call esi
mov esi, eax
mov dword [ebp - 4], esi
test esi, esi
je 0x1000455d
push ebx
push 0
push esi
call sub.ntdll.dll_memset
mov eax, str.netstat_nProto_tLocal_address_tRemote_address_tState_n
mov edx, esi
add esp, 0xc
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x100044f2
cmp dword [edi], 0
mov dword [ebp - 0x14], 0
jle 0x1000461e
add edi, 0x10
nop
mov eax, dword [edi - 8]
push eax
call fcn.10004270
mov ebx, eax
test ebx, ebx
je 0x10004609
mov ecx, dword [edi]
push ecx
call fcn.10004270
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x1000456d
mov edx, dword [0x10054278]
push ebx
push eax
push edx
call dword [sym.imp.KERNEL32.dll_HeapValidate]
test eax, eax
je 0x10004609
mov eax, dword [0x10054278]
push ebx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x10004609
mov esi, edi
call fcn.1000e820
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
mov eax, esi
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10004572
mov ecx, dword [edi - 0xc]
mov edx, dword [ebp + ecx*4 - 0x4c]
sub eax, esi
mov esi, eax
movzx eax, word [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
mov edx, dword [ebp - 0x10]
movzx ecx, ax
movzx eax, word [edi - 4]
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
mov edx, dword [ebp - 0x18]
add esi, dword [ebp - 4]
movzx ecx, ax
push ecx
push ebx
push str.TCP_t_s:_d_t_s:_d_t_s_n
push edx
push esi
call dword [sym.imp.ntdll.dll__snprintf]
mov ecx, dword [0x10054278]
mov esi, dword [sym.imp.KERNEL32.dll_HeapValidate]
add esp, 0x20
push ebx
push 0
push ecx
call esi
test eax, eax
je 0x100045e4
mov edx, dword [0x10054278]
push ebx
push 0
push edx
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov ebx, dword [ebp - 0x10]
mov eax, dword [0x10054278]
push ebx
push 0
push eax
call esi
test eax, eax
je 0x10004606
mov ecx, dword [0x10054278]
push ebx
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov esi, dword [ebp - 4]
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0xc]
inc eax
add edi, 0x14
mov dword [ebp - 0x14], eax
cmp eax, dword [edx]
jl 0x10004510
lea eax, [esi - 1]
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x10004621
mov cx, word [0x10047028]
mov word [eax], cx
mov dl, byte [0x1004702a]
mov byte [eax + 2], dl
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10004641
sub eax, edx
mov ebx, eax
mov dword [ebp - 0x18], 0
je 0x10004696
mov edi, dword [ebp + 8]
push 1
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push ebx
push 0
mov esi, eax
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LockFile]
mov ecx, dword [ebp - 4]
push 0
lea eax, [ebp - 0x18]
push eax
push ebx
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
push ebx
push 0
push esi
push edi
call dword [sym.imp.KERNEL32.dll_UnlockFile]
mov esi, dword [ebp - 4]
mov edx, dword [0x10054278]
push esi
push 0
push edx
call dword [sym.imp.KERNEL32.dll_HeapValidate]
test eax, eax
je 0x100046b9
mov eax, dword [0x10054278]
push esi
push 0
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4