Function at 0x46bae0
Capabilities:
Create directory
Delete directory
Delete file
Get common file path

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
lea esi, [ebp - 0x41c]
push ebx
sub esp, 0x438
mov dword [esp + 4], esi
mov dword [esp], 0x104
call dword [sym.imp.kernel32.dll_GetTempPathW]
sub esp, 8
mov ebx, eax
test eax, eax
jne 0x46bb1c
mov eax, dword fs:[0x18]
cmp dword [eax + 0x34], 0x78
je 0x46c0f0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x669
mov edi, dword fs:[0x18]
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.GetTempPathW_error__ld_n
mov dword [esp + 8], eax
xor eax, eax
test ebx, ebx
setne al
mov dword [esp], eax
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x66a
xor eax, eax
cmp ebx, 0x103
lea ebx, [ebp - 0x214]
setbe al
mov dword [esp + 4], 0x59813c
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], esi
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0
mov dword [esp + 4], 0x59eae0
call dword [sym.imp.kernel32.dll_GetTempFileNameW]
sub esp, 0x10
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x66d
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.GetTempFileNameW_error__ld_n
mov dword [esp + 8], eax
xor eax, eax
test esi, esi
setne al
mov dword [esp], eax
call fcn.0045bef0
mov dword [edi + 0x34], 0xdeadbeef
mov esi, dword [sym.imp.kernel32.dll_CreateFileW]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x10000000
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x80000000
mov dword [esp], ebx
call esi
sub esp, 0x1c
mov dword [ebp - 0x420], eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x672
xor eax, eax
cmp dword [ebp - 0x420], 0xffffffff
je 0x46c0c0
mov dword [esp + 4], str.CREATE_NEW_should_fail_if_file_exists_and_last_error_value_should_be_ERROR_FILE_EXISTS_n
mov dword [esp], eax
call fcn.0045bef0
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x420], edx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x10000000
mov dword [esp + 0x10], 2
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0x80000000
mov dword [esp], ebx
call esi
sub esp, 0x1c
mov edi, eax
call fcn.0057d110
mov edx, dword [ebp - 0x420]
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x678
xor eax, eax
mov ecx, dword [edx + 0x34]
cmp edi, 0xffffffff
je 0x46bccf
xor eax, eax
cmp ecx, 0xb7
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], str.hFile__p__last_error__lu_n
call fcn.0045bef0
mov eax, dword [sym.imp.kernel32.dll_CloseHandle]
mov dword [esp], edi
mov dword [ebp - 0x420], eax
call eax
sub esp, 4
mov edx, dword fs:[0x18]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [ebp - 0x424], edx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x10000000
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0x80000000
mov dword [esp], ebx
call esi
sub esp, 0x1c
mov edi, eax
call fcn.0057d110
mov edx, dword [ebp - 0x424]
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x680
xor eax, eax
mov ecx, dword [edx + 0x34]
cmp edi, 0xffffffff
je 0x46bd75
xor eax, eax
cmp ecx, 0xb7
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], str.hFile__p__last_error__lu_n
call fcn.0045bef0
mov dword [esp], edi
mov eax, dword [ebp - 0x420]
call eax
mov eax, dword [sym.imp.kernel32.dll_DeleteFileW]
sub esp, 4
mov dword [esp], ebx
mov dword [ebp - 0x424], eax
call eax
sub esp, 4
mov edi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x686
mov edx, dword fs:[0x18]
mov eax, dword [edx + 0x34]
mov dword [ebp - 0x428], edx
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], str.DeleteFileW:_error__ld_n
call fcn.0045bef0
mov edx, dword [ebp - 0x428]
mov dword [edx + 0x34], 0xdeadbeef
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x10000000
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0x80000000
mov dword [esp], ebx
call esi
sub esp, 0x1c
mov edi, eax
call fcn.0057d110
mov edx, dword [ebp - 0x428]
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x68b
xor eax, eax
mov ecx, dword [edx + 0x34]
cmp edi, 0xffffffff
je 0x46be56
xor eax, eax
test ecx, ecx
sete al
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], str.hFile__p__last_error__lu_n
call fcn.0045bef0
mov dword [esp], edi
mov eax, dword [ebp - 0x420]
call eax
sub esp, 4
mov dword [esp], ebx
mov eax, dword [ebp - 0x424]
call eax
sub esp, 4
mov edi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov edx, dword fs:[0x18]
mov dword [eax + 4], 0x691
mov eax, dword [edx + 0x34]
mov dword [ebp - 0x424], edx
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], str.DeleteFileW:_error__ld_n
call fcn.0045bef0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x10000000
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x80000000
mov dword [esp], 0x59eadc
call esi
sub esp, 0x1c
mov edi, eax
call fcn.0057d110
mov edx, dword [ebp - 0x424]
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x69e
xor eax, eax
mov ecx, dword [edx + 0x34]
cmp edi, 0xffffffff
je 0x46c0e0
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp + 4], str.CreateFileW_____returned_ret_p_error_ld_n
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], pe_nt_image_headers32
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0
mov dword [esp], str..BOGUS
call esi
sub esp, 0x1c
mov edi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x6a4
xor eax, eax
mov edx, dword fs:[0x18]
mov ecx, dword [edx + 0x34]
cmp edi, 0xffffffff
je 0x46c0d0
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp + 4], str.CreateFileW_on_invalid_VxD_name_returned_ret_p_error_ld_n
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], ebx
mov dword [esp + 4], 0
call dword [sym.imp.kernel32.dll_CreateDirectoryW]
sub esp, 8
mov edi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x6a8
xor eax, eax
cmp edi, 1
sete al
mov dword [esp + 4], str.couldnt_create_temporary_directory_n
mov dword [esp], eax
mov edi, dword fs:[0x18]
call fcn.0045bef0
mov dword [esp], ebx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x2000080
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xc0000000
call esi
sub esp, 0x1c
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x6ab
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.expected_CreateFile_to_succeed_on_existing_directory__error:__ld_n
mov dword [esp + 8], eax
xor eax, eax
cmp esi, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], esi
mov eax, dword [ebp - 0x420]
call eax
sub esp, 4
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_RemoveDirectoryW]
sub esp, 4
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x6af
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.DeleteFileW:_error__ld_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.0045bef0
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
xor eax, eax
cmp dword [edi + 0x34], 0x50
sete al
jmp 0x46bc44
xor eax, eax
cmp ecx, 2
sete al
jmp 0x46bfa3
xor eax, eax
cmp ecx, 3
sete al
jmp 0x46bf26
mov eax, 0x666
call fcn.0045b740
mov dword [esp], str.GetTempPathW_is_not_available_n
call fcn.0045bec0
jmp 0x46c0b2