Function at 0x10009850
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100444de
mov eax, dword fs:[0]
push eax
sub esp, 0x11c
mov eax, dword [0x1005d0b4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
call fcn.10009f80
mov ecx, eax
test ecx, ecx
je 0x10009898
mov eax, dword [ecx]
mov eax, dword [eax + 0xc]
call eax
test al, al
jne 0x10009ee2
push 0xd
xor eax, eax
mov dword [ebp - 0xa4], 7
push str.WinPetrNs.exe
lea ecx, [ebp - 0xb8]
mov dword [ebp - 0xa8], 0
mov word [ebp - 0xb8], ax
call fcn.100027f0
push 0xc
xor eax, eax
mov dword [ebp - 4], 0
push str.WinTpwer.exe
lea ecx, [ebp - 0x70]
mov dword [ebp - 0x5c], 7
mov dword [ebp - 0x60], 0
mov word [ebp - 0x70], ax
call fcn.100027f0
cmp dword [ebp - 0xa8], 0
mov byte [ebp - 4], 1
je 0x10009e9b
cmp dword [ebp - 0x60], 0
je 0x10009e9b
call fcn.10009f00
mov ecx, eax
call fcn.100068d0
test al, al
jne 0x10009e9b
call fcn.10009f00
mov ecx, eax
call fcn.10006760
test al, al
jne 0x10009e9b
push 0
call fcn.100339b6
add esp, 4
mov esi, eax
push 1
push str.08b675
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10004f20
test eax, eax
jne 0x100099ef
call fcn.10009f00
mov ecx, eax
call fcn.100068a0
test al, al
jne 0x100099ef
push 0
push str.219d64
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10004f20
mov edi, eax
cmp edi, 0x64
jg 0x100099ef
push 0
push str.b96d63
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10004f20
mov ecx, esi
sub ecx, eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
cmp eax, 0x708
jl 0x100099d3
lea eax, [edi + 1]
push eax
push str.219d64
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10007570
push esi
push str.b96d63
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10007570
jmp 0x10009e9b
cmp byte [ebp + 8], 0
jne 0x10009a3a
push 0xffffffffffffffff
push str.2a4fe3
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10004f20
mov ecx, esi
sub ecx, eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
cmp eax, 0x708
jle 0x10009e9b
push esi
push str.2a4fe3
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10007570
xor eax, eax
mov dword [ebp - 0x74], 7
mov dword [ebp - 0x78], 0
mov word [ebp - 0x88], ax
mov dword [ebp - 0x2c], 7
mov dword [ebp - 0x30], eax
mov word [ebp - 0x40], ax
push eax
push str.66918c
push str.Setting
mov byte [ebp - 4], 3
mov byte [ebp - 0x119], al
call fcn.10009f00
mov ecx, eax
call fcn.10004f20
mov ebx, eax
lea ecx, [ebp - 0x88]
test bl, 1
jne 0x10009aa5
push str.WinPetrNs.exe
mov byte [ebp - 0x119], 1
call fcn.10001750
push str.6b4fa8
jmp 0x10009ab4
push str.WinTpwer.exe
call fcn.10001750
push str.9f10f3
lea ecx, [ebp - 0x40]
call fcn.10001750
call fcn.10009f00
mov ecx, eax
call fcn.10004e90
push eax
lea ecx, [ebp - 0x118]
call fcn.10001390
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x88]
mov byte [ebp - 4], 4
push eax
lea ecx, [ebp - 0x118]
call fcn.10002260
lea ecx, [ebx + 1]
xor eax, eax
cmp ecx, 0x3e8
cmovl eax, ecx
push eax
push str.66918c
push str.Setting
call fcn.10009f00
mov ecx, eax
call fcn.10007570
cmp dword [ebp - 0x78], 0
je 0x10009e7d
call fcn.10013270
test al, al
je 0x10009b43
pop esp
pop ebx
push edx
pop ebx
pop ecx
push edx
push eax
push ebx
pop eax
pop edi
pop edi
push esi
push esp
push edx
push ecx
pop ecx
push ebx
pop edi
pop ebx
push esp
pop ebp
pop esi
pop eax
pop esp
push eax
pop eax
push edx
pop eax
push ebp
call fcn.10013ac0
test al, al
je 0x10009b65
pop eax
pop ecx
push eax
pop ebp
push edx
push ebp
pop eax
pop esp
pop ebp
push edi
pop ebx
pop ebx
pop edi
push ecx
push ebp
push esp
push eax
push esp
pop eax
pop edi
pop ebx
pop edi
push esi
push edx
pop esi
call fcn.100134a0
test al, al
je 0x10009b8a
pop eax
pop ecx
pop ebp
pop ecx
pop ecx
push ebx
pop eax
pop edx
pop edx
push esi
pop eax
pop esi
pop ebx
pop esp
pop eax
push ebx
pop ebp
push esi
pop ebp
push edi
push edx
pop edi
pop ecx
push ebp
push esp
push esi
pop edi
push ebp
lea eax, [ebp - 0x88]
push eax
lea ecx, [ebp - 0x58]
call fcn.10002dd0
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
mov byte [ebp - 4], 5
cmovae eax, dword [ebp - 0x58]
push eax
call fcn.1000c9f0
add esp, 4
test eax, eax
jne 0x10009e75
lea eax, [ebp - 0x118]
push eax
lea ecx, [ebp - 0x28]
call fcn.10002dd0
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 6
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x10009c0e
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x40]
lea eax, [ebp - 0x28]
cmovae ecx, dword [ebp - 0x40]
cmp dword [ebp - 0x14], 8
push ecx
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.10009f00
mov ecx, eax
call fcn.10012270
test eax, eax
jne 0x10009e6d
push str.955073594836064150654840111030516802483242582424
lea ecx, [ebp - 0xe8]
call fcn.10002d70
cmp byte [ebp - 0x119], 0
lea ecx, [ebp - 0xe8]
mov byte [ebp - 4], 7
je 0x10009c38
push str.955073594836064150654840111030516802483242582424
jmp 0x10009c3d
push str.2467704612404722126856442820702228203147
call fcn.10003300
cmp dword [ebp - 0xd4], 0x10
lea eax, [ebp - 0xe8]
cmovae eax, dword [ebp - 0xe8]
push eax
lea eax, [ebp - 0x100]
push eax
call fcn.1000a8f0
add esp, 8
mov dword [ebp - 0x128], 0
mov dword [ebp - 0x124], 0
mov dword [ebp - 0x120], 0
push 0x100478a8
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 9
call fcn.10002d70
cmp dword [ebp - 0xec], 0x10
lea eax, [ebp - 0x100]
lea ecx, [ebp - 0xa0]
mov byte [ebp - 4], 0xa
cmovae eax, dword [ebp - 0x100]
push eax
call fcn.10002d70
lea eax, [ebp - 0x128]
mov byte [ebp - 4], 0xb
push eax
lea eax, [ebp - 0xd0]
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.1000dc50
add esp, 0xc
lea ecx, [ebp - 0xa0]
call fcn.10001600
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 9
call fcn.10001600
mov esi, dword [ebp - 0x128]
mov eax, dword [ebp - 0x124]
cmp esi, eax
je 0x10009e4c
nop dword [eax + eax]
cmp dword [esi + 0x14], 0x10
jb 0x10009d1a
mov eax, dword [esi]
jmp 0x10009d1c
mov eax, esi
push eax
lea ecx, [ebp - 0xd0]
call fcn.10002d70
lea eax, [ebp - 0xd0]
mov byte [ebp - 4], 0xc
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.1000e020
add esp, 8
lea ecx, [ebp - 0x58]
push eax
call fcn.100016d0
lea ecx, [ebp - 0xa0]
call fcn.10001640
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
cmovae eax, dword [ebp - 0x58]
push eax
call fcn.1000c9f0
add esp, 4
mov byte [ebp - 4], 9
lea ecx, [ebp - 0xd0]
call fcn.10001600
mov eax, dword [ebp - 0x124]
add esi, 0x18
cmp esi, eax
jne 0x10009d10
mov esi, dword [ebp - 0x128]
cmp esi, eax
je 0x10009e4c
cmp dword [esi + 0x14], 0x10
jb 0x10009d9e
mov eax, dword [esi]
jmp 0x10009da0
mov eax, esi
push eax
lea ecx, [ebp - 0xa0]
call fcn.10002d70
lea eax, [ebp - 0xa0]
mov byte [ebp - 4], 0xd
push eax
lea eax, [ebp - 0xd0]
push eax
call fcn.1000e020
add esp, 8
lea ecx, [ebp - 0x58]
push eax
call fcn.100016d0
lea ecx, [ebp - 0xd0]
call fcn.10001640
call fcn.10009f00
mov ecx, eax
call fcn.10004e90
push eax
lea ecx, [ebp - 0x28]
call fcn.10001750
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x58]
push eax
lea ecx, [ebp - 0x28]
call fcn.10002260
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x40]
lea eax, [ebp - 0x28]
cmovae ecx, dword [ebp - 0x40]
cmp dword [ebp - 0x14], 8
push ecx
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.10009f00
mov ecx, eax
call fcn.10012270
lea ecx, [ebp - 0xa0]
test eax, eax
jne 0x10009e47
mov byte [ebp - 4], 9
call fcn.10001600
add esi, 0x18
cmp esi, dword [ebp - 0x124]
jne 0x10009d94
jmp 0x10009e4c
call fcn.10001600
lea ecx, [ebp - 0x128]
call fcn.100030a0
lea ecx, [ebp - 0x100]
call fcn.10001600
lea ecx, [ebp - 0xe8]
call fcn.10001600
lea ecx, [ebp - 0x28]
call fcn.10001640
lea ecx, [ebp - 0x58]
call fcn.10001640
lea ecx, [ebp - 0x118]
call fcn.10001640
lea ecx, [ebp - 0x40]
call fcn.10001640
lea ecx, [ebp - 0x88]
call fcn.10001640
mov eax, dword [ebp - 0x5c]
cmp eax, 8
jb 0x10009eb0
inc eax
lea ecx, [ebp - 0x70]
push eax
push dword [ebp - 0x70]
call fcn.10002940
xor eax, eax
mov dword [ebp - 0x5c], 7
mov word [ebp - 0x70], ax
mov eax, dword [ebp - 0xa4]
mov dword [ebp - 0x60], 0
cmp eax, 8
jb 0x10009ee2
inc eax
lea ecx, [ebp - 0xb8]
push eax
push dword [ebp - 0xb8]
call fcn.10002940
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.100157fc
mov esp, ebp
pop ebp
ret 4