Function at 0x100031944
Capabilities:
Identify system language via api

Disassembly:
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x3d0
mov rax, qword [0x100082138]
xor rax, rsp
mov qword [rsp + 0x3c0], rax
movzx edi, dx
mov rbx, rcx
mov qword [rsp + 0x48], rcx
mov qword [rsp + 0x40], 0
call fcn.100032190
mov rcx, rbx
mov dword [0x100083a10], eax
and al, 0x20
neg al
sbb r8d, r8d
xor edx, edx
and r8d, 0x1e
add r8d, 2
call qword [sym.imp.KERNEL32.dll_LoadLibraryExW]
test rax, rax
mov rsi, rax
mov qword [rsp + 0x38], rax
jne 0x1000319b6
xor eax, eax
jmp 0x100032165
mov eax, dword [0x100083a10]
mov r12d, 0
test al, 0x78
setne r12b
test al, 0x60
jne 0x100032158
lea r8, [0x10000a8a8]
mov edx, 1
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindResourceW]
test rax, rax
je 0x100032158
lea rax, [rsp + 0x40]
mov r9d, 0x104
xor r8d, r8d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x1b0]
mov rdx, rbx
xor ecx, ecx
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_SearchPathW]
test eax, eax
je 0x1000319af
mov rax, qword [rsp + 0x40]
test rax, rax
jne 0x100031a39
lea rax, [rsp + 0x1b0]
xor r14d, r14d
mov qword [rsp + 0x40], rax
jmp 0x100031a47
lea r14, [rsp + 0x1b0]
mov word [rax - 2], 0
test di, di
jne 0x100031fec
mov eax, dword [0x100083a10]
test al, 4
je 0x100031d7a
call qword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov word [rsp + 0x30], ax
lea rax, [0x100032498]
mov r9d, 0x18
mov r8d, 0x147
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
mov esi, 0x57
mov r13d, 0x8007007a
test rax, rax
lea ebx, [rsi - 2]
lea r15, [rbx - 0x56]
jne 0x100031c44
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
test eax, eax
je 0x10003215d
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031b0e
lea rdx, [rsp + 0x50]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031b0e
lea rdx, [rsp + 0x100]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
call qword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov word [rsp + 0x30], ax
lea rax, [0x100032498]
mov r9d, 0x18
mov r8d, 0x147
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
test rax, rax
jne 0x100031cdf
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
test eax, eax
je 0x10003215d
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031bac
lea rdx, [rsp + 0x50]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031bac
lea rdx, [rsp + 0x100]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
lea rax, [0x100032498]
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov r9d, 0x18
mov r8d, 0x147
mov word [rsp + 0x30], 0x409
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
test rax, rax
je 0x100031e6a
mov r8, qword [rax + 8]
xor eax, eax
mov rcx, r15
mov rdi, r8
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
ja 0x100031f2d
lea rdi, [rsp + 0x50]
xor r9d, r9d
mov rdx, rcx
sub r8, rdi
lea rax, [rsp + 0x50]
test rdx, rdx
je 0x100031f67
movzx edi, word [rax + r8]
test di, di
je 0x100031f67
mov word [rax], di
sub rdx, 1
add rax, 2
sub rbx, 1
jne 0x100031c17
jmp 0x100031f67
mov r9, qword [rax + 8]
xor eax, eax
mov rcx, r15
mov rdi, r9
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
mov r10, rcx
jbe 0x100031c69
mov word [rsp + 0x50], ax
jmp 0x100031cb5
mov rdi, rcx
lea rcx, [rsp + 0x50]
xor r8d, r8d
mov rdx, rbx
lea rax, [rsp + 0x50]
sub r9, rcx
test rdi, rdi
je 0x100031c9f
movzx ecx, word [rax + r9]
test cx, cx
je 0x100031c9f
mov word [rax], cx
sub rdi, 1
add rax, 2
sub rdx, 1
jne 0x100031c7f
test rdx, rdx
jne 0x100031cab
sub rax, 2
mov r8d, r13d
test r8d, r8d
mov word [rax], 0
jns 0x100031cbf
mov ecx, 0x7a
jmp 0x100031aaf
test r10d, r10d
je 0x100031ab5
lea rdx, [rsp + 0x100]
lea rcx, [rsp + 0x50]
call fcn.1000322ac
jmp 0x100031ab7
mov r9, qword [rax + 8]
xor eax, eax
mov rcx, r15
mov rdi, r9
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
mov r10, rcx
jbe 0x100031d04
mov word [rsp + 0x50], ax
jmp 0x100031d50
mov rdi, rcx
lea rcx, [rsp + 0x50]
xor r8d, r8d
mov rdx, rbx
lea rax, [rsp + 0x50]
sub r9, rcx
test rdi, rdi
je 0x100031d3a
movzx ecx, word [rax + r9]
test cx, cx
je 0x100031d3a
mov word [rax], cx
sub rdi, 1
add rax, 2
sub rdx, 1
jne 0x100031d1a
test rdx, rdx
jne 0x100031d46
sub rax, 2
mov r8d, r13d
test r8d, r8d
mov word [rax], 0
jns 0x100031d5a
mov ecx, 0x7a
jmp 0x100031b4d
test r10d, r10d
je 0x100031b53
lea rdx, [rsp + 0x100]
lea rcx, [rsp + 0x50]
call fcn.1000322ac
jmp 0x100031b55
test al, 3
je 0x100032158
call fcn.1000323a0
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov word [rsp + 0x30], ax
lea rax, [0x100032498]
mov r9d, 0x18
mov r8d, 0x147
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
mov esi, 0x57
mov r13d, 0x8007007a
test rax, rax
lea ebx, [rsi - 2]
lea r15, [rbx - 0x56]
jne 0x100031e77
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
test eax, eax
je 0x10003215d
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031e31
lea rdx, [rsp + 0x50]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100031e31
lea rdx, [rsp + 0x100]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
lea rax, [0x100032498]
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov r9d, 0x18
mov r8d, 0x147
mov word [rsp + 0x30], 0x409
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
test rax, rax
jne 0x100031f12
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x100031f9d
mov r9, qword [rax + 8]
xor eax, eax
mov rcx, r15
mov rdi, r9
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
mov r10, rcx
jbe 0x100031e9c
mov word [rsp + 0x50], ax
jmp 0x100031ee8
mov rdi, rcx
lea rcx, [rsp + 0x50]
xor r8d, r8d
mov rdx, rbx
lea rax, [rsp + 0x50]
sub r9, rcx
test rdi, rdi
je 0x100031ed2
movzx ecx, word [rax + r9]
test cx, cx
je 0x100031ed2
mov word [rax], cx
sub rdi, 1
add rax, 2
sub rdx, 1
jne 0x100031eb2
test rdx, rdx
jne 0x100031ede
sub rax, 2
mov r8d, r13d
test r8d, r8d
mov word [rax], 0
jns 0x100031ef2
mov ecx, 0x7a
jmp 0x100031dd2
test r10d, r10d
je 0x100031dd8
lea rdx, [rsp + 0x100]
lea rcx, [rsp + 0x50]
call fcn.1000322ac
jmp 0x100031dda
mov r8, qword [rax + 8]
xor eax, eax
mov rcx, r15
mov rdi, r8
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
jbe 0x100031f34
mov word [rsp + 0x50], ax
jmp 0x100031f7d
lea rdi, [rsp + 0x50]
xor r9d, r9d
mov rdx, rcx
sub r8, rdi
lea rax, [rsp + 0x50]
test rdx, rdx
je 0x100031f67
movzx edi, word [rax + r8]
test di, di
je 0x100031f67
mov word [rax], di
sub rdx, 1
add rax, 2
sub rbx, 1
jne 0x100031f47
test rbx, rbx
jne 0x100031f73
sub rax, 2
mov r9d, r13d
test r9d, r9d
mov word [rax], 0
jns 0x100031f87
mov ecx, 0x7a
jmp 0x100031e6c
test ecx, ecx
je 0x100031f9d
lea rdx, [rsp + 0x100]
lea rcx, [rsp + 0x50]
call fcn.1000322ac
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x10003215d
lea rdx, [rsp + 0x50]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x10003215d
mov r9d, r12d
xor edx, edx
mov rcx, r14
call fcn.100031870
test rax, rax
mov rdi, rax
jne 0x100032069
jmp 0x100032060
test byte [0x100083a10], 7
je 0x100032158
lea rax, [0x100032498]
lea rdx, [0x1000063e0]
lea rcx, [rsp + 0x30]
mov r9d, 0x18
mov r8d, 0x147
mov word [rsp + 0x30], di
mov qword [rsp + 0x20], rax
call sub.msvcrt.dll_bsearch
test rax, rax
jne 0x100032092
lea ecx, [rax + 0x57]
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
test eax, eax
je 0x100032158
mov r8, qword [rsp + 0x40]
test r8, r8
je 0x100032158
lea rdx, [rsp + 0x50]
mov r9d, r12d
mov rcx, r14
call fcn.100031870
mov rdi, rax
test rdi, rdi
je 0x10003215d
mov rbx, qword [rsp + 0x38]
mov rdx, rdi
mov rcx, rbx
call fcn.100031748
test eax, eax
je 0x100032131
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov rax, rdi
jmp 0x100032165
mov rdx, qword [rax + 8]
xor eax, eax
lea rcx, [rax - 1]
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
cmp rcx, 0x7ffffffe
jbe 0x1000320b5
mov word [rsp + 0x50], ax
jmp 0x100032108
lea r8, [rsp + 0x50]
xor r13d, r13d
mov rdi, rcx
mov ebx, 0x55
lea rax, [rsp + 0x50]
sub rdx, r8
test rdi, rdi
je 0x1000320ef
movzx r8d, word [rax + rdx]
test r8w, r8w
je 0x1000320ef
mov word [rax], r8w
sub rdi, 1
add rax, 2
sub rbx, 1
jne 0x1000320cd
test rbx, rbx
jne 0x1000320fe
sub rax, 2
mov r13d, 0x8007007a
test r13d, r13d
mov word [rax], 0
jns 0x100032112
mov ecx, 0x7a
jmp 0x10003202f
test ecx, ecx
je 0x100032035
lea rdx, [rsp + 0x100]
lea rcx, [rsp + 0x50]
call fcn.1000322ac
jmp 0x100032037
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
test r12d, r12d
jne 0x100032162
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov rbx, rax
jmp 0x100032162
mov rbx, rsi
jmp 0x100032162
mov rbx, qword [rsp + 0x38]
mov rax, rbx
mov rcx, qword [rsp + 0x3c0]
xor rcx, rsp
call fcn.10006b1f0
add rsp, 0x3d0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret