Function at 0x40ca70
Capabilities:
Get proxy
Query or enumerate registry value
Read .ini file

Disassembly:
sub esp, 0x62c
mov eax, dword [0x42e070]
xor eax, esp
mov dword [esp + 0x628], eax
push ebp
mov ebp, dword [esp + 0x634]
push esi
push edi
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0x22e]
push ecx
mov word [esp + 0x230], ax
call fcn.00410d60
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x32]
push eax
mov word [esp + 0x34], dx
call fcn.00410d60
xor ecx, ecx
push 0x206
push ecx
lea edx, [esp + 0x44e]
push edx
mov word [esp + 0x450], cx
call fcn.00410d60
push 0x430728
push str._semlscn.ini
lea edx, [esp + 0x458]
call fcn.0040d990
add esp, 0x2c
lea eax, [esp + 0x42c]
push eax
push 0x104
lea ecx, [esp + 0x24]
push ecx
push 0x424e08
push 0x428d60
push str.USID
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0x1c]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40cb26
sub eax, edx
sar eax, 1
je 0x40cd00
push str.SoftwareMicrosoftWindowsCurrentVersionInternet_Settings
lea edx, [esp + 0x20]
push 0x104
push edx
call fcn.0040ec9c
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
add esp, 0xc
lea eax, [esp + 0xc]
push eax
push 0x20019
push 0
lea ecx, [esp + 0x28]
push ecx
push reloc.WS2_32.dll_closesocket
call esi
test eax, eax
je 0x40cbc0
call fcn.0040cd20
push eax
lea edx, [esp + 0x20]
push 0x104
push edx
call fcn.0040ee2f
push str.SoftwareMicrosoftWindowsCurrentVersionInternet_Settings
lea eax, [esp + 0x2c]
push 0x104
push eax
call fcn.0040ec9c
add esp, 0x18
lea ecx, [esp + 0xc]
push ecx
push 0x20019
push 0
lea edx, [esp + 0x28]
push edx
push reloc.WS2_32.dll_closesocket
call esi
test eax, eax
jne 0x40cd00
mov edx, dword [esp + 0xc]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x228]
push ecx
push 0
push 0
push str.ProxyServer
push edx
mov dword [esp + 0x2c], 0x208
call esi
mov ecx, dword [esp + 0xc]
lea eax, [esp + 0x10]
push eax
push ebx
push 0
push 0
push str.ProxyPort
push ecx
mov dword [esp + 0x28], 4
call esi
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [esp + 0x224]
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40cc20
sub eax, edx
sar eax, 1
je 0x40cd00
lea eax, [esp + 0x224]
push str.socks
push eax
call fcn.0040f329
add esp, 8
mov edi, eax
push 0x3a
test edi, edi
je 0x40cca9
add edi, 0xc
push edi
call fcn.0040f52e
mov esi, eax
add esp, 8
test esi, esi
je 0x40cd00
push edi
push 0x426d04
xor ecx, ecx
push 0x104
push ebp
mov word [esi], cx
call fcn.0040fcda
add esi, 2
push esi
call fcn.004101f5
add esp, 0x14
pop edi
pop esi
mov dword [ebx], eax
mov eax, 1
pop ebp
mov ecx, dword [esp + 0x628]
xor ecx, esp
call fcn.0040e6d9
add esp, 0x62c
ret
lea edx, [esp + 0x228]
push edx
call fcn.0040f52e
add esp, 8
test eax, eax
je 0x40cd00
lea edx, [esp + 0x224]
push edx
push 0x426d04
xor ecx, ecx
push 0x104
push ebp
mov word [eax], cx
call fcn.0040fcda
add esp, 0x10
pop edi
pop esi
mov dword [ebx], 0x438
mov eax, 1
pop ebp
mov ecx, dword [esp + 0x628]
xor ecx, esp
call fcn.0040e6d9
add esp, 0x62c
ret
mov ecx, dword [esp + 0x634]
pop edi
pop esi
pop ebp
xor ecx, esp
xor eax, eax
call fcn.0040e6d9
add esp, 0x62c
ret