Function at 0x540990
Capabilities:
Get geographical location
Get keyboard layout
Hide graphical window
Resolve function by parsing pe exports

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x17c
mov dword [esp], 0
mov ebx, dword [esp + 0x190]
call fcn.00544a50
cmp byte [0x621a20], 0
je 0x540ee0
mov eax, dword [ebx + 4]
test eax, eax
je 0x5409d3
mov ecx, ebx
call fcn.0055ec60
mov eax, dword [eax + 0x68]
test eax, eax
je 0x541350
cmp byte [0x61cf98], 0
je 0x5411e0
mov ecx, ebx
call fcn.0055efc0
test eax, eax
mov esi, eax
je 0x541330
mov ebp, dword [0x632fbc]
test ebp, ebp
je 0x541343
mov dword [esp], esi
call sub.msvcrt.dll_strlen
lea edx, [esp + 0xa8]
mov dword [esp + 0xc], 0x64
mov dword [esp + 4], eax
mov dword [esp], esi
mov dword [esp + 8], edx
call fcn.0060aa20
mov eax, dword [0x632fb4]
mov edi, dword [0x632fb0]
test eax, eax
jle 0x540cf7
mov dword [esp + 0x190], ebx
xor ebp, ebp
mov ebx, edi
mov edi, eax
jmp 0x540a5b
add ebp, 1
cmp ebp, edi
je 0x540cf0
mov dword [esp + 4], esi
mov eax, dword [ebx + ebp*4]
mov dword [esp], eax
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x540a50
mov esi, dword [0x63311c]
mov ebx, dword [esp + 0x190]
mov edi, dword [sym.imp.USER32.dll_LoadCursorA]
test esi, esi
je 0x540ddf
mov eax, dword [ebx + 0x14]
mov ecx, dword [ebx + 4]
mov ebp, dword [ebx + 0x10]
mov dword [esp + 0x38], eax
mov eax, dword [ebx + 0x18]
test ecx, ecx
mov dword [esp + 0x3c], eax
mov eax, dword [ebx + 0x1c]
mov dword [esp + 0x48], eax
je 0x540ff1
mov ecx, ebx
call fcn.0055ec60
mov eax, dword [eax + 0x68]
test eax, eax
je 0x541363
mov eax, dword [eax]
mov dword [esp + 0x5c], 0
mov dword [esp + 0x50], 1
mov dword [esp + 0x44], 0x10100
mov dword [esp + 0x40], 0x46000000
mov dword [esp + 0x4c], eax
mov dword [esp], 0x28
call fcn.00606ce0
mov esi, eax
mov dword [eax + 4], 0
mov dword [eax + 8], ebx
mov dword [ebx + 0x68], eax
mov dword [eax + 0xc], 0
mov dword [eax + 0x18], 0
mov dword [esp + 4], 0x7f00
mov dword [esp], 0
call edi
mov ecx, dword [0x633078]
sub esp, 8
mov dword [esi + 0x1c], eax
mov dword [esi + 0x20], 0
test ecx, ecx
je 0x541143
mov edi, dword [ebx + 0x20]
test edi, edi
je 0x540f82
mov dword [esp], edi
call sub.msvcrt.dll_strlen
mov dword [esp], edi
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], eax
mov dword [esp + 0x58], eax
call fcn.0060aa20
lea edx, [eax + 1]
lea eax, [edx + edx]
mov dword [esp + 0x54], edx
mov dword [esp], eax
call sub.msvcrt.dll_malloc
mov edx, dword [esp + 0x54]
mov ecx, dword [esp + 0x58]
mov edi, eax
mov dword [esp + 8], eax
mov dword [esp + 0xc], edx
mov dword [esp + 4], ecx
mov eax, dword [ebx + 0x20]
mov dword [esp], eax
call fcn.0060aa20
xor edx, edx
mov word [edi + eax*2], dx
mov eax, dword [0x633084]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x24], 0
mov dword [esp + 0x10], ebp
mov dword [esp + 8], edi
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x48]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0xc], eax
lea eax, [esp + 0xa8]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x44]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_CreateWindowExW]
sub esp, 0x30
test edi, edi
mov dword [esi], eax
je 0x540c17
mov dword [esp], edi
call fcn.004defc0
mov eax, dword [0x6211a4]
mov ecx, esi
mov dword [0x6211a4], esi
mov dword [esi + 0x10], eax
call fcn.005416e0
test byte [ebx + 0x42], 4
jne 0x541190
mov eax, dword [0x61e528]
test eax, eax
je 0x540c67
mov eax, dword [0x61dc64]
test eax, eax
jne 0x540c67
mov eax, dword [esi]
mov byte [0x61e548], 1
mov dword [0x61dc64], eax
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetClipboardViewer]
sub esp, 4
mov dword [0x61e55c], eax
cmp byte [0x633114], 0
mov dword [esi + 0x14], 1
je 0x540e00
mov byte [0x633114], 0
test byte [ebx + 0x41], 0x40
jne 0x541300
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
mov eax, 7
mov dword [esp + 4], eax
mov eax, dword [esi]
mov dword [esp], eax
call ebp
mov eax, dword [0x633060]
sub esp, 8
mov dword [esp + 4], eax
mov eax, dword [esi]
mov dword [esp], eax
call dword [sym.imp.ole32.dll_RegisterDragDrop]
sub esp, 8
cmp byte [0x61cfbc], 0
jne 0x540ce3
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [esi]
mov dword [esp], eax
call dword [0x61e57c]
sub esp, 0xc
add esp, 0x17c
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebx, dword [esp + 0x190]
lea ebp, [esp + 0x78]
xor eax, eax
mov ecx, 0xc
mov edi, ebp
rep stosd dword es:[edi], eax
mov eax, dword [0x633084]
mov ecx, ebx
mov dword [esp + 0x78], 0x30
mov dword [esp + 0x7c], 0x2b
mov dword [esp + 0x80], 0x4f6370
mov dword [esp + 0x8c], eax
call fcn.0055eec0
test eax, eax
je 0x541478
mov ecx, ebx
call fcn.0055eec0
mov dword [esp + 4], 0x7f00
mov dword [esp + 0xa4], eax
mov dword [esp + 0x90], eax
mov dword [esp], 0
mov edi, dword [sym.imp.USER32.dll_LoadCursorA]
call edi
sub esp, 8
mov dword [esp + 0x94], eax
lea eax, [esp + 0xa8]
mov dword [esp + 0x98], 0
mov dword [esp + 0x9c], 0
mov dword [esp], ebp
mov dword [esp + 0xa0], eax
call dword [sym.imp.USER32.dll_RegisterClassExW]
mov edx, dword [0x632fb4]
sub esp, 4
cmp dword [0x632fb8], edx
je 0x541423
mov eax, dword [0x632fb0]
lea ecx, [edx + 1]
lea ebp, [eax + edx*4]
mov dword [esp], esi
mov dword [0x632fb4], ecx
call dword [sym.imp.msvcrt.dll__strdup]
mov dword [ebp], eax
mov esi, dword [0x63311c]
test esi, esi
jne 0x540a89
mov dword [esp], str.FLTK::ThreadWakeup
call dword [sym.imp.USER32.dll_RegisterWindowMessageW]
sub esp, 4
mov dword [0x63311c], eax
jmp 0x540a89
mov eax, dword [esp + 0x50]
test eax, eax
je 0x540c82
mov eax, dword [ebx]
and dword [ebx + 0x40], 0xfffffffd
mov edi, dword [0x62118c]
mov dword [0x62118c], 0x10
mov eax, dword [eax + 0xc]
cmp eax, fcn.00555780
jne 0x54140a
mov eax, dword [ebx + 4]
test eax, eax
je 0x54146d
mov eax, dword [ebx + 0x68]
test eax, eax
je 0x5415a5
mov dword [esp + 4], 9
mov eax, dword [eax]
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
mov dword [esp], eax
call ebp
sub esp, 8
mov dword [esp], 0x10
mov ecx, ebx
call fcn.00543880
sub esp, 4
cmp byte [ebx + 0x4c], 0xef
mov dword [0x62118c], edi
jbe 0x5413d8
mov edi, dword [ebx + 0x68]
test edi, edi
je 0x540eae
mov eax, dword [edi + 0xc]
test eax, eax
je 0x540ea0
mov dword [esp], eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [edi + 0xc], 0
sub esp, 4
or byte [ebx + 0x4d], 0x80
mov dword [0x62116c], 1
test byte [ebx + 0x41], 0x40
jne 0x541390
mov ebx, dword [0x621158]
mov eax, 4
test ebx, ebx
jne 0x540c97
cmp dword [esp + 0x5c], 1
sbb eax, eax
and eax, 0xfffffffd
add eax, 4
jmp 0x540c97
mov byte [0x621a20], 1
mov dword [esp], 0
call dword [sym.imp.ole32.dll_OleInitialize]
sub esp, 4
mov dword [esp], str.IMM32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
sub esp, 4
test eax, eax
mov dword [0x61dc50], eax
je 0x5414b0
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esp + 4], str.ImmAssociateContextEx
mov dword [esp], eax
call esi
mov dword [0x61e57c], eax
mov eax, dword [0x61dc50]
sub esp, 8
mov dword [esp + 4], str.ImmGetContext
mov dword [esp], eax
call esi
mov dword [0x61e51c], eax
mov eax, dword [0x61dc50]
sub esp, 8
mov dword [esp + 4], str.ImmSetCompositionWindow
mov dword [esp], eax
call esi
mov dword [0x61e580], eax
mov eax, dword [0x61dc50]
sub esp, 8
mov dword [esp + 4], str.ImmReleaseContext
mov dword [esp], eax
call esi
sub esp, 8
mov dword [0x61e560], eax
jmp 0x5409ba
mov eax, dword [0x633084]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x24], 0
mov dword [esp + 0x10], ebp
mov dword [esp + 8], 0
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x48]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0xc], eax
lea eax, [esp + 0xa8]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x44]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_CreateWindowExW]
sub esp, 0x30
mov dword [esi], eax
jmp 0x540c17
movzx eax, byte [ebx + 0x94]
test al, al
je 0x541240
mov edx, dword [ebx + 0x84]
mov ecx, dword [ebx + 0x80]
mov esi, dword [ebx + 0x78]
mov dword [esp + 0x54], eax
mov dword [esp + 0x50], edx
mov edx, dword [ebx + 0x7c]
mov dword [esp + 0x4c], edx
mov edx, dword [ebx + 0x40]
test dl, 8
je 0x5413a0
mov dword [esp + 0x5c], pe_nt_image_headers32
mov dword [esp + 0x44], 0x10180
mov dword [esp + 0x40], 0x86000000
mov eax, dword [esp + 0x54]
mov edx, dword [esp + 0x38]
mov dword [esp + 0x14], ecx
lea ecx, [esp + 0x6c]
mov dword [esp + 0x18], esi
mov dword [esp + 0x68], ebp
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x6c], edx
lea edx, [esp + 0x68]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x50]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x44]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0xc], eax
lea eax, [esp + 0x78]
mov dword [esp + 8], eax
lea eax, [esp + 0x74]
mov dword [esp + 4], eax
lea eax, [esp + 0x70]
mov dword [esp], eax
mov eax, ebx
call fcn.004f0f70
mov eax, dword [esp + 0x78]
mov edx, eax
add edx, dword [esp + 0x70]
je 0x5410c5
mov esi, dword [esp + 0x3c]
mov ecx, dword [esp + 0x74]
add eax, edx
add dword [esp + 0x48], eax
lea ecx, [esi + ecx*2]
mov dword [esp + 0x3c], ecx
mov eax, dword [ebx + 0x40]
test al, 0x10
jne 0x541310
mov dword [esp + 0x38], 0x80000000
mov ebp, 0x80000000
test eax, 0x4020
je 0x5412d1
mov eax, dword [0x6211a4]
test eax, eax
je 0x5412d1
mov edx, dword [0x633080]
test edx, edx
jne 0x5412d1
mov eax, dword [eax + 8]
mov edx, dword [eax + 4]
test edx, edx
je 0x54111e
lea esi, [esi]
mov ecx, eax
call fcn.0055ec60
mov esi, dword [eax + 4]
test esi, esi
jne 0x541110
mov edx, dword [eax + 0x68]
test edx, edx
je 0x5414c7
mov ecx, dword [edx]
mov dword [esp + 0x4c], ecx
mov eax, dword [eax + 0x40]
shr eax, 1
xor eax, 1
and eax, 1
mov dword [esp + 0x50], eax
jmp 0x540ae4
mov dword [esp], 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
sub esp, 4
movzx eax, ax
lea edi, [esp + 0x78]
mov dword [esp + 0xc], 6
mov dword [esp + 4], 0x1004
mov dword [esp], eax
mov dword [esp + 8], edi
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
sub esp, 0x10
mov dword [esp], edi
call sub.msvcrt.dll_atol
mov dword [0x633078], eax
jmp 0x540b39
lea eax, [esp + 0x78]
mov dword [esp + 4], eax
mov eax, dword [esi]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_GetWindowRect]
sub esp, 8
mov ecx, dword [esp + 0x7c]
mov eax, dword [esp + 0x84]
mov edx, dword [esp + 0x78]
sub eax, ecx
mov dword [esp + 4], ecx
mov ecx, esi
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x80]
mov dword [esp], edx
sub eax, edx
mov dword [esp + 8], eax
call fcn.00540600
sub esp, 0x10
jmp 0x540c36
mov dword [esp], 0x61cf98
call fcn.006076c0
test eax, eax
je 0x5409e0
mov dword [esp], 4
call sub.msvcrt.dll_malloc
mov dword [esp], 0x61cf98
mov dword [0x632fb0], eax
mov dword [0x632fb8], 1
mov dword [0x632fb4], 0
call fcn.00607880
mov dword [esp], 0x6082c0
call fcn.004014b0
jmp 0x5409e0
mov edx, dword [ebx + 0x5c]
test edx, edx
je 0x5414d4
mov eax, dword [edx + 0x18]
mov esi, dword [esp + 0x48]
mov ecx, 0x64
mov edx, dword [edx + 0x1c]
mov dword [esp + 0x54], 1
mov dword [ebx + 0x80], 0
mov dword [ebx + 0x84], 0
mov dword [ebx + 0x88], 0
mov dword [ebx + 0x8c], 0
sub esi, edx
cmp edx, 0x64
mov dword [ebx + 0x90], 0
cmovg edx, ecx
mov byte [ebx + 0x94], 1
mov dword [esp + 0x50], 0
add edx, esi
mov esi, dword [esp + 0x3c]
mov dword [esp + 0x4c], edx
mov edx, dword [esp + 0x4c]
sub esi, eax
cmp eax, 0x64
cmovg eax, ecx
mov dword [ebx + 0x7c], edx
xor ecx, ecx
lea esi, [esi + eax]
mov dword [ebx + 0x78], esi
jmp 0x54101e
mov eax, dword [0x621158]
test eax, eax
je 0x541450
mov eax, dword [eax + 0x68]
test eax, eax
je 0x541450
mov eax, dword [eax]
mov dword [esp + 0x50], 1
mov dword [esp + 0x4c], eax
jmp 0x540ae4
mov dword [0x621164], ebx
call fcn.004e0640
jmp 0x540c8c
mov ecx, dword [0x621158]
test ecx, ecx
je 0x541550
sub ebp, dword [esp + 0x74]
sub dword [esp + 0x38], edx
jmp 0x5410dd
mov esi, dword [0x632fbc]
test esi, esi
jne 0x5409ff
mov esi, 0x664f61
mov dword [0x632fbc], esi
jmp 0x5409ff
and dword [ebx + 0x40], 0xfffffffd
xor esi, esi
add esp, 0x17c
pop ebx
mov eax, esi
pop esi
pop edi
pop ebp
mov dword [esp + 0x5c], 0
mov dword [esp + 0x50], 1
mov dword [esp + 0x44], 0x10100
mov dword [esp + 0x40], 0x46000000
mov dword [esp + 0x4c], 0
jmp 0x540ae4
mov dword [0x621164], ebx
call fcn.004e0640
jmp 0x540eb8
cmp ecx, esi
je 0x541567
and edx, 0x4000
mov dword [esp + 0x5c], 0
mov dword [esp + 0x44], 0x10100
cmp edx, 1
sbb edx, edx
and edx, 0x20000
add edx, 0x6cd0000
mov dword [esp + 0x40], edx
jmp 0x541042
mov eax, dword [ebx + 0x1c]
mov ecx, ebx
mov dword [esp + 0x10], eax
mov eax, dword [ebx + 0x18]
mov dword [esp + 0xc], eax
mov eax, dword [ebx + 0x14]
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x10]
mov dword [esp], pe_nt_image_headers32
mov dword [esp + 4], eax
call fcn.00552290
sub esp, 0x14
jmp 0x540eae
mov dword [esp], 0x10
mov ecx, ebx
call eax
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
sub esp, 4
jmp 0x540e6f
mov eax, dword [0x632fb0]
add edx, 5
mov dword [0x632fb8], edx
shl edx, 2
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.msvcrt.dll_realloc
mov edx, dword [0x632fb4]
mov dword [0x632fb0], eax
jmp 0x540db9
mov dword [esp + 0x50], 1
mov dword [esp + 0x4c], 0
jmp 0x540ae4
mov dword [esp], ebx
call fcn.00540990
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
jmp 0x540e5e
mov eax, dword [ebx + 0x74]
mov edi, dword [eax + 8]
test edi, edi
jne 0x540d3c
mov dword [esp + 4], 0x7f00
mov dword [esp], 0
call dword [sym.imp.USER32.dll_LoadIconA]
sub esp, 8
mov ecx, ebx
mov dword [esp], eax
call fcn.00554d10
sub esp, 4
jmp 0x540d3c
mov dword [esp], str.FLTK_Lib_Error:_IMM32.DLL_file_not_found__n_nPlease_check_your_input_method_manager_library_accessibility.
call dword [0x621154]
mov eax, dword [0x61dc50]
jmp 0x540f14
mov dword [esp + 0x4c], 0
jmp 0x54112f
mov edx, dword [ebx + 0x40]
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x48]
mov dword [ebx + 0x88], 0
mov dword [ebx + 0x8c], 0
mov dword [ebx + 0x90], 0
test dl, 8
mov dword [ebx + 0x78], eax
mov dword [ebx + 0x80], eax
mov dword [ebx + 0x7c], ecx
mov dword [ebx + 0x84], ecx
mov byte [ebx + 0x94], 1
je 0x541621
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], ecx
mov esi, eax
mov ecx, eax
mov dword [esp + 0x54], 1
mov dword [esp + 0x5c], pe_nt_image_headers32
mov dword [esp + 0x44], 0x10180
mov dword [esp + 0x40], 0x86000000
jmp 0x541042
mov ecx, dword [esp + 0x6c]
mov ebp, dword [esp + 0x68]
mov dword [esp + 0x38], ecx
mov dword [ebx + 0x10], ebp
mov dword [ebx + 0x14], ecx
jmp 0x54131e
mov eax, dword [esp + 0x4c]
cmp dword [esp + 0x50], eax
jne 0x5413a8
and edx, 0x4000
mov dword [esp + 0x5c], 0
mov dword [esp + 0x44], 0x10100
cmp edx, 1
sbb edx, edx
and edx, 0xa0000
add edx, 0x6c00000
mov dword [esp + 0x40], edx
jmp 0x541042
mov eax, dword [ebx]
mov eax, dword [eax + 0x14]
cmp eax, fcn.00554fa0
jne 0x541659
mov eax, dword [0x621100]
test eax, eax
mov dword [ebx + 0x24], eax
je 0x54164f
mov dword [ebx + 0x38], 0x50
xor eax, eax
mov byte [ebx + 0x3c], al
mov dword [esp], ebx
call dword [0x61fe08]
mov eax, dword [ebx + 0x68]
test eax, eax
je 0x541465
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_IsIconic]
sub esp, 4
test eax, eax
jne 0x54163c
mov ebp, dword [0x633070]
test ebp, ebp
jne 0x54146d
mov eax, dword [ebx + 0x68]
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_BringWindowToTop]
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
sub esp, 4
jmp 0x540e5e
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], ecx
mov ecx, dword [esp + 0x3c]
mov dword [esp + 0x54], 1
mov esi, ecx
jmp 0x541575
mov eax, dword [ebx + 0x68]
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_OpenIcon]
sub esp, 4
jmp 0x5415f7
mov eax, 1
jmp 0x5415ce
mov ecx, ebx
call eax
mov ebp, dword [sym.imp.USER32.dll_ShowWindow]
jmp 0x540e5e