Function at 0x462850
Capabilities:
Check if file exists
Delete file
Get common file path
Get file attributes
Write file on windows

Disassembly:
push edi
lea edi, [esp + 8]
and esp, 0xfffffff8
push dword [edi - 4]
push ebp
mov ebp, esp
push edi
push esi
lea eax, [ebp - 0x410]
push ebx
sub esp, 0x6b0
mov dword [ebp - 0x624], eax
mov eax, dword [0x76d164]
mov dword [ebp - 0x658], 0xdeadbeef
mov dword [ebp - 0x654], 0
mov dword [ebp - 0x650], 0
mov dword [ebp - 0x64c], 0x57
mov dword [ebp - 0x648], 0xa
mov dword [ebp - 0x644], 0
mov dword [ebp - 0x640], 0
mov dword [ebp - 0x63c], 0x18
mov dword [ebp - 0x638], 0xa
mov dword [ebp - 0x634], 0
mov dword [ebp - 0x630], 0x400
mov dword [ebp - 0x62c], 0x3e6
mov dword [ebp - 0x628], 0xa
mov dword [ebp - 0x620], 0
mov dword [ebp - 0x61c], 0x18
test eax, eax
je 0x463417
lea eax, [ebp - 0x618]
mov dword [esp], 0x104
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_GetTempPathA]
sub esp, 8
mov ebx, eax
mov eax, 0x111a
call fcn.0045b740
mov edi, dword fs:[0x18]
mov eax, dword [edi + 0x34]
mov dword [esp], ebx
mov dword [esp + 4], str.GetFileInformationByHandleEx:_GetTempPathA_failed__got_error__lu._n
mov dword [esp + 8], eax
call fcn.0045bef0
lea eax, [ebp - 0x514]
mov dword [esp + 8], 0
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x618]
mov dword [esp + 4], 0x597f3c
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetTempFileNameA]
sub esp, 0x10
mov ebx, eax
mov eax, 0x111e
call fcn.0045b740
mov eax, dword [edi + 0x34]
mov dword [esp], ebx
mov dword [esp + 4], str.GetFileInformationByHandleEx:_GetTempFileNameA_failed__got_error__lu._n
mov dword [esp + 8], eax
call fcn.0045bef0
lea eax, [ebp - 0x514]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetFileAttributesA]
sub esp, 4
mov ebx, eax
mov eax, 0x1120
call fcn.0045b740
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_GetFileAttributesA_failed_to_find_the_temp_file__got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp ebx, 0xffffffff
lea ebx, [ebp - 0x658]
setne al
mov dword [esp], eax
call fcn.0045bef0
lea eax, [ebp - 0x618]
mov dword [esp + 0x18], 0
mov dword [esp], eax
mov eax, dword [sym.imp.kernel32.dll_CreateFileA]
mov dword [esp + 0x14], 0x2000000
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 7
mov dword [esp + 4], 0x80000000
mov dword [ebp - 0x690], eax
call eax
sub esp, 0x1c
mov dword [ebp - 0x688], eax
mov esi, eax
mov eax, 0x1125
call fcn.0045b740
mov eax, dword [edi + 0x34]
cmp esi, 0xffffffff
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_open_the_temp_folder__got_error__lu._n
mov dword [esp + 8], eax
setne al
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
mov dword [edi + 0x34], 0xdeadbeef
mov eax, dword [ebx + 8]
mov dword [esp + 0xc], eax
mov eax, dword [ebx + 4]
mov dword [esp + 8], eax
mov eax, dword [ebx]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x112c
xor eax, eax
mov ecx, dword [edi + 0x34]
mov edx, dword [ebx + 0xc]
test esi, esi
jne 0x462abb
xor eax, eax
cmp ecx, edx
sete al
mov dword [esp], eax
add ebx, 0x10
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edx
mov dword [esp + 4], str.GetFileInformationByHandleEx:_expected_error__lu__got__lu._n
call fcn.0045bef0
lea eax, [ebp - 0x618]
cmp ebx, eax
jne 0x462a67
mov ebx, dword fs:[0x18]
mov esi, ebx
mov ebx, dword [ebp - 0x688]
nop
mov eax, 0xffffffff
mov ecx, 0x100
lea edi, [ebp - 0x410]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x410]
mov dword [esp + 0xc], 0x400
mov dword [esp + 8], eax
mov dword [esp + 4], 0xa
mov dword [esp], ebx
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
test eax, eax
jne 0x463330
mov ebx, dword fs:[0x18]
cmp dword [ebx + 0x34], 0x12
mov esi, eax
je 0x462b6e
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x1136
mov eax, dword [ebx + 0x34]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_query_for_FileIdBothDirectoryInfo__got_error__lu._n
mov dword [esp + 8], eax
mov dword [esp], 0
call fcn.0045bef0
mov eax, dword [ebp - 0x688]
mov ebx, dword fs:[0x18]
mov dword [esp], eax
mov eax, dword [sym.imp.kernel32.dll_CloseHandle]
mov dword [ebp - 0x68c], eax
call eax
lea edx, [ebp - 0x514]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 7
mov dword [esp + 4], 0x80000000
mov dword [esp], edx
mov edx, dword [ebp - 0x690]
call edx
sub esp, 0x1c
mov edi, eax
mov eax, 0x1149
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_open_the_temp_file__got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp edi, 0xffffffff
setne al
mov dword [ebp - 0x688], edi
lea edi, [ebp - 0x410]
mov dword [esp], eax
call fcn.0045bef0
lea edx, [ebp - 0x410]
mov eax, 0xffffffff
mov ecx, 0x100
rep stosd dword es:[edi], eax
mov dword [esp + 8], edx
mov dword [esp + 0xc], 0x400
mov dword [esp + 4], 0
mov ecx, dword [ebp - 0x688]
mov dword [esp], ecx
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x114f
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp], edi
lea edi, [ebp - 0x514]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_get_FileBasicInfo___lu_n
mov dword [esp + 8], eax
call fcn.0045bef0
mov ecx, dword [ebp - 0x3fc]
mov edx, dword [ebp - 0x400]
mov dword [ebp - 0x694], ecx
mov ecx, dword [ebp - 0x688]
mov dword [ebp - 0x698], edx
mov dword [esp], ecx
mov ecx, dword [ebp - 0x68c]
call ecx
sub esp, 4
mov dword [esp], 0x1e
call dword [sym.imp.kernel32.dll_Sleep]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 7
mov dword [esp + 4], 0x40000000
mov dword [esp], edi
mov edi, dword [ebp - 0x690]
call edi
sub esp, 0x1c
mov edi, eax
mov eax, 0x1159
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_open_the_temp_file__got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp edi, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
lea ecx, [ebp - 0x514]
mov dword [esp], ecx
mov ecx, dword [sym.imp.msvcrt.dll_strlen]
mov dword [ebp - 0x69c], ecx
call ecx
lea ecx, [ebp - 0x680]
lea edx, [ebp - 0x514]
mov dword [esp], edi
mov dword [esp + 0xc], ecx
mov dword [esp + 4], edx
mov dword [esp + 0x10], 0
mov dword [esp + 8], eax
call dword [sym.imp.kernel32.dll_WriteFile]
sub esp, 0x14
mov dword [ebp - 0x688], eax
mov eax, 0x115c
call fcn.0045b740
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Write_failed_n
mov edx, dword [ebp - 0x688]
mov dword [esp], edx
call fcn.0045bef0
mov dword [esp], edi
mov ecx, dword [ebp - 0x68c]
call ecx
lea eax, [ebp - 0x514]
sub esp, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 7
mov dword [esp + 4], 0x80000000
mov dword [esp], eax
mov edi, dword [ebp - 0x690]
call edi
sub esp, 0x1c
mov edi, eax
mov eax, 0x1161
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_open_the_temp_file__got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp edi, 0xffffffff
setne al
mov dword [ebp - 0x688], edi
lea edi, [ebp - 0x410]
mov dword [esp], eax
call fcn.0045bef0
mov eax, 0xffffffff
mov ecx, 0x100
rep stosd dword es:[edi], eax
lea edi, [ebp - 0x410]
mov dword [esp + 0xc], 0x400
mov dword [esp + 8], edi
mov dword [esp + 4], 0
mov ecx, dword [ebp - 0x688]
mov dword [esp], ecx
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1166
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp], edi
lea edi, [ebp - 0x410]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_get_FileBasicInfo___lu_n
mov dword [esp + 8], eax
call fcn.0045bef0
mov eax, 0x116a
call fcn.0045b740
mov dword [esp + 4], str.GetFileInformationByHandleEx:_last_write_time_didnt_change_n
mov edx, dword [ebp - 0x698]
xor edx, dword [ebp - 0x400]
mov ecx, dword [ebp - 0x694]
mov eax, edx
xor ecx, dword [ebp - 0x3fc]
or eax, ecx
setne al
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
lea edx, [ebp - 0x410]
mov eax, 0xffffffff
mov ecx, 0x100
rep stosd dword es:[edi], eax
mov dword [esp + 8], edx
mov dword [esp + 0xc], 0x400
mov dword [esp + 4], 1
mov ecx, dword [ebp - 0x688]
mov dword [esp], ecx
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1170
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp], edi
lea edi, [ebp - 0x410]
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_get_FileStandardInfo___lu_n
mov dword [esp + 8], eax
call fcn.0045bef0
mov eax, 0x1172
call fcn.0045b740
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Unexpected_number_of_links_n
xor eax, eax
cmp dword [ebp - 0x400], 1
sete al
mov dword [esp], eax
call fcn.0045bef0
mov eax, 0x1173
call fcn.0045b740
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Unexpected_pending_delete_n
xor eax, eax
cmp byte [ebp - 0x3fc], 0
sete al
mov dword [esp], eax
call fcn.0045bef0
mov eax, 0x1174
call fcn.0045b740
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Incorrect_directory_flag_n
xor eax, eax
cmp byte [ebp - 0x3fb], 0
sete al
mov dword [esp], eax
call fcn.0045bef0
mov eax, 0xffffffff
mov ecx, 0x100
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x410]
mov dword [esp + 0xc], 0x400
mov dword [esp + 8], eax
mov dword [esp + 4], 2
mov ecx, dword [ebp - 0x688]
mov dword [esp], ecx
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1179
call fcn.0045b740
mov eax, dword [ebx + 0x34]
mov dword [esp], edi
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_get_FileNameInfo___lu_n
mov dword [esp + 8], eax
call fcn.0045bef0
lea eax, [ebp - 0x514]
mov dword [esp + 4], 0x5c
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll_strchr]
mov edi, eax
mov eax, 0x117c
call fcn.0045b740
xor eax, eax
test edi, edi
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Temp_filename_didnt_contain_backslash_n
setne al
mov dword [esp], eax
call fcn.0045bef0
mov eax, 0x117d
call fcn.0045b740
mov dword [esp], edi
mov ecx, dword [ebp - 0x69c]
call ecx
mov dword [esp + 4], str.GetFileInformationByHandleEx:_Incorrect_file_name_length_n
add eax, eax
cmp dword [ebp - 0x410], eax
sete al
xor ebx, ebx
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
mov eax, dword [ebp - 0x410]
shr eax, 1
je 0x463099
lea esi, [esi]
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x1180
movsx eax, byte [edi + ebx]
movzx edx, word [ebp + ebx*2 - 0x40c]
mov dword [esp + 8], ebx
mov dword [esp + 0xc], eax
cmp edx, eax
mov dword [esp + 0x10], edx
sete al
mov dword [esp + 4], str.Incorrect_filename_char__d:__c_vs__c_n
add ebx, 1
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
mov eax, dword [ebp - 0x410]
shr eax, 1
cmp ebx, eax
jb 0x463048
lea eax, [ebp - 0x670]
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x690], edx
mov dword [esp + 0xc], 8
mov dword [esp + 8], eax
mov dword [esp + 4], 6
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1186
call fcn.0045b740
mov edx, dword [ebp - 0x690]
xor eax, eax
mov ecx, dword [edx + 0x34]
test edi, edi
je 0x463409
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], 0x599b92
call fcn.0045bef0
lea eax, [ebp - 0x67c]
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x690], edx
mov dword [esp + 0xc], 4
mov dword [esp + 8], eax
mov dword [esp + 4], 0xc
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x118a
call fcn.0045b740
mov edx, dword [ebp - 0x690]
xor eax, eax
mov ecx, dword [edx + 0x34]
test edi, edi
jne 0x463173
xor eax, eax
cmp ecx, 0x57
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], 0x599b92
call fcn.0045bef0
lea eax, [ebp - 0x678]
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x690], edx
mov dword [esp + 0xc], 8
mov dword [esp + 8], eax
mov dword [esp + 4], 5
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x118e
call fcn.0045b740
mov edx, dword [ebp - 0x690]
xor eax, eax
mov ecx, dword [edx + 0x34]
test edi, edi
jne 0x4631ee
xor eax, eax
cmp ecx, 0x57
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], 0x599b92
call fcn.0045bef0
lea eax, [ebp - 0x681]
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x690], edx
mov dword [esp + 0xc], 1
mov dword [esp + 8], eax
mov dword [esp + 4], 4
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1192
call fcn.0045b740
mov edx, dword [ebp - 0x690]
xor eax, eax
mov ecx, dword [edx + 0x34]
test edi, edi
jne 0x463269
xor eax, eax
cmp ecx, 0x57
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], 0x599b92
call fcn.0045bef0
lea eax, [ebp - 0x668]
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x690], edx
mov dword [esp + 0xc], 0x10
mov dword [esp + 8], eax
mov dword [esp + 4], 3
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
call dword [0x76d164]
sub esp, 0x10
mov edi, eax
mov eax, 0x1196
call fcn.0045b740
mov edx, dword [ebp - 0x690]
mov eax, dword [edx + 0x34]
test edi, edi
je 0x4633fa
mov dword [esp + 0xc], eax
mov dword [esp + 8], edi
mov dword [esp], esi
mov dword [esp + 4], 0x599b92
call fcn.0045bef0
mov eax, dword [ebp - 0x688]
mov dword [esp], eax
mov eax, dword [ebp - 0x68c]
call eax
lea eax, [ebp - 0x514]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_DeleteFileA]
sub esp, 4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x1136
mov eax, dword [esi + 0x34]
mov dword [esp], edi
lea edi, [ebp - 0x410]
mov dword [esp + 8], eax
mov dword [esp + 4], str.GetFileInformationByHandleEx:_failed_to_query_for_FileIdBothDirectoryInfo__got_error__lu._n
call fcn.0045bef0
jmp 0x46336a
add edi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x113c
xor eax, eax
mov dword [esp + 4], str.GetFileInformationByHandleEx:_returned_invalid_file_attributes._n
cmp dword [edi + 0x38], 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x113d
xor eax, eax
mov dword [esp + 4], str.GetFileInformationByHandleEx:_returned_invalid_file_id._n
cmp dword [edi + 0x60], 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x113e
xor eax, eax
mov dword [esp + 4], str.GetFileInformationByHandleEx:_returned_invalid_file_name_length._n
cmp dword [edi + 0x3c], 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
mov eax, dword [edi]
test eax, eax
jne 0x463368
jmp 0x462af0
xor ecx, ecx
cmp eax, 0x57
sete cl
mov esi, ecx
jmp 0x4632de
xor eax, eax
cmp dword [edx + 0x34], 0x57
sete al
jmp 0x4630f8
mov eax, 0x1115
call fcn.0045b740
mov dword [esp], str.GetFileInformationByHandleEx_is_missing._n
call fcn.0045bec0
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret