Function at 0x140150240
Capabilities:
Query environment variable

Disassembly:
push rbp
push r12
push r13
push r14
push r15
mov eax, 0x50
call fcn.1402563f0
sub rsp, rax
lea rbp, [rsp + 0x40]
mov qword [rbp + 0x40], rbx
mov qword [rbp + 0x48], rsi
mov qword [rbp + 0x50], rdi
mov rax, qword [0x1403bb2d8]
xor rax, rbp
mov qword [rbp], rax
mov r13, rcx
lea rcx, str.OPENSSL_WIN32_UTF8
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x1401504eb
xor esi, esi
mov r12d, esi
mov ebx, esi
lea r14d, [rsi + 8]
call qword [sym.imp.KERNEL32.dll_GetACP]
mov edi, eax
cmp eax, 0xc42c
je 0x1401502ea
cmp eax, 0xc42d
je 0x1401502ea
cmp eax, 0xc42e
je 0x1401502ea
cmp eax, 0xc431
je 0x1401502ea
cmp eax, 0xc433
je 0x1401502ea
cmp eax, 0xc435
je 0x1401502ea
cmp eax, 0xdeaa
jb 0x1401502de
cmp eax, 0xdeb3
jbe 0x1401502ea
cmp eax, 0xfde8
je 0x1401502ea
cmp eax, 0x2a
jne 0x1401502ed
mov r14d, esi
or r9d, 0xffffffff
mov r8, r13
mov edx, r14d
mov ecx, eax
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
movsxd r15, eax
test eax, eax
jle 0x1401504e6
lea rcx, [r15 + r15 + 0x10]
movabs rdx, 0xffffffffffffff0
cmp rcx, 0x400
ja 0x140150359
lea rax, [rcx + 0xf]
cmp rax, rcx
ja 0x140150337
mov rax, rdx
and rax, 0xfffffffffffffff0
call fcn.1402563f0
sub rsp, rax
lea rsi, [rsp + 0x40]
test rsi, rsi
je 0x1401504e6
mov dword [rsi], 0xcccc
jmp 0x14015036c
call fcn.140253f70
mov rsi, rax
test rax, rax
je 0x140150370
mov dword [rax], 0xdddd
add rsi, 0x10
test rsi, rsi
je 0x1401504e6
or r9d, 0xffffffff
mov r8, r13
mov edx, r14d
mov ecx, edi
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jle 0x1401504bd
xor r8d, r8d
xor edx, edx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
test eax, eax
je 0x1401504bd
lea rcx, [rdi + rdi + 0x10]
cmp rcx, 0x400
ja 0x1401503f8
lea rax, [rcx + 0xf]
cmp rax, rcx
ja 0x1401503d6
movabs rax, 0xffffffffffffff0
and rax, 0xfffffffffffffff0
call fcn.1402563f0
sub rsp, rax
lea rbx, [rsp + 0x40]
test rbx, rbx
je 0x1401504bd
mov dword [rbx], 0xcccc
jmp 0x14015040b
call fcn.140253f70
mov rbx, rax
test rax, rax
je 0x14015040f
mov dword [rax], 0xdddd
add rbx, 0x10
test rbx, rbx
je 0x1401504bd
mov r8d, edi
mov rdx, rbx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, edi
jae 0x1401504bd
xor r13d, r13d
or r9d, 0xffffffff
mov r8, rbx
mov qword [rsp + 0x38], r13
mov qword [rsp + 0x30], r13
xor edx, edx
mov ecx, 0xfde9
mov dword [rsp + 0x28], r13d
mov qword [rsp + 0x20], r13
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
movsxd rdi, eax
test eax, eax
jle 0x1401504bd
lea r8d, [r13 + 0x46]
lea rdx, str.cryptogetenv.c
mov rcx, rdi
call fcn.1400b4570
mov r12, rax
test rax, rax
je 0x1401504bd
mov qword [rsp + 0x38], r13
mov qword [rsp + 0x30], r13
or r9d, 0xffffffff
mov r8, rbx
xor edx, edx
mov ecx, 0xfde9
mov dword [rsp + 0x28], edi
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x1401504bd
lea r8d, [r13 + 0x4c]
lea rdx, str.cryptogetenv.c
mov rcx, r12
call fcn.1400b4640
mov r12d, r13d
cmp dword [rsi - 0x10], 0xdddd
lea rcx, [rsi - 0x10]
jne 0x1401504cf
call fcn.1402540fc
test rbx, rbx
je 0x1401504e6
cmp dword [rbx - 0x10], 0xdddd
lea rcx, [rbx - 0x10]
jne 0x1401504e6
call fcn.1402540fc
mov rax, r12
jmp 0x140150500
call fcn.1401908e0
test eax, eax
je 0x1401504f8
xor eax, eax
jmp 0x140150500
mov rcx, r13
call fcn.1402596e8
mov rcx, qword [rbp]
xor rcx, rbp
call fcn.140254fb0
mov rbx, qword [rbp + 0x40]
mov rsi, qword [rbp + 0x48]
mov rdi, qword [rbp + 0x50]
lea rsp, [rbp + 0x10]
pop r15
pop r14
pop r13
pop r12
pop rbp
ret