Function at 0x405ee0
Capabilities:
Create directory
Hide graphical window
Initialize winsock library
Read .ini file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x338
mov eax, dword [0x439008]
xor eax, esp
mov dword [esp + 0x334], eax
push esi
push edi
mov edi, dword [ebp + 8]
push 1
mov dword [esp + 0x14], edi
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0x410f10
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov esi, dword [sym.imp.USER32.dll_LoadStringA]
push 0x64
push 0x5cd720
push 0x67
push edi
mov dword [0x5cd71c], eax
call esi
push 0x64
push 0x5cd6b8
push 0x6d
push edi
call esi
mov esi, dword [sym.imp.USER32.dll_LoadIconA]
push 0x6b
push edi
mov dword [esp + 0x1c8], 0x30
mov dword [esp + 0x1cc], 3
mov dword [esp + 0x1d0], 0x406440
mov dword [esp + 0x1d4], 0
mov dword [esp + 0x1d8], 0
mov dword [esp + 0x1dc], edi
call esi
push 0x7f00
push 0
mov dword [esp + 0x1e0], eax
call dword [sym.imp.USER32.dll_LoadCursorA]
push 0x6c
push dword [esp + 0x1d8]
mov dword [esp + 0x1e4], eax
mov dword [esp + 0x1e8], 6
mov dword [esp + 0x1ec], 0x6d
mov dword [esp + 0x1f0], 0x5cd6b8
call esi
mov dword [esp + 0x1ec], eax
lea eax, [esp + 0x1c0]
push eax
call dword [sym.imp.USER32.dll_RegisterClassExA]
push 0
push edi
push 0
push 0
push 0x258
push 0x258
push 0
push closesocket
push 0xcf0000
push 0x5cd720
push 0x5cd6b8
push 0
mov dword [0x5cd6b4], edi
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x5cd6b0], eax
test eax, eax
jne 0x406032
pop edi
pop esi
mov ecx, dword [esp + 0x334]
xor ecx, esp
call fcn.00414177
mov esp, ebp
pop ebp
ret 0x10
push dword [ebp + 0x14]
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
push dword [0x5cd6b0]
call dword [sym.imp.USER32.dll_UpdateWindow]
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push str..DataServer.ini
push 0x32
push 0x5cd67c
push str.Resets
push str.ResetTable
push str.DataServerInfo
call esi
push 0
push str.1.0.1.3
lea eax, [esp + 0x240]
push str.__s__DataServer__QueueSize_:__d_
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [esp + 0x238]
push eax
push dword [0x5cd6b0]
call dword [sym.imp.USER32.dll_SetWindowTextA]
mov eax, dword [0x5cd6b0]
mov dword [0x5cbb8c], eax
mov eax, dword [0x439d00]
test eax, eax
jne 0x4061a1
imul edi, eax, 0x214
inc eax
push 0x435764
push 0x100
mov dword [0x439d00], eax
add edi, 0x439aec
lea esi, [edi + 4]
mov dword [edi], 1
push esi
call fcn.0041789d
add esp, 0xc
cmp dword [edi], 0
je 0x406197
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea eax, [esp + 0x1f0]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx edx, word [esp + 0x1f6]
lea esi, [edi + 0x110]
movzx ecx, word [esp + 0x1f2]
movzx eax, word [esp + 0x1f0]
push edx
push ecx
push eax
mov dword [edi + 0x10c], eax
lea eax, [edi + 4]
push eax
push str.._s_04d__02d__02d.txt
push esi
mov dword [edi + 0x104], edx
mov dword [edi + 0x108], ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x18
push 0
push 0x80
push 4
push 0
push 1
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [edi + 0x210], eax
cmp eax, 0xffffffff
jne 0x406173
mov dword [edi], 0
jmp 0x406197
push 2
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x406197
push dword [edi + 0x210]
mov dword [edi], 0
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov edi, dword [esp + 0x10]
lea eax, [esp + 0x30]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x406378
push str..DataServer.ini
push 0x20
lea eax, [esp + 0x1c8]
xorps xmm0, xmm0
push eax
push 0x433688
push str.DataServerODBC
push str.DataServerInfo
movaps xmmword [esp + 0x1d8], xmm0
movaps xmmword [esp + 0x1e8], xmm0
movaps xmmword [esp + 0x228], xmm0
movaps xmmword [esp + 0x238], xmm0
movaps xmmword [esp + 0x208], xmm0
movaps xmmword [esp + 0x218], xmm0
call esi
push str..DataServer.ini
push 0x20
lea eax, [esp + 0x218]
push eax
push 0x433688
push str.DataServerUSER
push str.DataServerInfo
call esi
push str..DataServer.ini
push 0x20
lea eax, [esp + 0x1f8]
push eax
push 0x433688
push str.DataServerPASS
push str.DataServerInfo
call esi
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
push str..DataServer.ini
push 0xda98
push str.DataServerPort
push str.DataServerInfo
call esi
push str..DataServer.ini
push 5
push str.MaxCharacters
movzx eax, ax
push str.DataServerInfo
mov dword [esp + 0x20], eax
call esi
push str..DataServer.ini
push 0
push str.DisableCheckName
push str.DataServerInfo
mov dword [0x5cd678], eax
call esi
push str..DataServer.ini
push 0
push str.RecycleSerial
push str.DataServerInfo
mov dword [0x5cd674], eax
call esi
mov dword [0x5cd670], eax
mov ecx, 0x439d58
lea eax, [esp + 0x1f0]
push eax
lea eax, [esp + 0x214]
push eax
lea eax, [esp + 0x1c8]
push eax
call fcn.00411220
test al, al
jne 0x4062f1
push str.Could_not_connect_to_database
push 1
call fcn.004139f0
add esp, 8
jmp 0x40638e
push dword [esp + 0x10]
call fcn.00412720
test al, al
jne 0x40634e
mov eax, dword [0x439d64]
mov esi, dword [sym.imp.ODBC32.dll_SQLFreeHandle]
test eax, eax
je 0x40631c
push eax
push 3
call esi
mov dword [0x439d64], 0
mov eax, dword [0x439d60]
test eax, eax
je 0x406334
push eax
push 2
call esi
mov dword [0x439d60], 0
mov eax, dword [0x439d5c]
test eax, eax
je 0x40638e
push eax
push 1
call esi
mov dword [0x439d5c], 0
jmp 0x40638e
push ecx
call fcn.00401660
push ecx
call fcn.00402100
mov esi, dword [sym.imp.USER32.dll_SetTimer]
push 0
push 0x3e8
push 0x64
push dword [0x5cd6b0]
call esi
call fcn.0040eea0
jmp 0x406394
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.WSAStartup___failed_with_error:__d
push 1
call fcn.004139f0
add esp, 0xc
mov esi, dword [sym.imp.USER32.dll_SetTimer]
call fcn.00412350
push 0
push 0x7d0
push 0x65
push dword [0x5cd6b0]
call esi
push 0x6d
push edi
call dword [sym.imp.USER32.dll_LoadAcceleratorsA]
mov esi, dword [sym.imp.USER32.dll_GetMessageA]
push 0
push 0
mov dword [esp + 0x18], eax
lea eax, [esp + 0x1c]
push 0
push eax
call esi
test eax, eax
je 0x40640e
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x14]
push dword [esp + 0x1c]
call dword [sym.imp.USER32.dll_TranslateAcceleratorA]
test eax, eax
jne 0x4063fd
lea eax, [esp + 0x14]
push eax
call edi
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageA]
push 0
push 0
push 0
lea eax, [esp + 0x20]
push eax
call esi
test eax, eax
jne 0x4063d4
push dword [0x5cd71c]
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov ecx, dword [esp + 0x33c]
mov eax, dword [esp + 0x1c]
pop edi
pop esi
xor ecx, esp
call fcn.00414177
mov esp, ebp
pop ebp
ret 0x10