Function at 0x40e30c
Capabilities:
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc10
mov dl, byte [0x458ff4]
push ebx
push esi
push edi
push 0x3f
xor eax, eax
pop ecx
lea edi, [ebp - 0x507]
mov byte [ebp - 0x508], dl
push 0x3f
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
pop ecx
xor eax, eax
lea edi, [ebp - 0x707]
mov byte [ebp - 0x708], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push str.StartDatabase
lea eax, [ebp - 0x408]
xor edi, edi
push str.brodbcn.c
push eax
mov dword [ebp - 4], edi
call fcn.0040f00a
add esp, 0xc
cmp word [0x45ccf0], di
jle 0x40e37b
mov ecx, 0x80
jmp 0x40e6bf
and byte [0x45ccf2], 0
push 0x45cce0
mov dword [0x45ccec], edi
call sub.ODBC32.dll_SQLAllocEnv
test ax, ax
je 0x40e3d4
lea eax, [ebp - 0x408]
push edi
push eax
lea eax, [ebp - 0x208]
push eax
call fcn.0040e98e
mov ebx, 0x80
mov esi, eax
mov ecx, ebx
lea edi, [ebp - 0x208]
add esp, 0xc
rep movsd dword es:[edi], dword [esi]
cmp word [ebp - 0x208], 0
mov ecx, ebx
je 0x40e6bf
jmp 0x40e788
push 0x45cce4
push dword [0x45cce0]
call sub.ODBC32.dll_SQLAllocConnect
movsx eax, ax
cmp eax, 0xfffffffe
je 0x40e750
cmp eax, 0xffffffff
je 0x40e73d
push 1
cmp eax, edi
pop esi
je 0x40e414
cmp eax, esi
je 0x40e414
lea eax, [ebp - 0x408]
push edi
push eax
lea eax, [ebp - 0x208]
jmp 0x40e3a5
mov edi, 0x44e7b8
lea eax, [ebp - 0x508]
push edi
push eax
call fcn.0040afd0
pop ecx
lea eax, [ebp - 0x608]
pop ecx
mov ebx, str.Connection
push str.RFU30
push 0x100
push eax
push 0x458ff4
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x608]
push eax
call fcn.0040b0c0
test eax, eax
pop ecx
je 0x40e471
lea eax, [ebp - 0x508]
push eax
lea eax, [ebp - 0x608]
push eax
call fcn.00410c93
pop ecx
pop ecx
push str.DATABASE
call fcn.0040d3de
test eax, eax
pop ecx
je 0x40e497
cmp byte [eax], 0
je 0x40e497
push eax
lea eax, [ebp - 0x508]
push eax
call fcn.0040afd0
pop ecx
mov dword [ebp - 4], esi
pop ecx
push str.CF30_DATABASE
call fcn.0040d3de
test eax, eax
pop ecx
je 0x40e4bd
cmp byte [eax], 0
je 0x40e4bd
push eax
lea eax, [ebp - 0x508]
push eax
call fcn.0040afd0
pop ecx
mov dword [ebp - 4], esi
pop ecx
call dword [sym.imp.USER32.dll_GetDesktopWindow]
lea ecx, [ebp - 6]
push esi
push ecx
mov esi, 0xff
lea ecx, [ebp - 0x708]
push esi
push ecx
lea ecx, [ebp - 0x508]
push 0xfffffffffffffffd
push ecx
push eax
push dword [0x45cce4]
call sub.ODBC32.dll_SQLDriverConnect
movsx eax, ax
cmp eax, 0xfffffffe
je 0x40e729
cmp eax, 0xffffffff
je 0x40e715
test eax, eax
jl 0x40e701
cmp eax, 1
jg 0x40e701
lea eax, [ebp - 0x608]
push eax
lea eax, [ebp - 0x708]
push eax
call fcn.004109ec
pop ecx
cmp eax, esi
pop ecx
jle 0x40e54a
lea eax, [ebp - 0x406]
push str.8888___Connect_String_must_be_less_than_256_characters
push eax
mov word [ebp - 0x408], 0x22b8
call fcn.0040afd0
pop ecx
pop ecx
jmp 0x40e371
cmp dword [ebp - 4], 0
jne 0x40e564
lea eax, [ebp - 0x608]
push str.RFU30
push eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
push 0x45cce8
push dword [0x45cce4]
call fcn.0040ec3d
movsx eax, ax
pop ecx
cmp eax, 0xfffffffe
pop ecx
je 0x40e6e9
cmp eax, 0xffffffff
je 0x40e6d1
test eax, eax
je 0x40e5ac
cmp eax, 1
je 0x40e5ac
push dword [0x45cce8]
lea eax, [ebp - 0x408]
push eax
lea eax, [ebp - 0x208]
jmp 0x40e3a5
inc word [0x45ccf0]
lea eax, [ebp - 0x208]
push eax
call fcn.0040e830
pop ecx
mov ebx, 0x80
mov ecx, ebx
mov esi, eax
lea edi, [ebp - 0x208]
rep movsd dword es:[edi], dword [esi]
cmp word [ebp - 0x208], 0
jne 0x40e786
lea eax, [ebp - 0x810]
push 0x45ccf2
push eax
lea eax, [ebp - 0xa10]
push eax
call fcn.004106f2
mov ecx, ebx
mov esi, eax
lea edi, [ebp - 0x208]
add esp, 0xc
rep movsd dword es:[edi], dword [esi]
cmp word [ebp - 0x208], 0
jne 0x40e786
lea eax, [ebp - 0x810]
push eax
lea eax, [ebp - 0xa10]
push eax
call fcn.004107eb
pop ecx
mov esi, eax
pop ecx
lea edi, [ebp - 0x208]
mov ecx, ebx
rep movsd dword es:[edi], dword [esi]
cmp word [ebp - 0x208], 0
jne 0x40e786
lea eax, [ebp - 0x810]
mov esi, 0x45ccf2
push eax
push esi
call fcn.0040afd0
mov edi, 0x44e74c
push edi
push esi
call fcn.0040c220
add esp, 0x10
test eax, eax
jne 0x40e681
push 0x44e748
push esi
call fcn.0040c220
pop ecx
test eax, eax
pop ecx
jne 0x40e681
and dword [0x45ccec], eax
jmp 0x40e68b
mov dword [0x45ccec], 1
push 0x44e744
push esi
call fcn.0040c220
pop ecx
test eax, eax
pop ecx
jne 0x40e6a9
push edi
push esi
call fcn.0040c220
pop ecx
test eax, eax
pop ecx
je 0x40e6bd
push 0
push 1
push 0x4e5
push dword [0x45cce4]
call sub.ODBC32.dll_SQLSetConnectAttr
mov ecx, ebx
lea esi, [ebp - 0x408]
mov eax, dword [ebp + 8]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
pop edi
pop esi
pop ebx
leave
ret
push dword [0x45cce8]
lea eax, [ebp - 0x408]
push eax
lea eax, [ebp - 0xa10]
jmp 0x40e3a5
push dword [0x45cce8]
lea eax, [ebp - 0x408]
push eax
lea eax, [ebp - 0xc10]
jmp 0x40e3a5
lea eax, [ebp - 0x408]
push 0
push eax
lea eax, [ebp - 0xc10]
jmp 0x40e3a5
lea eax, [ebp - 0x408]
push 0
push eax
lea eax, [ebp - 0xa10]
jmp 0x40e3a5
lea eax, [ebp - 0x408]
push 0
push eax
lea eax, [ebp - 0x208]
jmp 0x40e3a5
lea eax, [ebp - 0x408]
push edi
push eax
lea eax, [ebp - 0xc10]
jmp 0x40e3a5
lea eax, [ebp - 0x408]
push edi
push eax
lea eax, [ebp - 0xa10]
push eax
call fcn.0040e98e
mov ebx, 0x80
mov esi, eax
mov ecx, ebx
lea edi, [ebp - 0x208]
add esp, 0xc
rep movsd dword es:[edi], dword [esi]
cmp word [ebp - 0x208], 0
je 0x40e6bd
mov ecx, ebx
lea esi, [ebp - 0x208]
jmp 0x40e6c5