Function at 0x423860
Capabilities:
Query environment variable
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push edi
mov edi, dword [ebp + 0xc]
push str.psql_9.5
mov dword [ebp - 4], 0
push dword [edi]
call fcn.00425380
mov ebx, dword [ebp + 8]
add esp, 8
cmp ebx, 1
jle 0x423984
mov ecx, dword [edi + 4]
mov edx, 0x44b2f0
mov eax, ecx
mov bl, byte [eax]
cmp bl, byte [edx]
jne 0x4238b7
test bl, bl
je 0x4238b3
mov bl, byte [eax + 1]
cmp bl, byte [edx + 1]
jne 0x4238b7
add eax, 2
add edx, 2
test bl, bl
jne 0x423897
xor eax, eax
jmp 0x4238bc
sbb eax, eax
or eax, 1
test eax, eax
je 0x42396f
cmp dword [ebp + 8], 2
jne 0x4238fa
mov edx, str.__help
mov eax, ecx
mov bl, byte [eax]
cmp bl, byte [edx]
jne 0x4238f1
test bl, bl
je 0x4238ed
mov bl, byte [eax + 1]
cmp bl, byte [edx + 1]
jne 0x4238f1
add eax, 2
add edx, 2
test bl, bl
jne 0x4238d1
xor eax, eax
jmp 0x4238f6
sbb eax, eax
or eax, 1
test eax, eax
je 0x42396f
mov edx, str.__version
mov eax, ecx
mov bl, byte [eax]
cmp bl, byte [edx]
jne 0x423921
test bl, bl
je 0x42391d
mov bl, byte [eax + 1]
cmp bl, byte [edx + 1]
jne 0x423921
add eax, 2
add edx, 2
test bl, bl
jne 0x423901
xor eax, eax
jmp 0x423926
sbb eax, eax
or eax, 1
test eax, eax
je 0x423959
mov eax, 0x44b308
nop
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x423950
test dl, dl
je 0x42394c
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x423950
add ecx, 2
add eax, 2
test dl, dl
jne 0x423930
xor eax, eax
jmp 0x423955
sbb eax, eax
or eax, 1
test eax, eax
jne 0x423981
push str.psql__PostgreSQL__9.5.5
call dword [sym.imp.MSVCR120.dll_puts]
add esp, 4
push 0
call dword [sym.imp.MSVCR120.dll_exit]
push 0
call fcn.00412890
add esp, 4
push 0
call dword [sym.imp.MSVCR120.dll_exit]
mov ebx, dword [ebp + 8]
push esi
mov esi, dword [sym.imp.MSVCR120.dll___iob_func]
push 0
push 4
push 0
call esi
add eax, 0x40
push eax
call dword [sym.imp.MSVCR120.dll_setvbuf]
push dword [edi]
call fcn.00428250
mov dword [0x456398], eax
mov dword [0x456300], 0
call fcn.004182b0
call sub.LIBPQ.dll_Ordinal_73
mov dword [0x456304], eax
call esi
add eax, 0x20
mov byte [0x45630c], 0
mov dword [0x456308], eax
mov dword [0x456310], 0
call esi
push 0x456314
mov dword [0x45638c], eax
mov byte [0x456390], 0
mov dword [0x456314], 2
mov dword [0x45631a], 0x10001
mov dword [0x456320], 0
mov word [0x456325], 0x101
mov byte [0x456327], 1
mov dword [0x456354], 0
mov dword [0x456358], 0
mov dword [0x45635c], 0
call fcn.00418370
mov edi, dword [sym.imp.MSVCR120.dll_getenv]
push str.COLUMNS
call edi
add esp, 0x1c
test eax, eax
je 0x423a6d
push str.COLUMNS
call edi
push eax
call dword [sym.imp.MSVCR120.dll_atoi]
add esp, 8
mov dword [0x45634c], eax
jmp 0x423a77
mov dword [0x45634c], 0
call esi
mov esi, dword [sym.imp.MSVCR120.dll__fileno]
push eax
call esi
mov edi, dword [sym.imp.MSVCR120.dll__isatty]
push eax
call edi
add esp, 8
test eax, eax
je 0x423aaf
call dword [sym.imp.MSVCR120.dll___iob_func]
add eax, 0x20
push eax
call esi
push eax
call edi
add esp, 8
mov byte [0x456384], 0
test eax, eax
jne 0x423ab6
mov byte [0x456384], 1
mov dword [0x456388], 0
call fcn.00423710
push str.PostgreSQL_9.5.5__compiled_by_Visual_C_build_1800__32_bit
push str.VERSION
push dword [0x4563b8]
call fcn.00424ab0
push str.AUTOCOMMIT
push dword [0x4563b8]
call fcn.00424c60
push str.default
push str.VERBOSITY
push dword [0x4563b8]
call fcn.00424ab0
push str.___R_
push str.PROMPT1
push dword [0x4563b8]
call fcn.00424ab0
push str.___R_
push str.PROMPT2
push dword [0x4563b8]
call fcn.00424ab0
push 0x44b388
push str.PROMPT3
push dword [0x4563b8]
call fcn.00424ab0
add esp, 0x44
lea eax, [ebp - 0x2c]
push eax
push dword [ebp + 0xc]
push ebx
call fcn.00422eb0
mov ebx, dword [ebp - 0x18]
add esp, 0xc
test ebx, ebx
jne 0x423b6e
cmp byte [0x456384], bl
je 0x423b6e
mov ebx, 4
mov dword [ebp + 8], 0
jmp 0x423b74
mov eax, dword [ebp - 0x14]
mov dword [ebp + 8], eax
cmp byte [ebp - 0xe], 0
je 0x423bb1
cmp ebx, 4
je 0x423bb1
test ebx, ebx
jne 0x423bb1
push dword [0x456398]
push str._s:__1_can_only_be_used_in_non_interactive_mode_n
call sub.libintl_8.dll_libintl_gettext
add esp, 4
push eax
call dword [sym.imp.MSVCR120.dll___iob_func]
add eax, 0x40
push eax
call fcn.00426490
add esp, 0xc
push 1
call dword [sym.imp.MSVCR120.dll_exit]
cmp dword [0x456330], 0
jne 0x423bdc
cmp byte [0x456334], 0
jne 0x423bdc
push 0x43b300
call fcn.00424d80
add esp, 4
mov dword [0x456330], eax
mov byte [0x456334], 0
cmp dword [0x456338], 0
jne 0x423c07
cmp byte [0x45633c], 0
jne 0x423c07
push 0x42d94c
call fcn.00424d80
add esp, 4
mov dword [0x456338], eax
mov byte [0x45633c], 0
mov eax, dword [ebp - 0x20]
test eax, eax
jne 0x423c20
push str.Password:
call sub.libintl_8.dll_libintl_gettext
push eax
call fcn.00424d80
jmp 0x423c34
push eax
push str.Password_for_user__s:
call sub.libintl_8.dll_libintl_gettext
add esp, 4
push eax
call fcn.00425060
add esp, 8
mov dword [ebp - 8], eax
cmp dword [0x456388], 2
jne 0x423c53
push 0
push 0x64
push eax
call fcn.00428800
add esp, 0xc
mov dword [ebp - 4], eax
push 0x20
call fcn.00424dd0
push 0x20
mov esi, eax
call fcn.00424dd0
mov edi, eax
mov dword [esi], str.host
mov eax, dword [ebp - 0x28]
add esp, 8
mov dword [edi], eax
mov eax, dword [ebp - 0x24]
mov dword [esi + 4], str.port
mov dword [edi + 4], eax
mov eax, dword [ebp - 0x20]
mov dword [esi + 8], str.user
mov dword [edi + 8], eax
mov eax, dword [ebp - 4]
mov dword [esi + 0xc], str.password
mov dword [edi + 0xc], eax
mov eax, dword [ebp - 0x2c]
mov dword [esi + 0x10], str.dbname
cmp ebx, 2
jne 0x423cb2
test eax, eax
jne 0x423cb2
mov eax, str.postgres
mov dword [edi + 0x10], eax
mov dword [esi + 0x14], str.fallback_application_name
mov eax, dword [0x456398]
mov dword [edi + 0x14], eax
mov dword [esi + 0x18], str.client_encoding
cmp byte [0x456384], 0
jne 0x423ced
push str.PGCLIENTENCODING
call dword [sym.imp.MSVCR120.dll_getenv]
add esp, 4
test eax, eax
jne 0x423ced
mov eax, str.auto
jmp 0x423cef
xor eax, eax
push 1
mov dword [edi + 0x18], eax
push edi
mov dword [esi + 0x1c], 0
push esi
mov dword [edi + 0x1c], 0
call sub.LIBPQ.dll_Ordinal_156
push esi
mov esi, dword [sym.imp.MSVCR120.dll_free]
mov dword [0x456300], eax
call esi
push edi
call esi
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_14
add esp, 0x18
cmp eax, 1
jne 0x423d6e
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_140
add esp, 4
test eax, eax
mov eax, dword [ebp - 4]
je 0x423d71
test eax, eax
jne 0x423d71
cmp dword [0x456388], 1
je 0x423d71
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_4
push 0
push 0x64
push dword [ebp - 8]
call fcn.00428800
add esp, 0x10
jmp 0x423c50
mov eax, dword [ebp - 4]
push eax
call esi
push dword [ebp - 8]
call esi
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_14
add esp, 0xc
cmp eax, 1
jne 0x423dcb
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_15
add esp, 4
push eax
push dword [0x456398]
push str._s:__s
call dword [sym.imp.MSVCR120.dll___iob_func]
add eax, 0x40
push eax
call fcn.00426490
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_4
add esp, 0x14
push 2
call dword [sym.imp.MSVCR120.dll_exit]
call fcn.00409050
push 0
push 0x409040
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_20
add esp, 0xc
call fcn.00403f30
cmp ebx, 2
jne 0x423e2a
cmp byte [ebp - 0xf], 0
jne 0x423e02
mov eax, dword [ebp + 0xc]
push dword [eax]
call fcn.00423520
add esp, 4
push 0
push 0
call fcn.0040e0a0
push dword [0x456300]
movsx esi, al
call sub.LIBPQ.dll_Ordinal_4
xor eax, eax
add esp, 0xc
test esi, esi
sete al
push eax
call dword [sym.imp.MSVCR120.dll_exit]
mov esi, dword [ebp - 0x1c]
test esi, esi
je 0x423e8a
push 0x42d68c
push esi
call dword [sym.imp.MSVCR120.dll_fopen]
add esp, 8
mov dword [0x4563b4], eax
test eax, eax
jne 0x423e8a
call dword [sym.imp.MSVCR120.dll__errno]
push dword [eax]
call dword [sym.imp.MSVCR120.dll_strerror]
add esp, 4
push eax
push esi
push dword [0x456398]
push str._s:_could_not_open_log_file___s_:__s_n
call sub.libintl_8.dll_libintl_gettext
add esp, 4
push eax
call dword [sym.imp.MSVCR120.dll___iob_func]
add eax, 0x40
push eax
call fcn.00426490
add esp, 0x14
push 1
call dword [sym.imp.MSVCR120.dll_exit]
cmp ebx, 4
jne 0x423eb8
cmp byte [ebp - 0xf], 0
jne 0x423ea2
mov eax, dword [ebp + 0xc]
push dword [eax]
call fcn.00423520
add esp, 4
mov edi, dword [ebp + 8]
push 0
push dword [ebp - 0xe]
push edi
call fcn.004031d0
add esp, 0xc
jmp 0x423f91
cmp ebx, 1
jne 0x423f0f
cmp dword [0x4563c8], 3
mov edi, dword [ebp + 8]
jne 0x423ed3
push edi
call dword [sym.imp.MSVCR120.dll_puts]
add esp, 4
call fcn.00414d90
mov edx, edi
mov esi, eax
lea eax, [edx + 1]
nop
mov cl, byte [edx]
inc edx
test cl, cl
jne 0x423ee0
sub edx, eax
push edx
push edi
push esi
call fcn.00414e20
push 0
push esi
call fcn.004030e0
xor ebx, ebx
cmp eax, 5
push esi
sete bl
call fcn.00414dd0
add esp, 0x18
jmp 0x423f93
cmp ebx, 3
jne 0x423f3b
mov edi, dword [ebp + 8]
cmp dword [0x4563c8], ebx
jne 0x423f29
push edi
call dword [sym.imp.MSVCR120.dll_puts]
add esp, 4
push edi
call fcn.00409440
xor ebx, ebx
add esp, 4
test al, al
sete bl
jmp 0x423f93
cmp byte [ebp - 0xf], 0
jne 0x423f4e
mov eax, dword [ebp + 0xc]
push dword [eax]
call fcn.00423520
add esp, 4
push 1
call fcn.00403de0
add esp, 4
cmp byte [0x4563be], 0
jne 0x423f74
push str.Type__help__for_help._n_n
call sub.libintl_8.dll_libintl_gettext
push eax
call fcn.004264b0
add esp, 8
xor eax, eax
cmp byte [ebp - 0x10], al
sete al
push eax
call fcn.00413de0
call dword [sym.imp.MSVCR120.dll___iob_func]
push eax
call fcn.00414430
add esp, 8
mov ebx, eax
mov eax, dword [0x4563b4]
pop esi
test eax, eax
je 0x423fa7
push eax
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 4
push dword [0x456300]
call sub.LIBPQ.dll_Ordinal_4
push 0
call fcn.00408f20
add esp, 8
mov eax, ebx
pop edi
pop ebx
mov esp, ebp
pop ebp
ret