Function at 0x1003d760
Capabilities:
Initialize winsock library

Disassembly:
push ebp
lea ebp, [esp - 0x39c]
sub esp, 0x39c
push 0xffffffffffffffff
push 0x10078d05
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x100c0040]
xor eax, ebp
mov dword [ebp + 0x398], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, dword [ebp + 0x3a4]
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x44], ebx
mov byte [ebp - 0x40], 0
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 4], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x30], 0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x44]
call fcn.1003d440
mov dword [ebp - 4], 2
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
mov byte [ebp - 4], 3
lea eax, [ebp - 0x10]
push eax
push 0x100a416c
push str.AI_BIND_TCP_HOST
mov dword [ebp - 0x14], 0
push ebx
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x10], 0
call dword [sym.imp.msi.dll_MsiGetSummaryInformationW]
mov edx, 2
cmp eax, 0xea
jne 0x1003d85d
mov esi, dword [ebp - 0x10]
xor ecx, ecx
inc esi
mov eax, esi
mov dword [ebp - 0x10], esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
lea eax, [ebp - 0x10]
push eax
push edi
push str.AI_BIND_TCP_HOST
mov dword [ebp - 0x14], edi
push ebx
mov dword [ebp - 0x18], esi
call dword [sym.imp.msi.dll_MsiGetSummaryInformationW]
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov byte [ebp - 4], 4
lea eax, [ebp - 0x10]
push eax
push 0x100a416c
xor edi, edi
push str.AI_SEARCH_TCP_PORT
mov dword [ebp - 0x1c], edi
push ebx
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x10], edi
call dword [sym.imp.msi.dll_MsiGetSummaryInformationW]
cmp eax, 0xea
jne 0x1003d8d1
mov esi, dword [ebp - 0x10]
xor ecx, ecx
inc esi
mov edx, 2
mov eax, esi
mov dword [ebp - 0x10], esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
lea eax, [ebp - 0x10]
push eax
push edi
push str.AI_SEARCH_TCP_PORT
mov dword [ebp - 0x1c], edi
push ebx
mov dword [ebp - 0x20], esi
call dword [sym.imp.msi.dll_MsiGetSummaryInformationW]
push 0xa
lea edx, [ebp - 0x10]
mov dword [ebp - 0x10], 0xffffffff
mov ecx, edi
call fcn.10033e40
movzx ecx, word [edi]
mov esi, eax
add esp, 4
mov dword [ebp - 0x10], esi
mov eax, ecx
test cx, cx
je 0x1003d91b
mov ecx, edi
mov edx, eax
nop word [eax + eax]
lea eax, [edx - 0x30]
cmp ax, 9
ja 0x1003da51
movzx eax, word [ecx + 2]
add ecx, 2
mov edx, eax
test ax, ax
jne 0x1003d900
test esi, esi
jle 0x1003da51
cmp esi, 0xffff
jge 0x1003da51
xor edi, edi
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x28], edi
mov byte [ebp - 4], 5
xor esi, esi
mov ecx, dword [ebp - 0x14]
mov eax, ecx
cmp word [ecx], si
je 0x1003d996
nop dword [eax + eax]
lea eax, [eax + 2]
inc esi
cmp word [eax], 0
jne 0x1003d950
test esi, esi
je 0x1003d996
inc esi
push esi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
mov dword [ebp - 0x28], edi
mov ecx, edi
mov eax, dword [ebp - 0x14]
mov edx, eax
mov dword [ebp - 0x2c], esi
movzx ebx, word [eax]
test bx, bx
je 0x1003d990
nop
mov byte [ecx], bl
lea edx, [edx + 2]
movzx eax, word [edx]
inc ecx
mov bl, al
test ax, ax
jne 0x1003d980
mov ebx, dword [ebp - 0x24]
mov byte [ecx], 0
push 0x190
lea eax, [ebp]
push 0
push eax
call fcn.10055bd0
add esp, 0xc
lea eax, [ebp]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x1003d9cf
push str.SockError
push str.AI_PORT_TEST_RES
push ebx
call dword [sym.imp.msi.dll_MsiSummaryInfoGetPropertyCount]
jmp 0x1003da2f
mov eax, dword [ebp - 0x10]
movzx esi, ax
mov eax, 0xffff
cmp si, ax
jae 0x1003d9f7
mov ebx, eax
mov edx, esi
mov ecx, edi
call fcn.10019f20
test eax, eax
je 0x1003d9f4
inc esi
cmp si, bx
jb 0x1003d9e1
mov ebx, dword [ebp - 0x24]
movzx ecx, si
lea edx, [ebp + 0x190]
call fcn.1002e8f0
lea eax, [ebp + 0x190]
push eax
push str.AI_SEARCH_TCP_PORT
push ebx
call dword [sym.imp.msi.dll_MsiSummaryInfoGetPropertyCount]
push str.FreePort
push str.AI_PORT_TEST_RES
push ebx
call dword [sym.imp.msi.dll_MsiSummaryInfoGetPropertyCount]
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov byte [ebp - 4], 4
test edi, edi
je 0x1003da3e
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov edi, dword [ebp - 0x1c]
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x2c], 0
jmp 0x1003da62
push str.SockError
push str.AI_PORT_TEST_RES
push ebx
call dword [sym.imp.msi.dll_MsiSummaryInfoGetPropertyCount]
mov byte [ebp - 4], 3
test edi, edi
je 0x1003da71
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x20], 0
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x1003da91
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x44]
call fcn.1003d360
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x398]
xor ecx, ebp
call fcn.10053e7d
lea esp, [ebp + 0x39c]
pop ebp
ret 4