Function at 0x409310
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x17c
mov eax, dword [0x42d0b4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x168], esi
push edi
mov edi, edx
test ecx, ecx
jne 0x41bb7a
lea eax, [ebp - 0x158]
push eax
call dword [sym.imp.api_ms_win_core_sysinfo_l1_1_0.dll_GetSystemTime]
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x158]
push eax
call dword [sym.imp.api_ms_win_core_timezone_l1_1_0.dll_SystemTimeToFileTime]
lea eax, [ebp - 0x178]
push eax
lea eax, [ebp - 0x170]
push eax
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_FileTimeToLocalFileTime]
lea eax, [ebp - 0x158]
push eax
lea eax, [ebp - 0x178]
push eax
call dword [sym.imp.api_ms_win_core_timezone_l1_1_0.dll_FileTimeToSystemTime]
cmp edi, 1
jne 0x41bb97
movzx eax, word [ebp - 0x14a]
xor edx, edx
push 0xa
pop ecx
div ecx
mov ecx, 0x43b9e0
push eax
movzx eax, word [ebp - 0x14c]
push 0x43b9c0
push eax
movzx eax, word [ebp - 0x14e]
push ecx
push eax
movzx eax, word [ebp - 0x150]
push ecx
push eax
push 0x40222c
test esi, esi
je 0x41bb8a
push dword [ebp + 0xc]
push esi
call fcn.00409abf
add esp, 0x28
lea edx, [esi + 2]
xor ecx, ecx
push 2
pop ebx
mov ax, word [esi]
add esi, ebx
cmp ax, cx
jne 0x4093e1
sub esi, edx
sar esi, 1
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00416b50
leave
ret 8
lea edx, [ebp - 0x170]
call fcn.00424897
jmp 0x40935c
call fcn.00409950
add esp, 0x20
jmp 0x41bd1f
push 2
xor edi, edi
cmp byte [0x435755], 0
pop ebx
je 0x41bd26
mov dword [ebp - 0x15c], edi
lea eax, [ebp - 0x148]
lea edi, [ebx + 0x7e]
push edi
push eax
push 0x1003
call fcn.00408791
push eax
call dword [sym.imp.api_ms_win_core_localization_l1_2_0.dll_GetLocaleInfoW]
test eax, eax
jne 0x41bc06
lea ecx, [ebp - 0x148]
mov edx, 0x4039fc
mov eax, ecx
sub edx, eax
lea eax, [edi + 0x7fffff7e]
test eax, eax
je 0x41bbfb
movzx eax, word [edx + ecx]
test ax, ax
je 0x41bbfb
mov word [ecx], ax
add ecx, ebx
sub edi, 1
jne 0x41bbde
test edi, edi
jne 0x41bc01
sub ecx, ebx
xor eax, eax
mov word [ecx], ax
mov ax, word [ebp - 0x148]
lea edi, [ebp - 0x148]
test ax, ax
je 0x41bcd4
movzx ecx, ax
xor esi, esi
mov dword [ebp - 0x164], ecx
cmp cx, 0x27
jne 0x41bc42
xor eax, eax
add edi, ebx
cmp dword [ebp - 0x15c], eax
sete al
mov dword [ebp - 0x15c], eax
jmp 0x41bcb8
cmp dword [ebp - 0x15c], esi
je 0x41bc4e
add edi, ebx
jmp 0x41bcb8
cmp cx, 0x68
je 0x41bc60
cmp cx, 0x48
je 0x41bc60
cmp cx, 0x6d
jne 0x41bcb8
mov edx, esi
add edi, ebx
inc edx
cmp word [edi], cx
je 0x41bc62
mov eax, edx
neg eax
lea eax, [edi + eax*2]
mov dword [ebp - 0x160], eax
lea edi, [eax + 2]
cmp edx, 1
jne 0x41bcb8
mov ecx, eax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, ebx
cmp ax, si
jne 0x41bc84
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push dword [ebp - 0x160]
push edi
call sub.msvcrt.dll_memmove
mov ecx, dword [ebp - 0x160]
add esp, 0xc
mov eax, dword [ebp - 0x164]
mov word [ecx], ax
add edi, ebx
movzx eax, word [edi]
mov ecx, eax
mov dword [ebp - 0x164], ecx
test ax, ax
jne 0x41bc27
mov esi, dword [ebp - 0x168]
push 0x20
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x148]
push eax
lea eax, [ebp - 0x158]
push eax
push ebx
call fcn.00408791
push eax
call dword [sym.imp.api_ms_win_core_datetime_l1_1_0.dll_GetTimeFormatW]
test eax, eax
jne 0x41bcfd
mov word [ebp - 0x48], ax
xor edi, edi
test esi, esi
jne 0x41bd7d
lea edx, [ebp - 0x48]
lea ecx, [edx + 2]
mov ax, word [edx]
add edx, ebx
cmp ax, di
jne 0x41bd09
sub edx, ecx
lea ecx, [ebp - 0x48]
sar edx, 1
call fcn.0040998d
mov esi, eax
jmp 0x4093ef
mov eax, 0x403a14
movzx ecx, word [ebp - 0x150]
cmp dword [0x42d0c4], edi
je 0x41bd54
push 0xc
pop edx
cmp ecx, edx
jb 0x41bd4c
jbe 0x41bd45
sub ecx, edx
mov eax, 0x403a18
jmp 0x41bd59
test ecx, ecx
jne 0x41bd59
mov ecx, edx
jmp 0x41bd59
mov eax, 0x40234c
push eax
movzx eax, word [ebp - 0x14e]
push eax
push 0x43b9e0
push ecx
push 0x403a8c
lea eax, [ebp - 0x48]
push 0x20
push eax
call fcn.00409abf
add esp, 0x1c
jmp 0x41bcff
mov edx, dword [ebp + 0xc]
lea eax, [ebp - 0x48]
push eax
mov ecx, esi
call fcn.0040f3a0
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, ebx
cmp ax, di
jne 0x41bd8e
sub esi, ecx
jmp 0x4093ed