Function at 0x40ca60
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x9c
movdqu xmm0, xmmword [0x456314]
mov eax, dword [0x45635c]
push ebx
movdqu xmmword [ebp - 0x9c], xmm0
mov dword [ebp - 0x54], eax
lea eax, [ebp - 0xc]
movdqu xmm0, xmmword [0x456324]
push esi
push eax
movdqu xmmword [ebp - 0x8c], xmm0
mov esi, 3
mov byte [ebp - 0x89], 0
movdqu xmm0, xmmword [0x456334]
movdqu xmmword [ebp - 0x7c], xmm0
movdqu xmm0, xmmword [0x456344]
movdqu xmmword [ebp - 0x6c], xmm0
movq xmm0, qword [0x456354]
movq qword [ebp - 0x5c], xmm0
call sub.LIBPQ.dll_Ordinal_69
add esp, 4
lea eax, [ebp - 0xc]
cmp dword [0x456394], 0x138e4
jl 0x40cb6e
push str.SELECT_r.rolname__r.rolsuper__r.rolinherit__n__r.rolcreaterole__r.rolcreatedb__r.rolcanlogin__n__r.rolconnlimit__r.rolvaliduntil__n__ARRAY_SELECT_b.rolname_n________FROM_pg_catalog.pg_auth_members_m_n________JOIN_pg_catalog.pg_roles_b_ON__m.roleid__b.oid__n________WHERE_m.member__r.oid__as_memberof
push eax
call sub.LIBPQ.dll_Ordinal_90
add esp, 8
cmp byte [ebp + 0xc], 0
je 0x40cb1b
cmp dword [0x456394], 0x13948
jl 0x40cb1b
lea eax, [ebp - 0xc]
push str._n__pg_catalog.shobj_description_r.oid__pg_authid__AS_description
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
mov esi, 4
cmp dword [0x456394], 0x15ff4
jl 0x40cb38
lea eax, [ebp - 0xc]
push str._n__r.rolreplication
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
cmp dword [0x456394], 0x16184
jl 0x40cb55
lea eax, [ebp - 0xc]
push str._n__r.rolbypassrls
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push str._nFROM_pg_catalog.pg_roles_r_n
push eax
call sub.LIBPQ.dll_Ordinal_75
push 0
push 0
push str.r.rolname
jmp 0x40cb82
push str.SELECT_u.usename_AS_rolname__n__u.usesuper_AS_rolsuper__n__true_AS_rolinherit__false_AS_rolcreaterole__n__u.usecreatedb_AS_rolcreatedb__true_AS_rolcanlogin__n___1_AS_rolconnlimit___u.valuntil_as_rolvaliduntil__n__ARRAY_SELECT_g.groname_FROM_pg_catalog.pg_group_g_WHERE_u.usesysid__ANY_g.grolist___as_memberof_nFROM_pg_catalog.pg_user_u_n
push eax
call sub.LIBPQ.dll_Ordinal_90
push 0
push 0
push str.u.usename
push 0
push 0
push 0
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
push dword [0x456300]
call fcn.00401fe0
add esp, 0x2c
lea eax, [ebp - 0xc]
push str.ORDER_BY_1_
push eax
call sub.LIBPQ.dll_Ordinal_75
push dword [ebp - 0xc]
call fcn.00409100
mov ebx, eax
add esp, 0xc
mov dword [ebp - 0x18], ebx
test ebx, ebx
jne 0x40cbc7
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_34
mov edi, eax
mov dword [ebp - 0x10], edi
lea ecx, [edi*4 + 4]
push ecx
call fcn.00424df0
add esp, 8
mov dword [ebp - 0x14], eax
push edi
push esi
push str.List_of_roles
call sub.libintl_8.dll_libintl_gettext
add esp, 4
push eax
lea eax, [ebp - 0x9c]
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.00417bc0
push 0x6c
push 1
lea eax, [ebp - 0x50]
push str.Role_name
push eax
call fcn.00417c50
push 0x6c
push 1
lea eax, [ebp - 0x50]
push str.Attributes
push eax
call fcn.00417c50
push 0x6c
push 1
lea eax, [ebp - 0x50]
push str.Member_of
push eax
call fcn.00417c50
add esp, 0x44
cmp byte [ebp + 0xc], 0
je 0x40cc66
cmp dword [0x456394], 0x13948
jl 0x40cc66
push 0x6c
push 1
lea eax, [ebp - 0x50]
push str.Description
push eax
call fcn.00417c50
add esp, 0x10
xor edi, edi
cmp dword [ebp - 0x10], edi
jle 0x40d11f
push 0
push 0
push 0
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.00417cd0
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_70
push 1
push edi
push ebx
mov esi, 0x42dc38
call sub.LIBPQ.dll_Ordinal_45
add esp, 0x20
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40ccc5
test cl, cl
je 0x40ccc1
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40ccc5
add eax, 2
add esi, 2
test cl, cl
jne 0x40cca5
xor eax, eax
jmp 0x40ccca
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40cd01
push str.Superuser
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40ccf4
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push 2
push edi
push ebx
mov esi, 0x42dc38
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40cd32
test cl, cl
je 0x40cd2e
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40cd32
add eax, 2
add esi, 2
test cl, cl
jne 0x40cd12
xor eax, eax
jmp 0x40cd37
sbb eax, eax
or eax, 1
test eax, eax
je 0x40cd6e
push str.No_inheritance
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40cd61
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push 3
push edi
push ebx
mov esi, 0x42dc38
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
nop
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40cda0
test cl, cl
je 0x40cd9c
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40cda0
add eax, 2
add esi, 2
test cl, cl
jne 0x40cd80
xor eax, eax
jmp 0x40cda5
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40cddc
push str.Create_role
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40cdcf
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push 4
push edi
push ebx
mov esi, 0x42dc38
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
lea ecx, [ecx]
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40ce10
test cl, cl
je 0x40ce0c
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40ce10
add eax, 2
add esi, 2
test cl, cl
jne 0x40cdf0
xor eax, eax
jmp 0x40ce15
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40ce4c
push str.Create_DB
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40ce3f
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push 5
push edi
push ebx
mov esi, 0x42dc38
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
lea ecx, [ecx]
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40ce80
test cl, cl
je 0x40ce7c
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40ce80
add eax, 2
add esi, 2
test cl, cl
jne 0x40ce60
xor eax, eax
jmp 0x40ce85
sbb eax, eax
or eax, 1
test eax, eax
je 0x40cebc
push str.Cannot_login
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40ceaf
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
cmp dword [0x456394], 0x15ff4
jl 0x40cf3f
xor eax, eax
mov esi, 0x42dc38
cmp byte [ebp + 0xc], al
setne al
add eax, 9
push eax
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40cf03
test cl, cl
je 0x40ceff
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40cf03
add eax, 2
add esi, 2
test cl, cl
jne 0x40cee3
xor eax, eax
jmp 0x40cf08
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40cf3f
push str.Replication
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40cf32
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
cmp dword [0x456394], 0x16184
jl 0x40cfc2
xor eax, eax
mov esi, 0x42dc38
cmp byte [ebp + 0xc], al
setne al
add eax, 0xa
push eax
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40cf86
test cl, cl
je 0x40cf82
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40cf86
add eax, 2
add esi, 2
test cl, cl
jne 0x40cf66
xor eax, eax
jmp 0x40cf8b
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40cfc2
push str.Bypass_RLS
call sub.libintl_8.dll_libintl_gettext
add esp, 4
mov esi, eax
cmp dword [ebp - 8], 0
jbe 0x40cfb5
lea eax, [ebp - 0xc]
push 0x434b68
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
lea eax, [ebp - 0xc]
push esi
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push 6
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
push eax
call dword [sym.imp.MSVCR120.dll_atoi]
mov esi, eax
add esp, 0x10
test esi, esi
js 0x40d02a
cmp dword [ebp - 8], 0
jbe 0x40cfef
lea eax, [ebp - 0xc]
push 0xa
push eax
call sub.LIBPQ.dll_Ordinal_68
add esp, 8
test esi, esi
jne 0x40d009
push str.No_connections
call sub.libintl_8.dll_libintl_gettext
push eax
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_75
jmp 0x40d027
push esi
push esi
push str._d_connections
push str._d_connection
call sub.libintl_8.dll_libintl_ngettext
add esp, 0xc
push eax
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_91
add esp, 0xc
push 7
push edi
push ebx
mov esi, 0x42b69a
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
jmp 0x40d040
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x40d060
test cl, cl
je 0x40d05c
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x40d060
add eax, 2
add esi, 2
test cl, cl
jne 0x40d040
xor eax, eax
jmp 0x40d065
sbb eax, eax
or eax, 1
test eax, eax
je 0x40d0aa
cmp dword [ebp - 8], 0
jbe 0x40d080
lea eax, [ebp - 0xc]
push 0x42d94c
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 8
push str.Password_valid_until
call sub.libintl_8.dll_libintl_gettext
push eax
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_75
push 7
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
push eax
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_75
add esp, 0x20
push dword [ebp - 0xc]
call fcn.00424d80
mov ecx, dword [ebp - 0x14]
push 0
push 0
push eax
mov dword [ecx + edi*4], eax
lea eax, [ebp - 0x50]
push eax
call fcn.00417cd0
add esp, 0x14
push 0
push 0
push 8
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.00417cd0
add esp, 0x10
cmp byte [ebp + 0xc], 0
je 0x40d115
cmp dword [0x456394], 0x13948
jl 0x40d115
push 0
push 0
push 9
push edi
push ebx
call sub.LIBPQ.dll_Ordinal_45
add esp, 0xc
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.00417cd0
add esp, 0x10
inc edi
cmp edi, dword [ebp - 0x10]
jl 0x40cc71
lea eax, [ebp - 0xc]
push eax
call sub.LIBPQ.dll_Ordinal_67
push dword [0x4563b4]
lea eax, [ebp - 0x50]
push 0
push dword [0x456308]
push eax
call fcn.00417ee0
lea eax, [ebp - 0x50]
push eax
call fcn.00417e10
mov edi, dword [sym.imp.MSVCR120.dll_free]
xor esi, esi
add esp, 0x18
cmp dword [ebp - 0x10], esi
jle 0x40d173
mov ebx, dword [ebp - 0x10]
jmp 0x40d160
mov eax, dword [ebp - 0x14]
push dword [eax + esi*4]
call edi
inc esi
add esp, 4
cmp esi, ebx
jl 0x40d160
mov ebx, dword [ebp - 0x18]
push dword [ebp - 0x14]
call edi
push ebx
call sub.LIBPQ.dll_Ordinal_48
add esp, 8
mov al, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret