Function at 0x1400212d0
Capabilities:
Get geographical location

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x90], rbx
mov rax, qword [0x14003e010]
xor rax, rsp
mov qword [rsp + 0x38], rax
mov r14, rdx
mov r12, rcx
mov qword [rsp + 0x30], rcx
mov qword [rsp + 0x28], rdx
mov ecx, 0x20a
call fcn.140027fd4
mov rbx, rax
call fcn.140001540
mov rcx, rax
test rax, rax
je 0x1400216ce
mov rax, qword [rax]
mov rax, qword [rax + 0x18]
call qword [case.0x140027f5e.0]
add rax, 0x18
mov qword [rsp + 0x30], rax
lea rdi, [0x14002dea4]
mov rdx, rdi
lea rcx, [rsp + 0x30]
call fcn.14000ae00
mov r15, 0xffffffffffffffff
test al, al
jne 0x140021381
mov rax, r15
inc rax
cmp word [rdi + rax*2], 0
jne 0x140021366
mov r8d, eax
mov rdx, rdi
lea rcx, [rsp + 0x30]
call fcn.14000b2f0
nop
xor r13d, r13d
mov word [rbx], r13w
mov rcx, r14
cmp qword [r14 + 0x18], 0x10
jb 0x140021395
mov rcx, qword [r14]
cmp qword [r14 + 0x10], 2
jne 0x1400213c5
movzx eax, byte [rcx]
cmp al, byte [0x14002eea4]
jne 0x1400213b8
movzx eax, byte [rcx + 1]
cmp al, byte [0x14002eea5]
jne 0x1400213b8
mov eax, r13d
jmp 0x1400213bd
sbb eax, eax
or eax, 1
test eax, eax
jne 0x1400213c5
mov al, 1
jmp 0x1400213c7
xor al, al
lea rdi, str._x_sys_default_locale
mov rcx, r13
test al, al
cmovne rcx, rdi
mov r9d, 0x104
mov r8, rbx
mov edx, 0x59
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
test eax, eax
jne 0x1400213f8
lea rdx, str.unknown_
jmp 0x140021421
mov rax, r15
nop dword [rax + rax]
inc rax
cmp word [rbx + rax*2], r13w
jne 0x140021400
mov r8d, eax
mov rdx, rbx
lea rcx, [rsp + 0x30]
call fcn.14000b120
lea rdx, [0x140030b8c]
lea rcx, [rsp + 0x30]
call fcn.140021c60
mov word [rbx], r13w
mov rcx, r14
cmp qword [r14 + 0x18], 0x10
jb 0x14002143c
mov rcx, qword [r14]
cmp qword [r14 + 0x10], 2
jne 0x14002146c
movzx eax, byte [rcx]
cmp al, byte [0x14002eea4]
jne 0x14002145f
movzx eax, byte [rcx + 1]
cmp al, byte [0x14002eea5]
jne 0x14002145f
mov eax, r13d
jmp 0x140021464
sbb eax, eax
or eax, 1
test eax, eax
jne 0x14002146c
mov al, 1
jmp 0x14002146e
xor al, al
mov rcx, r13
test al, al
cmovne rcx, rdi
mov r9d, 0x104
mov r8, rbx
mov edx, 0x5a
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
test eax, eax
jne 0x1400214a2
lea rdx, [0x140030b18]
lea rcx, [rsp + 0x30]
call fcn.140021c60
jmp 0x1400214bf
mov rax, r15
inc rax
cmp word [rbx + rax*2], r13w
jne 0x1400214a5
mov r8d, eax
mov rdx, rbx
lea rcx, [rsp + 0x30]
call fcn.14000b120
mov rcx, rbx
call fcn.140027c70
mov rbx, qword [rsp + 0x30]
mov rsi, rbx
mov rdi, r13
movzx eax, word [rbx]
mov ebp, 1
test ax, ax
je 0x140021551
nop
movzx ecx, ax
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_iswspace]
test eax, eax
je 0x1400214fc
mov rax, rsi
test rdi, rdi
cmovne rax, rdi
mov rdi, rax
jmp 0x1400214ff
mov rdi, r13
add rsi, 2
movzx eax, word [rsi]
test ax, ax
jne 0x1400214e0
test rdi, rdi
je 0x140021551
sub rdi, rbx
sar rdi, 1
test edi, edi
js 0x1400216d9
mov ecx, ebp
sub ecx, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, edi
or eax, ecx
jge 0x14002153d
mov edx, edi
lea rcx, [rsp + 0x30]
call fcn.14000b430
mov rbx, qword [rsp + 0x30]
cmp edi, dword [rbx - 0xc]
jg 0x1400216ef
mov dword [rbx - 0x10], edi
movsxd rax, edi
mov word [rbx + rax*2], r13w
mov rdi, rbx
movzx ecx, word [rbx]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_iswspace]
test eax, eax
je 0x14002161b
nop word [rax + rax]
add rdi, 2
movzx ecx, word [rdi]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_iswspace]
test eax, eax
jne 0x140021570
cmp rdi, rbx
je 0x14002161b
sub rdi, rbx
sar rdi, 1
mov edx, dword [rbx - 0x10]
test edx, edx
js 0x1400216e4
sub ebp, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, edx
or eax, ebp
jge 0x1400215b6
lea rcx, [rsp + 0x30]
call fcn.14000b430
mov rbx, qword [rsp + 0x30]
movsxd rax, edi
lea rdx, [rbx + rax*2]
mov ecx, dword [rbx - 0x10]
mov esi, ecx
sub esi, edi
lea eax, [rsi + 1]
movsxd r8, eax
add r8, r8
je 0x1400215ff
test rdx, rdx
jne 0x1400215e5
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [rax], 0x16
jmp 0x140021706
lea eax, [rcx + 1]
movsxd rcx, eax
add rcx, rcx
cmp rcx, r8
jb 0x1400216fa
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
test esi, esi
js 0x1400216c3
cmp esi, dword [rbx - 0xc]
jg 0x1400216c3
mov dword [rbx - 0x10], esi
movsxd rax, esi
mov word [rbx + rax*2], r13w
lea rcx, [rbx - 0x18]
call fcn.14000b250
add rax, 0x18
mov qword [r12], rax
lock xadd dword [rbx - 8], r15d
sub r15d, 1
jg 0x14002164e
mov rcx, qword [rbx - 0x18]
mov rax, qword [rcx]
lea rdx, [rbx - 0x18]
mov rax, qword [rax + 8]
call qword [case.0x140027f5e.0]
nop
mov rdx, qword [r14 + 0x18]
cmp rdx, 0x10
jb 0x140021684
inc rdx
mov rcx, qword [r14]
cmp rdx, 0x1000
jb 0x14002167f
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x1400216bc
mov rcx, r8
call fcn.140027c70
mov qword [r14 + 0x10], r13
mov qword [r14 + 0x18], 0xf
mov byte [r14], 0
mov rax, r12
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140027890
mov rbx, qword [rsp + 0x90]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
mov ecx, 0x80070057
call fcn.140001280
nop
mov ecx, 0x80004005
call fcn.140001280
nop
mov ecx, 0x80070057
call fcn.140001280
int3
mov ecx, 0x80070057
call fcn.140001280
int3
mov ecx, 0x80070057
call fcn.140001280
int3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [rax], 0x22
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo]
mov ecx, 0x80070057
call fcn.140001280
int3