Function at 0x417955
Capabilities:
Check if file exists
Delete file
Move file

Disassembly:
sub esp, 0x18
push ebx
push ebp
push esi
mov bl, cl
mov bh, dl
push edi
lea ecx, [esp + 0x1c]
call fcn.00417006
test bl, bl
je 0x417a34
push 0
lea ecx, [esp + 0x20]
call fcn.00402642
push eax
lea ecx, [esp + 0x38]
call fcn.0040580b
test eax, eax
jne 0x417a34
lea ecx, [esp + 0x14]
call fcn.00402286
lea ecx, [esp + 0x18]
call fcn.00402286
lea eax, [esp + 0x20]
push eax
call fcn.0040b5ac
mov esi, 0x49a36c
push dword [eax]
lea eax, [esp + 0x18]
push dword [esp + 0x20]
push esi
push eax
call fcn.0040289a
add esp, 0x10
lea ecx, [esp + 0x20]
call fcn.0040223f
lea eax, [esp + 0x20]
push eax
call fcn.0040b504
push dword [eax]
lea eax, [esp + 0x1c]
push dword [esp + 0x20]
push esi
push eax
call fcn.0040289a
add esp, 0x10
lea ecx, [esp + 0x20]
call fcn.0040223f
lea ecx, [esp + 0x14]
call fcn.0040590f
push eax
lea ecx, [esp + 0x1c]
call fcn.0040590f
push eax
call fcn.00466761
push dword [esp + 0x20]
push dword [esp + 0x20]
push eax
push str.File_rename__d__s_:__s
call fcn.0041c596
add esp, 0x18
lea ecx, [esp + 0x18]
call fcn.0040223f
lea ecx, [esp + 0x14]
call fcn.0040223f
lea ecx, [esp + 0x18]
call fcn.00402286
lea ecx, [esp + 0x14]
call fcn.00402286
mov ebp, fcn.00462f9e
test bh, bh
je 0x417b17
lea eax, [esp + 0x24]
push eax
call fcn.0040b49b
mov esi, eax
lea eax, [esp + 0x20]
push eax
call fcn.0040b41d
push dword [esi]
mov edi, str._s_s_s
push dword [eax]
lea eax, [esp + 0x20]
push dword [esp + 0x38]
push edi
push eax
call fcn.0040289a
add esp, 0x14
lea ecx, [esp + 0x20]
call fcn.0040223f
lea ecx, [esp + 0x24]
call fcn.0040223f
lea eax, [esp + 0x20]
push eax
call fcn.0040b597
mov esi, eax
lea eax, [esp + 0x24]
push eax
call fcn.0040b41d
push dword [esi]
push dword [eax]
lea eax, [esp + 0x1c]
push dword [esp + 0x38]
push edi
push eax
call fcn.0040289a
add esp, 0x14
lea ecx, [esp + 0x24]
call fcn.0040223f
lea ecx, [esp + 0x20]
call fcn.0040223f
lea ecx, [esp + 0x14]
call fcn.0040590f
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push str.ReplaceFilesInAppFolder:_Renaming_ZohoTray.exe_to_temp__for_update.
call fcn.0041c6f8
pop ecx
lea ecx, [esp + 0x14]
call fcn.0040590f
push eax
lea ecx, [esp + 0x1c]
call fcn.0040590f
push eax
call fcn.00466761
push ebp
push eax
push 0x4ae000
call fcn.0041c6f8
add esp, 0x14
cmp dword [esp + 0x34], 1
jne 0x417b73
lea ecx, [esp + 0x2c]
call fcn.00402642
push eax
lea ecx, [esp + 0x24]
call fcn.00406e64
lea ecx, [esp + 0x30]
call fcn.00402642
push eax
lea ecx, [esp + 0x38]
call fcn.00406e64
lea ecx, [esp + 0x34]
call fcn.00402b7c
push eax
lea ecx, [esp + 0x24]
call fcn.00402b7c
mov edx, eax
call fcn.00428bc0
pop ecx
lea ecx, [esp + 0x34]
call fcn.0040223f
lea ecx, [esp + 0x20]
call fcn.0040223f
jmp 0x417b90
lea ecx, [esp + 0x30]
call fcn.0040590f
lea ecx, [esp + 0x2c]
mov esi, eax
call fcn.0040590f
mov edx, esi
mov ecx, eax
call fcn.004172e5
test bh, bh
je 0x417bdb
lea ecx, [esp + 0x18]
call fcn.0040590f
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x417bdb
push str.ReplaceFilesInAppFolder:_Zip_extracted_but_ZohoTray_exe_is_not_found._Renaming_previous_temp_exe_to_original_file.
call fcn.0041c68c
pop ecx
lea ecx, [esp + 0x18]
call fcn.0040590f
push eax
lea ecx, [esp + 0x18]
call fcn.0040590f
push eax
call fcn.00466761
push ebp
push eax
push str.ReplaceFilesInAppFolder:_Reverting_rename_operation_result:__d._Error:__d
call fcn.0041c6f8
add esp, 0x14
push 0
lea ecx, [esp + 0x30]
call fcn.004022af
push eax
call fcn.0046305b
pop ecx
lea ecx, [esp + 0x14]
call fcn.0040223f
lea ecx, [esp + 0x18]
call fcn.0040223f
lea ecx, [esp + 0x1c]
call fcn.0040223f
lea ecx, [esp + 0x2c]
call fcn.0040223f
lea ecx, [esp + 0x30]
call fcn.0040223f
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x18
ret