Function at 0x401770
Capabilities:
Check if file exists
Delete file
Get file attributes
Query environment variable
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x431101
mov eax, dword fs:[0]
push eax
sub esp, 0x98c
mov eax, dword [0x448034]
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
mov edi, edx
mov dword [ebp - 0x988], edi
mov esi, ecx
lea ecx, [ebp - 0x984]
call fcn.0041a020
push 0x436b78
lea edx, [ebp - 0x984]
lea ecx, [ebp - 0x90c]
mov dword [ebp - 4], 0
call fcn.004036e0
add esp, 4
push str.twslogs_
lea edx, [ebp - 0x984]
lea ecx, [ebp - 0x954]
mov byte [ebp - 4], 1
call fcn.004036e0
add esp, 4
xor eax, eax
push 0xffffffffffffffff
mov byte [ebp - 4], 2
push eax
push esi
lea ecx, [ebp - 0x87c]
mov dword [ebp - 0x868], 7
mov dword [ebp - 0x86c], 0
mov word [ebp - 0x87c], ax
call fcn.00402bb0
mov byte [ebp - 4], 3
cmp dword [ebp - 0x86c], 0
mov esi, dword [sym.imp.MSVCR110.dll_void___cdecl_operator_delete_void__]
jne 0x4018af
push str.bugreport.zip
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x864]
call fcn.004036e0
mov edi, eax
lea eax, [ebp - 0x87c]
add esp, 4
cmp eax, edi
je 0x401895
cmp dword [ebp - 0x868], 8
jb 0x40186c
push dword [ebp - 0x87c]
call esi
add esp, 4
xor eax, eax
push edi
lea ecx, [ebp - 0x87c]
mov dword [ebp - 0x868], 7
mov dword [ebp - 0x86c], 0
mov word [ebp - 0x87c], ax
call fcn.00402b50
cmp dword [ebp - 0x850], 8
jb 0x4018a9
push dword [ebp - 0x864]
call esi
add esp, 4
mov edi, dword [ebp - 0x988]
mov dword [ebp - 0x8e0], 0xf
mov dword [ebp - 0x8e4], 0
mov byte [ebp - 0x8f4], 0
lea ecx, [ebp - 0x8f4]
mov byte [ebp - 4], 4
call fcn.00415190
cmp byte [ebp + 8], 0
jne 0x401a07
mov dword [ebp - 0x850], 0xf
mov dword [ebp - 0x854], 0
mov byte [ebp - 0x864], 0
lea ecx, [ebp - 0x864]
mov byte [ebp - 4], 5
call fcn.00415a60
mov dword [ebp - 0x838], 0xf
mov dword [ebp - 0x83c], 0
mov byte [ebp - 0x84c], 0
mov dl, 1
lea ecx, [ebp - 0x84c]
mov byte [ebp - 4], 6
call fcn.004158f0
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x8f4]
push eax
lea ecx, [ebp - 0x864]
call fcn.00402930
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x84c]
push eax
lea ecx, [ebp - 0x864]
call fcn.00402930
lea ecx, [ebp - 0x864]
call fcn.004015b0
test al, al
jne 0x4019c0
cmp dword [ebp - 0x838], 0x10
jb 0x401988
push dword [ebp - 0x84c]
call esi
add esp, 4
cmp dword [ebp - 0x850], 0x10
mov dword [ebp - 0x838], 0xf
mov dword [ebp - 0x83c], 0
mov byte [ebp - 0x84c], 0
jb 0x4022f9
push dword [ebp - 0x864]
call esi
add esp, 4
jmp 0x4022f9
cmp dword [ebp - 0x838], 0x10
jb 0x4019d4
push dword [ebp - 0x84c]
call esi
add esp, 4
mov byte [ebp - 4], 4
cmp dword [ebp - 0x850], 0x10
mov dword [ebp - 0x838], 0xf
mov dword [ebp - 0x83c], 0
mov byte [ebp - 0x84c], 0
jb 0x401a07
push dword [ebp - 0x864]
call esi
add esp, 4
push str.serviceInfo.log
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x894]
call fcn.004036e0
add esp, 4
mov dword [ebp - 0x910], 0xf
mov dword [ebp - 0x914], 0
mov byte [ebp - 0x924], 0
xor dl, dl
lea ecx, [ebp - 0x924]
mov byte [ebp - 4], 8
call fcn.004158f0
lea edx, [ebp - 0x924]
lea ecx, [ebp - 0x894]
call fcn.004012e0
push str.browserInfo.log
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x8dc]
call fcn.004036e0
add esp, 4
lea edx, [ebp - 0x8f4]
lea ecx, [ebp - 0x8dc]
mov byte [ebp - 4], 9
call fcn.004012e0
push 0
push 0x436adc
lea ecx, [ebp - 0x8f4]
call fcn.00402da0
push str.systemInfo.log
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x8c4]
call fcn.004036e0
add esp, 4
lea ecx, [ebp - 0x8f4]
mov byte [ebp - 4], 0xa
call fcn.004154e0
lea edx, [ebp - 0x8f4]
lea ecx, [ebp - 0x8c4]
call fcn.004012e0
push 0
push 0x436adc
lea ecx, [ebp - 0x8f4]
call fcn.00402da0
push str.processInfo.log
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x8ac]
call fcn.004036e0
mov dword [ebp - 0x928], 0xf
mov dword [ebp - 0x92c], 0
mov byte [ebp - 0x93c], 0
mov dword [ebp - 0x958], 0xf
mov dword [ebp - 0x95c], 0
mov byte [ebp - 0x96c], 0
lea ecx, [ebp - 0x93c]
mov byte [ebp - 4], 0xd
call fcn.004152f0
add esp, 4
lea edx, [ebp - 0x93c]
lea ecx, [ebp - 0x8ac]
call fcn.004012e0
push 0
push 0x436adc
lea ecx, [ebp - 0x8f4]
call fcn.00402da0
cmp dword [ebp - 0x868], 8
mov ebx, dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, dword [ebp - 0x87c]
jb 0x401b86
mov eax, ecx
test ecx, ecx
je 0x401bdb
jmp 0x401b8c
lea eax, [ebp - 0x87c]
cmp word [eax], 0
je 0x401bdb
push eax
call ebx
cmp eax, 0xffffffff
je 0x401bd5
cmp dword [ebp - 0x868], 8
lea eax, [ebp - 0x87c]
cmovae eax, dword [ebp - 0x87c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp dword [ebp - 0x868], 8
lea eax, [ebp - 0x87c]
cmovae eax, dword [ebp - 0x87c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, dword [ebp - 0x87c]
mov dword [ebp - 0x834], 0
mov byte [ebp - 4], 0xe
cmp dword [ebp - 0x868], 8
push ecx
lea eax, [ebp - 0x87c]
cmovae eax, ecx
push eax
push ecx
lea ecx, [ebp - 0x834]
call fcn.0041ac10
test al, al
je 0x402174
cmp byte [ebp + 0xc], 0
lea ecx, [ebp - 0x834]
jne 0x401e45
cmp dword [ebp - 0x8f8], 8
lea eax, [ebp - 0x90c]
cmovae eax, dword [ebp - 0x90c]
sub esp, 8
push eax
call fcn.0041ad70
cmp dword [ebp - 0x940], 8
lea eax, [ebp - 0x954]
cmovae eax, dword [ebp - 0x954]
sub esp, 8
lea ecx, [ebp - 0x834]
push eax
call fcn.0041ad70
push 0x14
xor eax, eax
push str._appdata_isafelog_
lea ecx, [ebp - 0x864]
mov dword [ebp - 0x850], 7
mov dword [ebp - 0x854], 0
mov word [ebp - 0x864], ax
call fcn.00402fc0
mov byte [ebp - 4], 0xf
cmp dword [ebp - 0x850], 8
push 0x410
lea ecx, [ebp - 0x830]
lea eax, [ebp - 0x864]
cmovae eax, dword [ebp - 0x864]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x401cd9
cmp eax, 0x410
ja 0x401cd9
sub esp, 8
lea eax, [ebp - 0x830]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad70
mov byte [ebp - 4], 0xe
cmp dword [ebp - 0x850], 8
jb 0x401cf1
push dword [ebp - 0x864]
call esi
add esp, 4
mov edi, dword [edi]
xor ecx, ecx
mov dword [ebp - 0x990], ecx
mov ecx, dword [ebp - 0x988]
mov eax, 0x2aaaaaab
mov ecx, dword [ecx + 4]
sub ecx, edi
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x401fb4
xor eax, eax
mov dword [ebp - 0x98c], eax
xor ecx, ecx
push 0xffffffffffffffff
push ecx
add eax, edi
mov word [ebp - 0x84c], cx
push eax
lea ecx, [ebp - 0x84c]
mov dword [ebp - 0x838], 7
mov dword [ebp - 0x83c], 0
call fcn.00402bb0
mov byte [ebp - 4], 0x10
cmp dword [ebp - 0x838], 8
mov edx, dword [ebp - 0x84c]
jb 0x401d72
mov eax, edx
test edx, edx
je 0x401df0
jmp 0x401d78
lea eax, [ebp - 0x84c]
cmp word [eax], 0
je 0x401df0
push eax
call ebx
cmp eax, 0xffffffff
je 0x401dea
cmp dword [ebp - 0x838], 8
mov edx, dword [ebp - 0x84c]
jb 0x401d9d
mov edi, edx
test edx, edx
je 0x401df0
jmp 0x401da3
lea edi, [ebp - 0x84c]
mov eax, edi
lea ecx, [eax + 2]
mov dword [ebp - 0x994], ecx
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401db0
sub eax, dword [ebp - 0x994]
sar eax, 1
je 0x401df0
cmp word [edi], cx
je 0x401df0
push edi
call ebx
cmp eax, 0xffffffff
je 0x401dea
push edi
push edi
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
mov ecx, dword [ebp - 0x834]
mov edx, eax
call fcn.0042b800
add esp, 4
mov edx, dword [ebp - 0x84c]
mov byte [ebp - 4], 0xe
cmp dword [ebp - 0x838], 8
jb 0x401e03
push edx
call esi
add esp, 4
mov eax, dword [ebp - 0x988]
inc dword [ebp - 0x990]
mov edi, dword [eax]
mov ecx, dword [eax + 4]
add dword [ebp - 0x98c], 0x18
sub ecx, edi
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp dword [ebp - 0x990], eax
mov eax, dword [ebp - 0x98c]
jb 0x401d25
jmp 0x401fb4
cmp dword [ebp - 0x880], 8
lea eax, [ebp - 0x894]
cmovae eax, dword [ebp - 0x894]
push eax
call fcn.0041ad10
cmp dword [ebp - 0x8c8], 8
lea eax, [ebp - 0x8dc]
cmovae eax, dword [ebp - 0x8dc]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad10
cmp dword [ebp - 0x8b0], 8
lea eax, [ebp - 0x8c4]
cmovae eax, dword [ebp - 0x8c4]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad10
cmp dword [ebp - 0x898], 8
lea eax, [ebp - 0x8ac]
cmovae eax, dword [ebp - 0x8ac]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad10
push str.iSafeSvc.LOG
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x864]
call fcn.004036e0
add esp, 4
mov byte [ebp - 4], 0x11
cmp dword [ebp - 0x850], 8
lea ecx, [ebp - 0x864]
cmovae ecx, dword [ebp - 0x864]
call fcn.00406410
push str.iSafeSvc2.LOG
lea edx, [ebp - 0x90c]
lea ecx, [ebp - 0x84c]
call fcn.004036e0
add esp, 4
mov byte [ebp - 4], 0x12
cmp dword [ebp - 0x838], 8
lea ecx, [ebp - 0x84c]
cmovae ecx, dword [ebp - 0x84c]
call fcn.00406410
cmp dword [ebp - 0x850], 8
lea eax, [ebp - 0x864]
cmovae eax, dword [ebp - 0x864]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad10
cmp dword [ebp - 0x838], 8
lea eax, [ebp - 0x84c]
cmovae eax, dword [ebp - 0x84c]
push eax
lea ecx, [ebp - 0x834]
call fcn.0041ad10
cmp dword [ebp - 0x838], 8
jb 0x401f7f
push dword [ebp - 0x84c]
call esi
add esp, 4
xor eax, eax
mov byte [ebp - 4], 0xe
cmp dword [ebp - 0x850], 8
mov dword [ebp - 0x838], 7
mov dword [ebp - 0x83c], 0
mov word [ebp - 0x84c], ax
jb 0x401fb4
push dword [ebp - 0x864]
call esi
add esp, 4
mov ecx, dword [ebp - 0x834]
test ecx, ecx
je 0x401fe4
cmp dword [ecx], 1
sete al
test al, al
je 0x401fcf
call fcn.004273c0
jmp 0x401fda
mov ecx, dword [ebp - 0x834]
call fcn.0042b850
mov dword [ebp - 0x834], 0
cmp dword [ebp - 0x8b0], 8
jb 0x402016
mov eax, dword [ebp - 0x8c4]
test eax, eax
jne 0x40201c
mov edi, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp dword [ebp - 0x8c8], 8
jb 0x402069
mov eax, dword [ebp - 0x8dc]
test eax, eax
je 0x4020b4
jmp 0x40206f
lea eax, [ebp - 0x8c4]
cmp word [eax], 0
je 0x401ff7
push eax
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp eax, 0xffffffff
je 0x401ffd
cmp dword [ebp - 0x8b0], 8
lea eax, [ebp - 0x8c4]
cmovae eax, dword [ebp - 0x8c4]
push 0x80
push eax
call edi
cmp dword [ebp - 0x8b0], 8
lea eax, [ebp - 0x8c4]
cmovae eax, dword [ebp - 0x8c4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x401ffd
lea eax, [ebp - 0x8dc]
cmp word [eax], 0
je 0x4020b4
push eax
call ebx
cmp eax, 0xffffffff
je 0x4020b4
cmp dword [ebp - 0x8c8], 8
lea eax, [ebp - 0x8dc]
cmovae eax, dword [ebp - 0x8dc]
push 0x80
push eax
call edi
cmp dword [ebp - 0x8c8], 8
lea eax, [ebp - 0x8dc]
cmovae eax, dword [ebp - 0x8dc]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [ebp - 0x898], 8
jb 0x4020c9
mov eax, dword [ebp - 0x8ac]
test eax, eax
je 0x402114
jmp 0x4020cf
lea eax, [ebp - 0x8ac]
cmp word [eax], 0
je 0x402114
push eax
call ebx
cmp eax, 0xffffffff
je 0x402114
cmp dword [ebp - 0x898], 8
lea eax, [ebp - 0x8ac]
cmovae eax, dword [ebp - 0x8ac]
push 0x80
push eax
call edi
cmp dword [ebp - 0x898], 8
lea eax, [ebp - 0x8ac]
cmovae eax, dword [ebp - 0x8ac]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [ebp - 0x880], 8
jb 0x402129
mov eax, dword [ebp - 0x894]
test eax, eax
je 0x402174
jmp 0x40212f
lea eax, [ebp - 0x894]
cmp word [eax], 0
je 0x402174
push eax
call ebx
cmp eax, 0xffffffff
je 0x402174
cmp dword [ebp - 0x880], 8
lea eax, [ebp - 0x894]
cmovae eax, dword [ebp - 0x894]
push 0x80
push eax
call edi
cmp dword [ebp - 0x880], 8
lea eax, [ebp - 0x894]
cmovae eax, dword [ebp - 0x894]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov byte [ebp - 4], 0xd
mov ecx, dword [ebp - 0x834]
test ecx, ecx
je 0x4021a8
cmp dword [ecx], 1
sete al
test al, al
je 0x402193
call fcn.004273c0
jmp 0x40219e
mov ecx, dword [ebp - 0x834]
call fcn.0042b850
mov dword [ebp - 0x834], 0
cmp dword [ebp - 0x958], 0x10
jb 0x4021bc
push dword [ebp - 0x96c]
call esi
add esp, 4
cmp dword [ebp - 0x928], 0x10
mov dword [ebp - 0x958], 0xf
mov dword [ebp - 0x95c], 0
mov byte [ebp - 0x96c], 0
jb 0x4021eb
push dword [ebp - 0x93c]
call esi
add esp, 4
cmp dword [ebp - 0x898], 8
mov dword [ebp - 0x928], 0xf
mov dword [ebp - 0x92c], 0
mov byte [ebp - 0x93c], 0
jb 0x40221a
push dword [ebp - 0x8ac]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x8b0], 8
mov dword [ebp - 0x898], 7
mov dword [ebp - 0x89c], 0
mov word [ebp - 0x8ac], ax
jb 0x40224b
push dword [ebp - 0x8c4]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x8c8], 8
mov dword [ebp - 0x8b0], 7
mov dword [ebp - 0x8b4], 0
mov word [ebp - 0x8c4], ax
jb 0x40227c
push dword [ebp - 0x8dc]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x910], 0x10
mov dword [ebp - 0x8c8], 7
mov dword [ebp - 0x8cc], 0
mov word [ebp - 0x8dc], ax
jb 0x4022ad
push dword [ebp - 0x924]
call esi
add esp, 4
cmp dword [ebp - 0x880], 8
mov dword [ebp - 0x910], 0xf
mov dword [ebp - 0x914], 0
mov byte [ebp - 0x924], 0
jb 0x4022dc
push dword [ebp - 0x894]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x880], 7
mov dword [ebp - 0x884], 0
mov word [ebp - 0x894], ax
cmp dword [ebp - 0x8e0], 0x10
jb 0x40230d
push dword [ebp - 0x8f4]
call esi
add esp, 4
cmp dword [ebp - 0x868], 8
mov dword [ebp - 0x8e0], 0xf
mov dword [ebp - 0x8e4], 0
mov byte [ebp - 0x8f4], 0
jb 0x40233c
push dword [ebp - 0x87c]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x940], 8
mov dword [ebp - 0x868], 7
mov dword [ebp - 0x86c], 0
mov word [ebp - 0x87c], ax
jb 0x40236d
push dword [ebp - 0x954]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x8f8], 8
mov dword [ebp - 0x940], 7
mov dword [ebp - 0x944], 0
mov word [ebp - 0x954], ax
jb 0x40239e
push dword [ebp - 0x90c]
call esi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x970], 8
mov dword [ebp - 0x8f8], 7
mov dword [ebp - 0x8fc], 0
mov word [ebp - 0x90c], ax
jb 0x4023cf
push dword [ebp - 0x984]
call esi
add esp, 4
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.0042ef5e
mov esp, ebp
pop ebp
ret