Function at 0x140012e00
Capabilities:
Query environment variable

Disassembly:
push rbx
push rbp
push rsi
push r12
push r14
push r15
sub rsp, 0x768
mov rax, qword [0x140374a58]
xor rax, rsp
mov qword [rsp + 0x750], rax
mov r12, qword [rsp + 0x7c0]
mov r14, rcx
lea rcx, str.MARIADB_PLUGIN_DIR
mov r15d, r9d
mov esi, r8d
mov rbp, rdx
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov dword [r14 + 0x78], 0
mov rdx, rbp
mov ecx, dword [str.00000]
mov rbx, rax
mov dword [r14 + 0x27f], ecx
movzx ecx, word [0x14005f988]
mov word [r14 + 0x283], cx
mov rcx, r14
mov byte [r14 + 0x7f], 0
call fcn.140012a00
test eax, eax
je 0x140012e86
xor eax, eax
jmp 0x1400130fa
lea rcx, [0x140375080]
mov qword [rsp + 0x760], rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
test esi, esi
js 0x140012eba
mov edx, esi
mov rcx, rbp
call fcn.140012940
test rax, rax
je 0x140012eba
lea rbx, str.it_is_already_loaded
jmp 0x140013093
mov r9, qword [r14 + 0x440]
test r9, r9
je 0x140012ece
mov r9, qword [r9]
test r9, r9
jne 0x140012edc
test rbx, rbx
lea r9, str.C:_Program_Files__x86__MySQL_C:_Program_Files_MariaDB_10.4_lib_plugin
cmovne r9, rbx
lea rax, str..dll
mov edx, 0x200
mov qword [rsp + 0x28], rax
lea r8, str._s__s_s
lea rcx, [rsp + 0x140]
mov qword [rsp + 0x20], rbp
call fcn.140009bc0
lea rdx, str.__________.___
mov rcx, rbp
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strpbrk]
test rax, rax
je 0x140012f27
lea rbx, str.invalid_plugin_name
jmp 0x140013093
xor r8d, r8d
lea rcx, [rsp + 0x140]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov rdi, rax
test rax, rax
jne 0x140013003
mov byte [rsp + 0x40], al
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov qword [rsp + 0x30], rdi
xor edx, edx
mov r8d, eax
mov dword [rsp + 0x28], 0xff
lea rax, [rsp + 0x40]
mov ecx, 0x1000
mov r9d, 0x400
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
lea rcx, [rsp + 0x40]
mov rax, 0xffffffffffffffff
nop dword [rax]
inc rax
cmp byte [rcx + rax], 0
jne 0x140012f90
test rax, rax
je 0x140012fcb
nop
movzx ecx, byte [rsp + rax + 0x3f]
cmp cl, 0xa
je 0x140012faf
cmp cl, 0xd
jne 0x140012fb5
sub rax, 1
jne 0x140012fa0
test rax, rax
je 0x140012fcb
cmp rax, 0xff
jae 0x14001311b
mov byte [rsp + rax + 0x40], 0
lea rax, [rsp + 0x140]
mov edx, 0x400
lea r9, [rsp + 0x40]
mov qword [rsp + 0x20], rax
lea r8, str._s_Library_path_is__s
lea rcx, [rsp + 0x350]
call fcn.140009bc0
lea rbx, [rsp + 0x350]
jmp 0x140013093
lea rdx, str._mysql_client_plugin_declaration_
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, rax
test rax, rax
jne 0x14001302d
mov rcx, rdi
lea rbx, str.not_a_plugin
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x14001308a
test esi, esi
js 0x14001303e
cmp esi, dword [rax]
je 0x14001303e
lea rbx, str.type_mismatch
jmp 0x14001308a
mov r8, qword [rbx + 8]
mov rax, rbp
sub r8, rbp
nop dword [rax + rax]
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x140013063
inc rax
test ecx, ecx
jne 0x140013050
test edx, edx
je 0x140013070
lea rbx, str.name_mismatch
jmp 0x14001308a
test esi, esi
jns 0x1400130c9
mov edx, dword [rbx]
mov rcx, rbp
call fcn.140012940
test rax, rax
je 0x1400130c9
lea rbx, str.it_is_already_loaded
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
lea rcx, [0x140375080]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov r9, qword [str.Plugin__s_could_not_be_loaded:__s]
mov edx, 0x80b
mov r8, qword [str.HY000]
mov rcx, r14
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rbp
call fcn.1400046e0
xor eax, eax
jmp 0x1400130f2
mov r9d, r15d
mov qword [rsp + 0x20], r12
mov r8, rdi
mov rdx, rbx
mov rcx, r14
call fcn.1400127b0
lea rcx, [0x140375080]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rax, rbx
mov rdi, qword [rsp + 0x760]
mov rcx, qword [rsp + 0x750]
xor rcx, rsp
call fcn.14005bc60
add rsp, 0x768
pop r15
pop r14
pop r12
pop rsi
pop rbp
pop rbx
ret
call fcn.14005c000
int3