Function at 0x470ad0
Capabilities:
Create directory
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x204f4
call fcn.0040f8c0
or eax, 0xffffffff
push ebx
xor ebx, ebx
mov dword [esp + 0x10], eax
mov dword [esp + 8], eax
push esi
mov esi, dword [ebp + 0x10]
push edi
xor eax, eax
mov word [esp + 0x50], bx
mov ecx, 0x95
lea edi, [esp + 0x52]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov word [esp + 0x2a8], bx
mov ecx, 0x95
lea edi, [esp + 0x2aa]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
mov dword [esp + 0x48], eax
push esi
mov dword [esp + 0x20], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x3c], 1
mov dword [esp + 0x30], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x50], eax
call dword [sym.imp.MSVCR71.dll_wcslen]
mov edi, dword [ebp + 8]
add esp, 4
test eax, eax
jne 0x470b7e
mov eax, dword [ebp + 0x14]
shr eax, 1
cmp eax, 0x7fffffff
ja 0x470b86
push edi
push eax
push esi
call fcn.0040120a
jmp 0x470b86
mov dword [esp + 0x38], 0
push edi
call fcn.00471ea0
add esp, 4
test eax, eax
jne 0x470ba6
push 0x80
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push edi
call fcn.00471ea0
add esp, 4
test eax, eax
je 0x470c2f
push edi
call fcn.00471ee0
add esp, 4
test eax, eax
jne 0x470c2f
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push edi
call fcn.00471f20
add esp, 4
test eax, eax
jne 0x470c2f
push eax
push 0x2000000
push 3
push eax
push eax
push 0x410f0000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x470c0c
push esi
push str.Unable_to_write_file_attributes_for_directory__s
push str.Engine
call fcn.004572b0
add esp, 0xc
jmp 0x4712bb
mov ecx, dword [edi + 0x23a]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea edx, [esp + 0x10]
push edx
call fcn.00471f40
add esp, 4
mov dword [esp + 0x2c], 1
mov eax, dword [ebp + 0x18]
mov dword [0x4e3a70], eax
movzx ecx, word [edi + 0x258]
movzx edx, word [edi + 0x256]
mov eax, dword [ebp + 0xc]
push edx
mov dword [esp + 0x48], ecx
mov ecx, dword [eax + 0x2c]
push ecx
push 0x4e3508
push str._s_dData_d
lea edx, [esp + 0x60]
push 0x258
push edx
call fcn.00403fa3
add esp, 0x18
push 0
push 0
push 3
push 0
push 0
push SysReAllocString
lea eax, [esp + 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x18], eax
jne 0x470d47
cmp dword [ebp + 0x18], 2
jne 0x470cf2
mov ecx, dword [0x4e40c8]
xor edx, edx
mov dx, word [0x4e327c]
xor eax, eax
mov ax, word [0x4e3270]
push ecx
mov ecx, dword [0x4e3a5c]
push edx
movzx edx, word [edi + 0x256]
push eax
push ecx
push 0x4e3508
push edx
call sub.ui.dll_LoadCDForRestoreFile
mov ebx, eax
add esp, 0x18
test ebx, ebx
je 0x470d18
cmp ebx, 2
jne 0x470cf2
push str.RestoreFile_failed___cancel_restore_was_called
push str.Engine
call fcn.004572b0
add esp, 8
jmp 0x4712bb
push 0x505
lea eax, [esp + 0x54]
push eax
push str.RestoreFile_failed___unable_to_create__s___dwRet__0x_08x
push str.Engine
mov ebx, 0x505
call fcn.004572b0
add esp, 0x10
jmp 0x4712bb
push 0
push 0
push 3
push 0
push 0
push SysReAllocString
lea ecx, [esp + 0x68]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x18], eax
jne 0x470d47
push 0x505
lea edx, [esp + 0x54]
push edx
jmp 0x470cfc
mov ecx, dword [edi + 0x25a]
push 0
push 0
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [edi + 0x25a]
mov dword [0x4e376c], edx
movzx eax, word [edi + 0x256]
push edi
mov dword [0x4e3768], eax
call fcn.00471ee0
add esp, 4
cmp eax, 1
jne 0x470e8e
movzx ecx, word [esi]
push ecx
push str._c:_temp.2
lea edx, [esp + 0x2b0]
push 0x258
push edx
call fcn.00403fa3
mov edx, dword [ebp + 0xc]
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x2bc]
push ecx
push edx
push edi
call fcn.00470950
mov ebx, eax
add esp, 0x20
test ebx, ebx
je 0x470dd5
push str.Leaving_RestoreFile___CreateTemporaryFile_failed
push str.Engine
call fcn.004572b0
add esp, 8
jmp 0x4712bb
push 0
push 0x80
push 3
push 0
push 0
push SysReAllocString
lea eax, [esp + 0x2c0]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x470e22
mov ebx, 0x50c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push str.RestoreFile_failed__EFS____unable_to_create_temp_file___dwRet__0x_08x___WinRC__0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x10
jmp 0x4712bb
push edi
call fcn.00471ea0
add esp, 4
neg eax
sbb eax, eax
and eax, 0x12
lea ecx, [esp + 0x28]
push ecx
inc eax
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_OpenEncryptedFileRawW]
test eax, eax
je 0x470e69
mov ebx, 0x50d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push esi
push str.RestoreFile_failed__EFS____unable_to_create_raw__s___dwRet__0x_08x___WinRC__0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x14
jmp 0x4712bb
mov edx, dword [esp + 0x28]
push edx
lea eax, [esp + 0x14]
push eax
push 0x46fef0
call dword [sym.imp.ADVAPI32.dll_WriteEncryptedFileRaw]
mov ecx, dword [esp + 0x28]
push ecx
call dword [sym.imp.ADVAPI32.dll_CloseEncryptedFileRaw]
jmp 0x4712bb
push edi
call fcn.00471ea0
add esp, 4
test eax, eax
je 0x470ec1
push edi
call fcn.00471f20
mov edi, eax
add esp, 4
neg edi
sbb edi, edi
and edi, 0x200000
mov eax, 4
add edi, 0x2000010
mov dword [esp + 0x24], eax
jmp 0x470ed2
mov dword [esp + 0x24], 2
mov eax, dword [esp + 0x24]
mov edi, 0x2000000
mov ecx, dword [0x4e3a88]
test ecx, ecx
jne 0x470f79
mov ecx, dword [esp + 0x38]
test ecx, ecx
je 0x470f79
mov edx, dword [esp + 0x2c]
mov ecx, dword [ebp + 8]
push edx
push eax
push edi
lea eax, [esp + 0x1c]
push eax
push ecx
call fcn.00470310
mov ebx, eax
add esp, 0x14
cmp ebx, 0x587
jne 0x470f15
xor ebx, ebx
jmp 0x4712b8
test ebx, ebx
je 0x470fe1
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x20
jne 0x470f4c
mov ebx, dword [ebp + 8]
push ebx
call fcn.00470590
mov edx, dword [esp + 0x30]
mov eax, dword [esp + 0x28]
push edx
push eax
push edi
lea ecx, [esp + 0x20]
push ecx
push ebx
call fcn.00470310
add esp, 0x18
mov ebx, eax
test ebx, ebx
je 0x470fe1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push esi
push str.RestoreFile_failed___unable_to_create_new_file__s___dwRet__0x_08x___GetLastError___returns_0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x14
mov ebx, 0x514
jmp 0x4712b8
push 0
push edi
push eax
push 0
push 0
push 0x410f0000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
je 0x470f9a
test eax, eax
jne 0x470fd0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x20
jne 0x470fcc
push esi
call fcn.00470590
mov edx, dword [esp + 0x28]
add esp, 4
push 0
push edi
push edx
push 0
push 0
push 0x410f0000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esp + 0x10], eax
jmp 0x470fd0
mov eax, dword [esp + 0x10]
cmp eax, 0xffffffff
je 0x4713a2
test eax, eax
je 0x4713a2
mov edx, dword [ebp + 8]
mov eax, dword [0x4e376c]
cmp eax, dword [edx + 0x25e]
jb 0x471001
mov ecx, dword [esp + 0x44]
cmp dword [0x4e3768], ecx
jae 0x47122a
xor eax, eax
mov ecx, 0x3fff
lea edi, [esp + 0x500]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax + 0x2c]
push ecx
push edx
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x2c]
push ecx
lea edx, [esp + 0x514]
push edx
call fcn.004705f0
mov ebx, eax
add esp, 0x18
test ebx, ebx
jne 0x4712b8
mov eax, dword [esp + 0x20]
push eax
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x10508]
push edx
push eax
lea ecx, [esp + 0x510]
push ecx
call fcn.00470270
mov ebx, eax
add esp, 0x14
test ebx, ebx
jne 0x4712f7
mov edx, dword [ebp + 8]
push edx
call fcn.00471f20
add esp, 4
test eax, eax
je 0x471197
push 0x4000
call dword [sym.imp.MSVCR71.dll_malloc]
mov ecx, dword [esp + 0x18]
mov edx, ecx
shr ecx, 2
mov edi, eax
lea esi, [esp + 0x10504]
rep movsd dword es:[edi], dword [esi]
add esp, 4
mov ecx, edx
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x18]
lea ecx, [esp + 0x44]
push ecx
push ebx
push ebx
push edx
push eax
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x28]
push 0x900a4
push eax
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x47130c
xor eax, eax
mov ecx, 0x3fff
lea edi, [esp + 0x500]
rep stosd dword es:[edi], eax
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 0x2c]
stosw word es:[edi], ax
push edx
stosb byte es:[edi], al
mov eax, dword [ebp + 8]
push eax
lea ecx, [esp + 0x28]
push ecx
lea edx, [esp + 0x24]
push edx
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x514]
push ecx
call fcn.004705f0
mov ebx, eax
add esp, 0x18
test ebx, ebx
jne 0x4712b5
mov edx, dword [esp + 0x20]
push edx
mov edx, dword [esp + 0x20]
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x10508]
push ecx
push edx
lea eax, [esp + 0x510]
push eax
call fcn.00470270
mov ebx, eax
add esp, 0x14
test ebx, ebx
jne 0x471331
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.MSVCR71.dll_malloc]
mov ecx, dword [esp + 0x18]
mov edx, ecx
shr ecx, 2
mov edi, eax
lea esi, [esp + 0x10504]
rep movsd dword es:[edi], dword [esi]
push eax
mov eax, dword [ebp + 8]
mov ecx, edx
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call fcn.00471f90
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x4712b5
mov esi, dword [ebp + 0x10]
jmp 0x4711d3
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x34]
push ecx
push 1
push 0
lea edx, [esp + 0x3c]
push edx
mov edx, dword [esp + 0x20]
push eax
lea ecx, [esp + 0x10514]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_BackupWrite]
test eax, eax
je 0x471349
mov eax, dword [esp + 0x14]
cmp eax, dword [esp + 0x30]
jne 0x471384
mov eax, dword [esp + 0x1c]
mov edi, dword [0x4e3220]
mov edx, dword [0x4e3224]
xor ecx, ecx
add eax, 3
add edi, eax
adc edx, ecx
mov dword [0x4e3220], edi
mov edi, dword [0x4e3274]
mov dword [0x4e3224], edx
mov edx, dword [0x4e3278]
add edi, eax
adc edx, ecx
mov ecx, dword [0x4e3778]
push ecx
mov ecx, 0x4e3210
mov dword [0x4e3274], edi
mov dword [0x4e3278], edx
call fcn.004746a0
jmp 0x470fe1
push edx
call fcn.00471f20
add esp, 4
test eax, eax
jne 0x471249
lea edx, [esp + 0x34]
push edx
push eax
push 1
push eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_BackupWrite]
mov eax, dword [ebp + 8]
add eax, 0x246
mov ecx, 2
lea edi, [esp + 0x48]
mov esi, eax
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
jne 0x47127a
mov eax, dword [ebp + 8]
lea ecx, [eax + 0x23e]
push ecx
add eax, 0x24e
push eax
push edx
mov edx, dword [esp + 0x1c]
push edx
jmp 0x471291
mov ecx, dword [ebp + 8]
lea edx, [ecx + 0x23e]
push edx
add ecx, 0x24e
push ecx
push eax
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileTime]
mov eax, dword [0x4e3a88]
test eax, eax
je 0x4712b5
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 8]
push ecx
push edx
lea eax, [esp + 0x18]
push eax
call fcn.0046ff60
add esp, 0xc
mov esi, dword [ebp + 0x10]
mov edi, dword [ebp + 8]
lea eax, [esp + 0x18]
push eax
call fcn.00471f40
lea ecx, [esp + 0x14]
push ecx
call fcn.00471f40
add esp, 8
lea edx, [esp + 0x2a8]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test ebx, ebx
je 0x4713d8
mov dword [esi], 0
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push esi
push str.RestoreFile_failed_for__s___DecompressAndDecryptBuffer_failed
push str.Engine
call fcn.004572b0
add esp, 0xc
jmp 0x4712b8
mov ebx, 0x5c1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp + 8]
push eax
push ebx
push ecx
push str.RestoreFile_failed___unable_to_set_reparse_point_data_for_file__s___dwRet__0x_08x___WinRC__0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x14
jmp 0x4712b5
mov edx, dword [ebp + 0x10]
push edx
push str.RestoreFile_failed_for__s___DecompressAndDecryptBuffer_failed
push str.Engine
call fcn.004572b0
jmp 0x4712b2
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x515
mov edi, eax
push edi
push esi
push str.RestoreFile_failed___BackupWrite_for__s___GetLastError___returns_0x_08x__dwRet__0x_08x
push str.Engine
call fcn.004572b0
xor ebx, ebx
add esp, 0x14
cmp edi, 0x51b
setne bl
dec ebx
and ebx, 0xb
add ebx, 0x515
jmp 0x4712b8
mov ebx, 0x517
push ebx
push esi
push str.RestoreFile_failed___BackupWrite_for__s___dwRet__0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x10
jmp 0x4712b8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push esi
push str.RestoreFile_failed___unable_to_create_new_file__s___GetLastError___returns_0x_08x
push str.Engine
call fcn.004572b0
xor ebx, ebx
add esp, 0x10
cmp edi, 0x522
setne bl
dec ebx
and ebx, 0xc
add ebx, 0x514
jmp 0x4712b8
mov eax, dword [edi + 0x23a]
test ah, 8
je 0x471406
push esi
call fcn.0046ffb0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x471406
push ebx
push esi
push str.Unable_to_enable_compression_for_file__s___dwRet__0x_08x
push str.Engine
call fcn.004572b0
add esp, 0x10
mov eax, dword [edi + 0x23a]
test al, 0x20
je 0x471413
add eax, 0xffffffe0
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, dword [esp + 0x3c]
test eax, eax
mov dword [esi], 0
je 0x471433
push eax
call dword [sym.imp.MSVCR71.dll_free]
add esp, 4
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret