Function at 0x413ea0
Capabilities:
Get hostname
Initialize winsock library
Read .ini file
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x488
mov eax, dword [0x4a0270]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov dword [ebp - 8], ecx
mov dword [ebp - 0x308], 1
jmp 0x413ed4
mov eax, dword [ebp - 0x308]
add eax, 1
mov dword [ebp - 0x308], eax
cmp dword [ebp - 0x308], 0x64
jg 0x413f6e
mov byte [ebp - 0x36c], 0
push 0x63
push 0
lea eax, [ebp - 0x36b]
push eax
call fcn.0045f1b0
add esp, 0xc
mov dword [ebp - 0x370], 0
mov eax, dword [ebp - 0x308]
push eax
push str.Key_d
lea ecx, [ebp - 0x36c]
push ecx
call fcn.0045ee9d
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 0x108
push eax
push SysReAllocString
lea ecx, [ebp - 0x36c]
push ecx
push str.Client
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
mov dword [ebp - 0x370], eax
cmp dword [ebp - 0x370], 0x7fffffff
jne 0x413f54
jmp 0x413f6e
push 2
mov eax, dword [ebp - 0x370]
push eax
call fcn.004121a0
mov ecx, eax
call fcn.004148d0
jmp 0x413ec5
mov dword [ebp - 0x374], 1
jmp 0x413f89
mov eax, dword [ebp - 0x374]
add eax, 1
mov dword [ebp - 0x374], eax
cmp dword [ebp - 0x374], 0x64
jg 0x414023
mov byte [ebp - 0x3d8], 0
push 0x63
push 0
lea eax, [ebp - 0x3d7]
push eax
call fcn.0045f1b0
add esp, 0xc
mov dword [ebp - 0x3dc], 0
mov eax, dword [ebp - 0x374]
push eax
push str.Key_d
lea ecx, [ebp - 0x3d8]
push ecx
call fcn.0045ee9d
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 0x108
push eax
push SysReAllocString
lea ecx, [ebp - 0x3d8]
push ecx
push str.Server
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
mov dword [ebp - 0x3dc], eax
cmp dword [ebp - 0x3dc], 0x7fffffff
jne 0x414009
jmp 0x414023
push 1
mov eax, dword [ebp - 0x3dc]
push eax
call fcn.004121a0
mov ecx, eax
call fcn.004148d0
jmp 0x413f7a
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerMaxUser
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x300], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.NoResponseLimitCount
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x304], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerDefaultAllocSize
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x308], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerAddAllocSize
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x30c], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerLogLevel
push str.LogInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov word [ecx + 0x20c], ax
mov eax, dword [ebp - 8]
mov byte [eax + 0x4bc], 0x43
mov eax, dword [ebp - 8]
mov byte [eax + 0x4bd], 0
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerLogPath
push str.LogInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov eax, dword [ebp - 8]
mov cl, byte [ebp - 0x6c]
mov byte [eax + 0x4bc], cl
mov eax, dword [ebp - 8]
mov byte [eax + 0x4bd], 0
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f110
push str.HDDCheckValueGB
push str.LogInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x4c0], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.GameDB
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
mov ecx, dword [ebp - 8]
add ecx, 0x214
push ecx
call fcn.0045eb30
add esp, 8
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.LogDB
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
mov ecx, dword [ebp - 8]
add ecx, 0x228
push ecx
call fcn.0045eb30
add esp, 8
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push str.CF_GAMEDB
push str.GuildDB
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
mov ecx, dword [ebp - 8]
add ecx, 0x23c
push ecx
call fcn.0045eb30
add esp, 8
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.DBPoint
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
mov ecx, dword [ebp - 8]
add ecx, 0x250
push ecx
call fcn.0045eb30
add esp, 8
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerProperty
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov word [ecx + 0x20e], ax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ClientVersion
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x210], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f0b0
push str.ConnectTimeOut
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x4b8], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov word [ebp - 0x70], 2
lea eax, [ebp - 0x200]
push eax
mov cx, word [ebp - 0x70]
push ecx
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x4144be
push 0xff
lea eax, [ebp - 0x300]
push eax
call dword [sym.imp.WS2_32.dll_gethostname]
test eax, eax
jne 0x4144b8
lea eax, [ebp - 0x300]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 0x304], eax
cmp dword [ebp - 0x304], 0
je 0x41449f
mov eax, dword [ebp - 0x304]
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
lea ecx, [ebp - 0x6c]
push ecx
call fcn.0045eb30
add esp, 8
lea eax, [ebp - 0x300]
push eax
mov ecx, dword [ebp - 8]
add ecx, 0x264
push ecx
call fcn.0045eb30
add esp, 8
call dword [sym.imp.WS2_32.dll_WSACleanup]
push str.0.0.0.0
mov eax, dword [ebp - 8]
add eax, 0x2c9
push eax
call fcn.0045eb30
add esp, 8
push 0xb
push str.211.240.11.
mov eax, dword [ebp - 8]
add eax, 0x2c9
push eax
call fcn.0046179f
add esp, 0xc
test eax, eax
je 0x41450a
push str.211.43.215.41
mov eax, dword [ebp - 8]
add eax, 0x2c9
push eax
call fcn.00460a60
add esp, 8
test eax, eax
jne 0x414519
mov eax, dword [ebp - 8]
mov dword [eax + 0x320], 1
jmp 0x414526
mov eax, dword [ebp - 8]
mov dword [eax + 0x320], 0
mov eax, dword [ebp - 8]
add eax, 0x2c9
push eax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x2ec], eax
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerServiceForcePort
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x2f0], eax
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x2f0]
mov dword [eax + 0x2f4], edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax + 0x2f0]
add ecx, 1
mov edx, dword [ebp - 8]
mov dword [edx + 0x2f8], ecx
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48dd60
push str.ServerServiceForcePort
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x2f0], eax
mov dword [ebp - 0x3e0], 0
jmp 0x41460e
mov eax, dword [ebp - 0x3e0]
add eax, 1
mov dword [ebp - 0x3e0], eax
cmp dword [ebp - 0x3e0], 0x64
jge 0x41469e
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
push 0x64
push 0
lea eax, [ebp - 0x444]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 0x3e0]
push eax
push str._d_ServerList
lea ecx, [ebp - 0x444]
push ecx
call fcn.0045ee9d
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f050
lea edx, [ebp - 0x444]
push edx
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 0x3e0]
mov edx, dword [ebp - 8]
mov dword [edx + ecx*4 + 0x328], eax
jmp 0x4145ff
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f050
push str.ValidCheck
push str.BridgeServerExist
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push 0x48f02c
lea eax, [ebp - 0x6c]
push eax
call fcn.00460a60
add esp, 8
test eax, eax
jne 0x4146fe
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x310], 1
mov dword [ebp - 0x488], 1
jmp 0x414715
mov edx, dword [ebp - 8]
mov dword [edx + 0x310], 0
mov dword [ebp - 0x488], 0
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f050
push str.MMSValidCheck
push str.BridgeServerExist
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push 0x48f02c
lea eax, [ebp - 0x6c]
push eax
call fcn.00460a60
add esp, 8
test eax, eax
jne 0x414775
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x314], 1
mov dword [ebp - 0x488], 1
jmp 0x41478c
mov edx, dword [ebp - 8]
mov dword [edx + 0x314], 0
mov dword [ebp - 0x488], 0
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f050
push str.PMSConn
push str.BridgeServerExist
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push 0x48f02c
lea eax, [ebp - 0x6c]
push eax
call fcn.00460a60
add esp, 8
test eax, eax
jne 0x4147ec
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x318], 1
mov dword [ebp - 0x488], 1
jmp 0x414803
mov edx, dword [ebp - 8]
mov dword [edx + 0x318], 0
mov dword [ebp - 0x488], 0
push 0x64
push 0
lea eax, [ebp - 0x6c]
push eax
call fcn.0045f1b0
add esp, 0xc
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48f050
push str.CloseBetaUserCheck
push str.BridgeServerExist
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push 0x48f02c
lea eax, [ebp - 0x6c]
push eax
call fcn.00460a60
add esp, 8
test eax, eax
jne 0x414863
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x31c], 1
mov dword [ebp - 0x488], 1
jmp 0x41487a
mov edx, dword [ebp - 8]
mov dword [edx + 0x31c], 0
mov dword [ebp - 0x488], 0
mov eax, dword [ebp - 8]
add eax, 4
push eax
push 0x64
lea ecx, [ebp - 0x6c]
push ecx
push 0x48effc
push 0x48eff8
push str.ServerInfo
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x6c]
push eax
call fcn.00460430
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x324], eax
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045ee62
mov esp, ebp
pop ebp
ret