Function at 0x40a370
Capabilities:
Get common file path
Query or enumerate registry value
Set current directory

Disassembly:
push 0xffffffffffffffff
push 0x46c63c
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x258
push ebx
push ebp
push esi
lea eax, [esp + 0x15c]
push edi
push eax
push 0x104
xor bl, bl
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov ebp, dword [esp + 0x278]
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], 0
push ecx
push 0x2001f
push 0
push str.SOFTWARE
push reloc.OLEAUT32.dll_SysReAllocString
mov byte [ebp], bl
mov edi, 0x20019
call esi
test eax, eax
jne 0x40a3f8
mov eax, dword [0x48c764]
mov edi, 0x2001f
cmp eax, 4
jne 0x40a435
mov dword [0x48c764], 0
jmp 0x40a435
lea edx, [esp + 0x24]
push edx
push 0x20019
push 0
push str.SOFTWARE
push reloc.OLEAUT32.dll_SysReAllocString
call esi
cmp dword [0x48c764], 4
jne 0x40a42d
test eax, eax
jne 0x40a943
mov dword [0x48c764], 3
jmp 0x40a435
test eax, eax
jne 0x40a943
lea eax, [esp + 0x54]
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x28]
push eax
mov esi, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
push ecx
push 0
push edi
push 0
push 0
push 0
push str.Adobe
push edx
mov dword [esp + 0x4c], 0
call esi
test eax, eax
jne 0x40a934
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x54]
mov edx, dword [esp + 0x28]
lea ecx, [esp + 0x2c]
push eax
push ecx
push 0
push edi
push 0
push 0
push 0
push str.CommonFiles
push edx
call esi
test eax, eax
jne 0x40a925
mov eax, dword [esp + 0x27c]
lea ecx, [esp + 0x58]
push eax
mov eax, dword [str.AdobeHome]
lea edx, [esp + 0x54]
push ecx
mov ecx, dword [esp + 0x34]
push edx
push 0
push eax
push ecx
mov dword [esp + 0x68], 1
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40a925
mov dl, byte [esp + 0x13]
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x18], dl
call fcn.00409470
lea edi, [esp + 0x58]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea eax, [esp + 0x58]
push ecx
push eax
lea ecx, [esp + 0x1c]
call fcn.0040ae20
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x270], 0
test eax, eax
je 0x40a7d6
mov edi, 0x483f30
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push eax
push 0x483f30
lea ecx, [esp + 0x20]
call fcn.0040ac30
lea ebx, [eax + 1]
mov eax, dword [esp + 0x1c]
test ebx, ebx
jle 0x40a743
cmp ebx, eax
ja 0x40a743
push ebx
lea ecx, [esp + 0x44]
push 0
push ecx
lea ecx, [esp + 0x20]
call fcn.0040aaa0
mov dl, byte [esp + 0x13]
push 0
lea ecx, [esp + 0x34]
mov byte [esp + 0x274], 1
mov byte [esp + 0x34], dl
call fcn.00409470
mov edi, 0x48c6f4
or ecx, 0xffffffff
xor eax, eax
push 1
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebp, ecx
lea ecx, [esp + 0x34]
push ebp
call fcn.00409600
test al, al
je 0x40a5b6
mov edi, dword [esp + 0x34]
mov ecx, ebp
mov eax, ecx
mov esi, 0x48c6f4
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x34]
call fcn.004095e0
mov eax, dword [esp + 0x48]
mov byte [esp + 0x270], 2
cmp eax, 1
jbe 0x40a651
mov esi, dword [esp + 0x278]
lea ecx, [esp + 0x40]
push ecx
push esi
call fcn.0040a980
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
add esp, 8
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 1
mov ebp, ecx
lea ecx, [esp + 0x34]
push ebp
call fcn.00409600
test al, al
je 0x40a61c
mov edi, dword [esp + 0x34]
mov ecx, ebp
mov edx, ecx
push ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x34]
call fcn.004095e0
mov eax, dword [0x471338]
mov ecx, dword [esp + 0x280]
push eax
push 0
push ecx
lea ecx, [esp + 0x3c]
call fcn.0040ad40
mov eax, dword [esp + 0x34]
test eax, eax
jne 0x40a642
mov eax, 0x471334
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
jne 0x40a8b2
lea ecx, [esp + 0x14]
mov edi, ebx
call fcn.00409a40
mov eax, dword [esp + 0x1c]
cmp eax, ebx
jae 0x40a666
mov edi, eax
test edi, edi
jbe 0x40a6a0
mov ecx, dword [esp + 0x18]
sub eax, edi
push eax
lea edx, [ecx + edi]
push edx
push ecx
call fcn.004336d0
mov esi, dword [esp + 0x28]
add esp, 0xc
sub esi, edi
lea ecx, [esp + 0x14]
push 0
push esi
call fcn.00409600
test al, al
je 0x40a6a0
mov edx, dword [esp + 0x18]
mov dword [esp + 0x1c], esi
mov byte [edx + esi], 0
lea ecx, [esp + 0x14]
call fcn.0040acc0
mov esi, dword [esp + 0x18]
lea ecx, [esp + 0x14]
call fcn.0040acc0
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40a6c4
mov ecx, dword [esp + 0x1c]
add eax, ecx
cmp esi, eax
je 0x40a6db
movsx edx, byte [esi]
push edx
call fcn.0043273f
add esp, 4
test eax, eax
jne 0x40a6db
inc esi
jmp 0x40a6ad
lea ecx, [esp + 0x14]
call fcn.0040acc0
mov edi, dword [esp + 0x18]
lea ecx, [esp + 0x14]
call fcn.0040acc0
test edi, edi
jne 0x40a6f9
xor ecx, ecx
jmp 0x40a701
mov eax, dword [esp + 0x18]
mov ecx, edi
sub ecx, eax
test esi, esi
jne 0x40a709
xor eax, eax
jmp 0x40a70d
sub esi, edi
mov eax, esi
push eax
push ecx
lea ecx, [esp + 0x1c]
call fcn.004094c0
push 1
lea ecx, [esp + 0x34]
mov byte [esp + 0x274], 1
call fcn.00409470
push 1
lea ecx, [esp + 0x44]
mov byte [esp + 0x274], 0
call fcn.00409470
jmp 0x40a7c3
mov ecx, dword [esp + 0x18]
mov ebp, dword [0x471338]
test ecx, ecx
je 0x40a789
mov dl, byte [ecx - 1]
test dl, dl
je 0x40a789
cmp dl, 0xff
je 0x40a789
mov esi, ecx
push 1
lea ecx, [esp + 0x18]
call fcn.00409470
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push esi
lea ecx, [esp + 0x1c]
call fcn.0040ae20
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
cmp eax, ebp
jae 0x40a78f
mov ebp, eax
test ebp, ebp
jbe 0x40a7c7
sub eax, ebp
lea edx, [ecx + ebp]
push eax
push edx
push ecx
call fcn.004336d0
mov esi, dword [esp + 0x28]
add esp, 0xc
sub esi, ebp
lea ecx, [esp + 0x14]
push 0
push esi
call fcn.00409600
test al, al
je 0x40a7c3
push esi
lea ecx, [esp + 0x18]
call fcn.004095e0
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x40a510
mov ebp, dword [esp + 0x278]
mov al, byte [0x48c760]
test al, 1
jne 0x40a854
mov cl, al
mov al, byte [esp + 0x13]
or cl, 1
push 0
mov byte [0x48c760], cl
mov ecx, 0x48c740
mov byte [0x48c740], al
call fcn.00409470
mov edi, 0x483f2c
or ecx, 0xffffffff
xor eax, eax
push 1
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebx, ecx
mov ecx, 0x48c740
push ebx
call fcn.00409600
test al, al
je 0x40a847
mov edi, dword [0x48c744]
mov ecx, ebx
mov edx, ecx
mov esi, 0x483f2c
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0x48c740
call fcn.004095e0
push 0x40aa50
call fcn.00431d88
add esp, 4
push 0x48c740
push ebp
call fcn.0040a980
mov eax, dword [esp + 0x288]
lea ecx, [esp + 0x48]
push eax
push ebp
push ecx
call fcn.0040aec0
add esp, 0x14
mov eax, dword [esp + 0x44]
mov byte [esp + 0x270], 3
test eax, eax
jne 0x40a88a
mov eax, 0x471334
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
jne 0x40a8db
mov eax, dword [esp + 0x44]
test eax, eax
jne 0x40a8a2
mov eax, 0x471334
push eax
call fcn.0040a030
add esp, 4
test al, al
setne bl
jmp 0x40a8dd
mov bl, 1
push 1
lea ecx, [esp + 0x34]
mov byte [esp + 0x274], bl
call fcn.00409470
push 1
lea ecx, [esp + 0x44]
mov byte [esp + 0x274], 0
call fcn.00409470
jmp 0x40a901
mov bl, 1
mov ecx, dword [esp + 0x44]
test ecx, ecx
je 0x40a901
mov al, byte [ecx - 1]
test al, al
je 0x40a8f7
cmp al, 0xff
je 0x40a8f7
dec al
mov byte [ecx - 1], al
jmp 0x40a901
dec ecx
push ecx
call fcn.00453071
add esp, 4
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x40a925
mov al, byte [ecx - 1]
test al, al
je 0x40a91b
cmp al, 0xff
je 0x40a91b
dec al
mov byte [ecx - 1], al
jmp 0x40a925
dec ecx
push ecx
call fcn.00453071
add esp, 4
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x40a934
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x40a943
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x24]
test eax, eax
je 0x40a952
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [esp + 0x160]
push edx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov ecx, dword [esp + 0x268]
pop edi
pop esi
mov al, bl
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x264
ret