Function at 0x140040fb4
Capabilities:
Get geographical location

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x128
mov rax, qword [0x140050318]
xor rax, rsp
mov qword [rsp + 0x110], rax
mov r12, qword [rsp + 0x1a0]
xor esi, esi
mov r15, rdx
mov qword [r8], rsi
mov dword [r12], esi
mov rdx, qword [0x1400c28e8]
mov r14, r9
mov rbp, r8
mov r13, rcx
mov qword [rsp + 0x60], rcx
mov rbx, rsi
cmp qword [r9], rdx
jae 0x14004101a
mov rdi, qword [r9]
shl rdi, 6
add rdi, qword [0x1400c28e0]
jmp 0x14004103f
mov rcx, qword [0x1400c2908]
add rcx, rdx
cmp qword [r9], rcx
jae 0x14004103c
mov rdi, qword [r9]
sub rdi, rdx
shl rdi, 6
add rdi, qword [0x1400c2900]
jmp 0x14004103f
mov rdi, rsi
cmp rdi, rsi
je 0x14004161f
movsxd rsi, dword [rsp + 0x190]
lea rcx, [0x14006e710]
mov rax, rsi
shl rax, 5
mov qword [rsp + 0x48], rax
mov ecx, dword [rax + rcx + 0x18]
test cl, 0x40
je 0x140041156
sub esi, 0x10
mov r13d, dword [rdi + 0x10]
je 0x140041083
cmp esi, 1
jne 0x140041096
mov rcx, qword [r9]
jmp 0x140041087
mov rcx, qword [r9 + 0x18]
call fcn.1400405c0
xor ecx, ecx
cmp al, cl
je 0x140041612
test byte [rsp + 0x198], 0x20
je 0x1400410ae
call qword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
cmp ax, r13w
cmove r13d, eax
mov eax, 2
lea rcx, [0x14006e710]
test byte [rsp + 0x198], al
mov rax, qword [rsp + 0x48]
mov esi, dword [rax + rcx + 0x10]
je 0x1400410d0
bts esi, 0x1f
cmp r13d, 0x1000
jne 0x140041118
call fcn.140042e00
xor ecx, ecx
cmp al, cl
je 0x140041118
mov r8, qword [rsp + 0x60]
mov rcx, qword [rdi + 8]
mov r9d, r15d
mov edx, esi
call fcn.140042bd4
xor ecx, ecx
movsxd rbx, eax
cmp rbx, rcx
jne 0x140041368
mov rcx, qword [rdi + 8]
xor r9d, r9d
xor r8d, r8d
mov edx, esi
call fcn.140042bd4
jmp 0x14004114a
mov r8, qword [rsp + 0x60]
mov r9d, r15d
mov edx, esi
mov ecx, r13d
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
movsxd rbx, eax
xor eax, eax
cmp rbx, rax
jne 0x140041368
mov edx, esi
xor r9d, r9d
xor r8d, r8d
mov ecx, r13d
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
movsxd rcx, eax
mov qword [rbp], rcx
jmp 0x140041612
test cl, cl
jns 0x140041371
mov rcx, qword [r9 + 0x10]
mov r13d, dword [rdi + 0x10]
xor eax, eax
mov qword [rsp + 0x58], rcx
mov dword [rsp + 0x40], eax
cmp rcx, rax
jne 0x140041199
mov rcx, qword [r9]
lea r8, [rsp + 0x58]
lea edx, [rax + 1]
call fcn.14003cdd4
xor ecx, ecx
cmp eax, ecx
mov dword [r12], eax
jl 0x140041627
mov rcx, qword [rsp + 0x58]
lea rdx, [rsp + 0x40]
call fcn.140038f10
xor edx, edx
cmp eax, edx
mov dword [r12], eax
jl 0x140041627
cmp esi, 0x29
jne 0x140041203
mov rdi, qword [r14 + 0x18]
mov rdx, qword [0x1400c28e8]
cmp rdi, rdx
jae 0x1400411d3
shl rdi, 6
add rdi, qword [0x1400c28e0]
jmp 0x1400411f4
mov rcx, qword [0x1400c2908]
add rcx, rdx
cmp rdi, rcx
jae 0x1400411f2
sub rdi, rdx
shl rdi, 6
add rdi, qword [0x1400c2900]
jmp 0x1400411f4
xor edi, edi
xor eax, eax
cmp rdi, rax
je 0x140041612
mov r13d, dword [rdi + 0x10]
test byte [rsp + 0x198], 0x20
je 0x14004121b
call qword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
cmp ax, r13w
cmove r13d, eax
mov eax, 2
lea rcx, [0x14006e710]
test byte [rsp + 0x198], al
mov rax, qword [rsp + 0x48]
mov esi, dword [rax + rcx + 0x10]
je 0x14004123d
bts esi, 0x1f
cmp r13d, 0x1000
jne 0x1400412aa
call fcn.140042e00
cmp al, bl
je 0x1400412aa
mov rax, qword [rsp + 0x60]
mov edx, dword [rsp + 0x40]
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x30], rbx
mov r9d, esi
xor r8d, r8d
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], rax
call fcn.140042c28
movsxd rbx, eax
xor eax, eax
cmp rbx, rax
jne 0x140041368
mov edx, dword [rsp + 0x40]
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], eax
mov r9d, esi
xor r8d, r8d
mov qword [rsp + 0x20], rax
call fcn.140042c28
jmp 0x14004114a
call qword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
cmp r13d, eax
jne 0x14004131e
cmp esi, 5
je 0x1400412bf
cmp esi, 6
jne 0x14004131e
lea r8, [rsp + 0x70]
mov r9d, 0x50
mov edx, 0x1009
mov ecx, r13d
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
cmp eax, ebx
jbe 0x14004131e
lea rcx, [rsp + 0x70]
call qword [sym.imp.MSVCR90.dll__wtoi]
mov edx, dword [rsp + 0x40]
cmp eax, edx
jne 0x140041322
mov r8, qword [rsp + 0x60]
mov edi, ebx
cmp esi, 5
setne dil
mov r9d, r15d
mov ecx, r13d
lea edx, [rdi + 0x1f]
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
movsxd rbx, eax
xor eax, eax
cmp rbx, rax
jne 0x140041368
lea edx, [rdi + 0x1f]
jmp 0x14004113b
mov edx, dword [rsp + 0x40]
mov r9, qword [rsp + 0x60]
mov r8d, esi
mov ecx, r13d
mov qword [rsp + 0x28], rbx
mov dword [rsp + 0x20], r15d
call qword [sym.imp.KERNEL32.dll_GetCalendarInfoW]
movsxd rbx, eax
xor eax, eax
cmp rbx, rax
jne 0x140041368
mov edx, dword [rsp + 0x40]
mov qword [rsp + 0x28], rax
xor r9d, r9d
mov r8d, esi
mov ecx, r13d
mov dword [rsp + 0x20], eax
call qword [sym.imp.KERNEL32.dll_GetCalendarInfoW]
jmp 0x14004114a
mov qword [rbp], rbx
jmp 0x140041612
cmp esi, 4
jl 0x14004161f
cmp esi, 5
jle 0x1400415f9
cmp esi, 0xe
je 0x1400415c1
mov eax, 0xf
cmp esi, eax
je 0x140041538
mov eax, 0x35
cmp esi, eax
jle 0x14004161f
cmp esi, 0x42
jg 0x14004161f
xor edx, edx
cmp qword [r9 + 0x10], rdx
je 0x14004161f
lea ecx, [rdx + 0xa]
mov eax, 0x7d6
lea r9d, [rdx + 0x50]
mov word [rsp + 0x48], ax
lea eax, [rdx + 2]
mov word [rsp + 0x4a], cx
mov word [rsp + 0x4c], ax
mov word [rsp + 0x50], ax
lea eax, [rdx + 0x1d]
mov word [rsp + 0x4e], cx
mov ecx, dword [rdi + 0x10]
mov word [rsp + 0x52], ax
lea eax, [rdx + 0x17]
mov dword [rsp + 0x40], edx
mov word [rsp + 0x56], dx
lea r8, [rsp + 0x70]
mov edx, 0x1009
mov word [rsp + 0x54], ax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
movsxd rbx, eax
xor eax, eax
cmp rbx, rax
jbe 0x14004142a
lea rcx, [rsp + 0x70]
call qword [sym.imp.MSVCR90.dll__wtoi]
mov dword [rsp + 0x40], eax
jmp 0x14004142e
mov eax, dword [rsp + 0x40]
cmp eax, 1
jne 0x140041612
mov rcx, qword [r14 + 0x10]
lea rdx, [rsp + 0x40]
call fcn.140038f10
xor ecx, ecx
cmp eax, ecx
mov dword [r12], eax
jl 0x140041627
cmp dword [rsp + 0x40], 1
jne 0x140041612
lea edx, [rcx + 1]
mov rcx, qword [r14]
xor eax, eax
lea r8, [rsp + 0x58]
mov qword [rsp + 0x58], rax
call fcn.14003cdd4
xor ecx, ecx
cmp eax, ecx
mov dword [r12], eax
jl 0x140041627
mov rcx, qword [rsp + 0x58]
lea rdx, [rsp + 0x40]
call fcn.140038f10
xor r14d, r14d
cmp eax, r14d
mov dword [r12], eax
jl 0x140041627
cmp dword [rsp + 0x40], 1
jne 0x140041612
mov ecx, dword [rdi + 0x10]
lea rax, [rsp + 0x70]
lea r9, str.ddMMMM
lea r8, [rsp + 0x48]
sub si, 0x35
xor edx, edx
mov dword [rsp + 0x28], 0x50
mov qword [rsp + 0x20], rax
mov word [rsp + 0x4a], si
call qword [sym.imp.KERNEL32.dll_GetDateFormatW]
movsxd rbx, eax
cmp rbx, r14
jbe 0x140041612
or rcx, 0xffffffffffffffff
xor eax, eax
xor ebx, ebx
lea rdi, [rsp + 0x74]
mov dword [r12], ebx
repne scasw ax, word [rdi]
not rcx
mov qword [rbp], rcx
cmp rcx, r15
ja 0x14004152b
lea r8, [rsp + 0x74]
mov rdx, r15
mov rcx, r13
call qword [sym.imp.MSVCR90.dll_wcscpy_s]
mov dword [r12], ebx
mov rbx, qword [rbp]
xor ebp, ebp
jmp 0x14004161a
mov dword [r12], 0x8007007a
jmp 0x140041612
mov ebx, dword [rdi + 0x10]
mov edi, ebx
shr edi, 0x10
and di, ax
test byte [rsp + 0x198], 0x20
je 0x140041563
call qword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
cmp ax, bx
jne 0x140041563
shr eax, 0x10
mov edi, 0xf
and di, ax
movzx ecx, di
mov edx, 0x30
cmp rcx, 9
ja 0x140041576
add dx, cx
jmp 0x140041583
lea rax, [rcx - 0xa]
cmp rax, 5
ja 0x140041583
lea edx, [rcx + 0x57]
xor ebx, ebx
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x40]
mov word [rsp + 0x40], dx
mov word [rsp + 0x42], bx
repne scasw ax, word [rdi]
mov dword [r12], ebx
not rcx
mov qword [rbp], rcx
cmp rcx, r15
ja 0x1400415b7
lea r8, [rsp + 0x40]
jmp 0x140041510
mov dword [r12], 0x8007007a
jmp 0x140041627
xor eax, eax
cmp qword [r9 + 8], rax
jne 0x1400415e0
mov rcx, qword [r9]
lea rdx, [rsp + 0x58]
call fcn.14003c73c
xor ecx, ecx
cmp eax, ecx
mov dword [r12], eax
jl 0x140041627
mov rcx, qword [r14 + 8]
mov r9, rbp
mov r8, r15
mov rdx, r13
mov qword [rsp + 0x20], r12
call fcn.14003a6c8
jmp 0x14004160f
mov rcx, qword [r14]
mov r9, r8
mov rdx, r13
mov r8, r15
mov qword [rsp + 0x20], r12
call fcn.14003be40
mov rbx, rax
xor ebp, ebp
cmp dword [r12], ebp
jl 0x140041627
cmp rbx, rbp
jne 0x140041627
mov dword [r12], 0x80004005
mov rax, rbx
mov rcx, qword [rsp + 0x110]
xor rcx, rsp
call fcn.140008a98
add rsp, 0x128
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret