Function at 0x682242
Capabilities:
Accept command line arguments
Check if file exists
Create process on windows
Delete file
Move file

Disassembly:
push 0x364
mov eax, 0x6a213d
call fcn.0049be90
mov esi, 0x750660
lea ecx, [ebp - 0x24]
xor ebx, ebx
push esi
mov byte [ebp - 0x19], bl
call fcn.004514db
push esi
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], ebx
call fcn.004514db
push esi
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 1
call fcn.004514db
xor esi, esi
mov byte [ebp - 4], 3
push ecx
inc esi
lea ecx, [ebp - 0x370]
mov dword [0x7af24c], esi
call fcn.00686368
push esi
mov byte [ebp - 4], 4
mov ecx, eax
push dword [0x7af24c]
call fcn.00685f8f
lea ecx, [ebp - 0x370]
mov byte [ebp - 0x1a], al
mov byte [ebp - 4], 3
call fcn.006862d9
cmp byte [0x7af234], bl
je 0x682676
cmp byte [ebp - 0x1a], bl
je 0x682676
lea ecx, [ebp - 0x20]
call fcn.00689cdf
push eax
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 5
call fcn.00451d78
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x20]
lea ecx, [ecx - 0x10]
call fcn.0044ec01
push 0x7557b8
push dword [ebp - 0x24]
mov edi, 0x751814
lea eax, [ebp - 0x14]
push edi
push eax
call fcn.00452465
add esp, 0x10
lea eax, [ebp - 0x20]
push eax
call fcn.0066fec3
mov byte [ebp - 4], 6
push dword [eax]
lea eax, [ebp - 0x18]
push dword [ebp - 0x24]
push edi
push eax
call fcn.00452465
mov byte [ebp - 4], 3
add esp, 0x10
mov ecx, dword [ebp - 0x20]
lea ecx, [ecx - 0x10]
call fcn.0044ec01
mov eax, dword [ebp - 0x18]
cmp dword [eax - 4], esi
jle 0x682351
push dword [eax - 0xc]
lea ecx, [ebp - 0x18]
call fcn.00451ca4
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x682399
mov eax, dword [ebp - 0x18]
cmp dword [eax - 4], esi
jle 0x682372
push dword [eax - 0xc]
lea ecx, [ebp - 0x18]
call fcn.00451ca4
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
call edi
push eax
push esi
push str.CJoinSessionApp::HandleSelfUpdateForLaunchappWorkflow
push str._s_::_Deleting_old_ConnectTemp_bRet_d_Err_d
call fcn.006778de
add esp, 0x10
jmp 0x68239f
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, dword [ebp - 0x18]
cmp dword [esi - 4], 1
jle 0x6823b6
push dword [esi - 0xc]
lea ecx, [ebp - 0x18]
call fcn.00451ca4
mov esi, dword [ebp - 0x18]
mov eax, dword [ebp - 0x14]
cmp dword [eax - 4], 1
jle 0x6823cd
push dword [eax - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov eax, dword [ebp - 0x14]
push esi
push eax
call fcn.00512407
pop ecx
pop ecx
push dword [ebp - 0x14]
mov esi, eax
push dword [ebp - 0x18]
push esi
call edi
push eax
push str.File_rename__d__d____s_:__s
call fcn.006778de
add esp, 0x14
test esi, esi
jne 0x6826b6
mov eax, dword [0x7af21c]
cmp dword [eax - 4], 1
jle 0x682414
push dword [eax - 0xc]
mov ecx, 0x7af21c
call fcn.00451ca4
mov eax, dword [0x7af21c]
push 0x7530
push 0xea60
push 2
push 1
push dword [0x7af230]
lea ecx, [ebp - 0x138]
push eax
call fcn.0067ec5b
mov byte [ebp - 4], 7
mov esi, dword [ebp - 0x14]
cmp dword [esi - 4], 1
jle 0x68244f
push dword [esi - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov esi, dword [ebp - 0x14]
mov eax, dword [0x7af224]
cmp dword [eax - 4], 1
jle 0x68246c
push dword [eax - 0xc]
mov ecx, 0x7af224
call fcn.00451ca4
mov eax, dword [0x7af224]
push ebx
push ebx
push esi
push eax
lea ecx, [ebp - 0x138]
call fcn.0067cf02
test eax, eax
je 0x682520
mov eax, dword [0x7af210]
cmp dword [eax - 4], 1
jle 0x6824a0
push dword [eax - 0xc]
mov ecx, 0x7af210
call fcn.00451ca4
mov eax, dword [0x7af210]
push 0x7530
push 0xea60
push 2
push 1
push dword [0x7af230]
lea ecx, [ebp - 0xb0]
push eax
call fcn.0067ec5b
mov byte [ebp - 4], 8
mov esi, dword [ebp - 0x14]
cmp dword [esi - 4], 1
jle 0x6824db
push dword [esi - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov esi, dword [ebp - 0x14]
mov eax, dword [0x7af218]
cmp dword [eax - 4], 1
jle 0x6824f8
push dword [eax - 0xc]
mov ecx, 0x7af218
call fcn.00451ca4
mov eax, dword [0x7af218]
push ebx
push ebx
push esi
push eax
lea ecx, [ebp - 0xb0]
call fcn.0067cf02
lea ecx, [ebp - 0xb0]
mov byte [ebp - 4], 7
mov esi, eax
call fcn.0067ec50
test esi, esi
jne 0x68260a
mov eax, dword [ebp - 0x14]
xor esi, esi
inc esi
cmp dword [eax - 4], esi
jle 0x682539
push dword [eax - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x68260a
mov ecx, dword [ebp - 0x14]
cmp dword [ecx - 4], esi
jle 0x68255e
push dword [ecx - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov ecx, dword [ebp - 0x14]
push esi
xor dl, dl
call fcn.0068a223
pop ecx
test al, al
je 0x68260a
call fcn.00474f38
push eax
lea ecx, [ebp - 0x20]
call fcn.00451c1b
mov byte [ebp - 4], 9
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
lea eax, [ebp - 0x20]
push str._Relaunched_instance_true__s
push eax
call fcn.00452465
add esp, 0xc
lea eax, [ebp - 0x28]
push eax
call fcn.0066ff9b
push esi
push dword [ebp - 0x24]
mov esi, dword [ebp - 0x20]
push esi
push dword [eax]
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov ecx, dword [ebp - 0x28]
mov edi, eax
lea ecx, [ecx - 0x10]
call fcn.0044ec01
lea eax, [ebp - 0x28]
push eax
call fcn.0066ff9b
push edi
push esi
mov byte [ebp - 4], 0xa
push dword [eax]
push str.CJoinSessionApp::HandleSelfUpdateForLaunchappWorkflow
push str._s___ShellExecute_status___app:_s_cmd:_s_Ret_d
call fcn.00677869
mov ecx, dword [ebp - 0x28]
add esp, 0x14
lea ecx, [ecx - 0x10]
call fcn.0044ec01
cmp edi, 0x20
lea ecx, [esi - 0x10]
setg bl
mov byte [ebp - 0x19], bl
call fcn.0044ec01
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [ebp - 0x138]
mov byte [ebp - 4], 3
call fcn.0067ec50
test bl, bl
jne 0x6826b6
mov esi, dword [ebp - 0x14]
cmp dword [esi - 4], 1
jle 0x682638
push dword [esi - 0xc]
lea ecx, [ebp - 0x14]
call fcn.00451ca4
mov esi, dword [ebp - 0x14]
mov eax, dword [ebp - 0x18]
cmp dword [eax - 4], 1
jle 0x68264f
push dword [eax - 0xc]
lea ecx, [ebp - 0x18]
call fcn.00451ca4
mov eax, dword [ebp - 0x18]
push esi
push eax
call fcn.00512407
pop ecx
pop ecx
push dword [ebp - 0x14]
push dword [ebp - 0x18]
push eax
call edi
push eax
push str.CJoinSessionApp::HandleSelfUpdateForLaunchappWorkflow
push str._s_::_Fresh_connect_download_failed__reverting_rename_lasterror:_d__Res:_d____s_:__s
call fcn.006778de
add esp, 0x18
jmp 0x6826b6
push str.CJoinSessionApp::HandleSelfUpdateForLaunchappWorkflow
push str._s_::_App_is_uptodate__proceeding_for_join_session_via_launchapp_flow
call fcn.006778de
xor eax, eax
cmp byte [0x7af250], al
pop ecx
sete al
add eax, 2
pop ecx
mov dword [0x7af24c], eax
jmp 0x6826b6
mov ecx, dword [ebp - 0x14]
lea ecx, [ecx - 0x10]
call fcn.0044ec01
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
call fcn.0044ec01
mov ecx, dword [ebp - 0x24]
add ecx, 0xfffffff0
call fcn.0044ec01
mov al, bl
call fcn.0049bdee
ret