Function at 0x14006e850
Capabilities:
Check if file exists
Copy file
Create directory
Create thread
Move file
Set registry value

Disassembly:
mov r11, rsp
push rbp
push rdi
push r15
lea rbp, [r11 - 0x1b8]
sub rsp, 0x2a0
mov rax, qword [0x140193440]
xor rax, rsp
mov qword [rbp + 0x180], rax
movups xmm0, xmmword [str._:_sources_boot.wim]
mov eax, dword [0x140174480]
mov qword [r11 + 0x20], r12
mov r12d, edx
movups xmmword [rbp - 0x28], xmm0
mov dword [rbp - 0x18], eax
movups xmm0, xmmword [str._:_sources_appraiserres.dll]
mov eax, dword [0x1401744a0]
mov qword [r11 - 0x20], r13
movups xmmword [rbp - 0x10], xmm0
movsx r13d, cl
xor ecx, ecx
cmp qword [0x1401d05d0], rcx
mov edi, ecx
movsd xmm0, qword [0x140174498]
mov r15d, ecx
movsd qword [rbp], xmm0
movups xmm0, xmmword [str._:_sources_appraiserres.bak]
mov dword [rbp + 8], eax
mov eax, dword [0x1401744c0]
movups xmmword [rbp + 0x10], xmm0
mov dword [rsp + 0x54], ecx
movsd xmm0, qword [0x1401744b8]
movsd qword [rbp + 0x20], xmm0
mov dword [rsp + 0x58], ecx
mov dword [rsp + 0x50], 2
mov dword [rbp + 0x28], eax
mov qword [rsp + 0x78], rcx
mov qword [rsp + 0x70], rcx
mov dword [rsp + 0x68], 1
jne 0x14006e926
mov r8d, 0x312
lea rdx, str.D:_a_rufus_rufus_srcwue.c
lea rcx, str.unattend_xml_path___NULL
call fcn.1400fbe54
mov qword [rsp + 0x2c8], rbx
lea rcx, str.Applying_Windows_customization:
mov qword [rsp + 0x2d0], rsi
mov qword [rsp + 0x290], r14
call fcn.14004f2f0
mov r9d, 0xcfe
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call fcn.140021510
bt r12d, 0x10
jae 0x14006ea30
mov ebx, r13d
lea r9, str._c:WindowsPanther
mov edx, 0x104
mov dword [rsp + 0x20], ebx
mov r8, 0xffffffffffffffff
lea rcx, [rbp + 0x30]
call fcn.140004fd0
xor edx, edx
mov byte [rbp + 0x133], dil
lea rcx, [rbp + 0x30]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x14006e9d0
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x14006e9d0
call fcn.14004fba0
mov r8, rax
lea rdx, [rbp + 0x30]
lea rcx, str.Could_not_create__s_:__s
call fcn.14004f2f0
mov ebx, 2
jmp 0x14006f081
lea r9, str._c:WindowsPantherunattend.xml
mov dword [rsp + 0x20], ebx
mov edx, 0x104
lea rcx, [rbp + 0x30]
mov r8, 0xffffffffffffffff
call fcn.140004fd0
mov rcx, qword [0x1401d05d0]
lea rdx, [rbp + 0x30]
mov r8d, 1
mov byte [rbp + 0x133], dil
call qword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x14006e9ae
lea rdx, [rbp + 0x30]
lea rcx, str.Added__s
call fcn.14004f2f0
mov ebx, dword [rsp + 0x50]
mov edi, 1
jmp 0x14006f081
mov esi, r12d
mov byte [rbp - 0x28], r13b
and esi, 1
je 0x14006ec59
lea rcx, [rbp - 0x10]
mov byte [rbp - 0x10], r13b
mov byte [rbp + 0x10], r13b
call fcn.14006bbf0
lea rcx, [rbp + 0x10]
mov rbx, rax
call fcn.14006bbf0
mov r8d, 1
mov rdx, rax
mov rcx, rbx
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_MoveFileExW]
mov r14d, eax
test rdi, rdi
je 0x14006ea82
mov rcx, rdi
call fcn.1400e8c70
test rbx, rbx
je 0x14006ea8f
mov rcx, rbx
call fcn.1400e8c70
test r14d, r14d
jne 0x14006eabc
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x14006eabc
call fcn.14004fba0
mov r8, rax
lea rdx, [rbp - 0x10]
lea rcx, str.Could_not_rename__s:__s
call fcn.14004f2f0
jmp 0x14006ebf3
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x14006eada
lea r8, [rbp + 0x10]
lea rdx, [rbp - 0x10]
lea rcx, str.Renamed__s___s
call fcn.14004f2f0
lea rcx, [rbp - 0x10]
call fcn.14006bbf0
mov qword [rsp + 0x30], r15
xor r9d, r9d
mov dword [rsp + 0x28], 0x80
mov edx, 0xc0000000
mov r8d, 1
mov dword [rsp + 0x20], 2
mov rcx, rax
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r14d, eax
test rbx, rbx
je 0x14006eb2b
mov rcx, rbx
call fcn.1400e8c70
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, [rbp - 0x10]
lea rcx, str.Created__s_placeholder
call fcn.14004f2f0
cmp dword [0x1401a0460], r15d
je 0x14006ec59
xorps xmm0, xmm0
lea rcx, [rbp + 0x10]
xor eax, eax
movups xmmword [rbp - 0x60], xmm0
mov qword [rbp - 0x30], rax
movups xmmword [rbp - 0x50], xmm0
movups xmmword [rbp - 0x40], xmm0
call fcn.14006bbf0
lea rdx, [rbp - 0x60]
mov rcx, rax
mov rbx, rax
call fcn.1401073d4
test rbx, rbx
je 0x14006eb94
mov rcx, rbx
call fcn.1400e8c70
mov rax, qword [rbp - 0x48]
sub qword [0x1401e79b0], rax
mov rbx, qword [0x1401a0468]
test rbx, rbx
je 0x14006ec59
mov eax, dword [0x1401a0474]
cmp dword [0x1401a0470], eax
jne 0x14006ec15
add eax, eax
mov rcx, rbx
mov edx, eax
shl rdx, 3
mov dword [0x1401a0474], eax
call fcn.1400c5b50
mov qword [0x1401a0468], rax
test rax, rax
jne 0x14006ec15
mov rcx, rbx
call fcn.1400e8c70
lea rcx, str.Could_not_reallocate_string_array
call fcn.14004f2f0
mov r9d, 0xcf
mov dword [rsp + 0x20], 1
xor r8d, r8d
mov edx, 0xcfd
mov ecx, 8
call fcn.140066570
jmp 0x14006ec81
lea rcx, [rbp - 0x10]
call fcn.1400fc834
mov ecx, dword [0x1401a0470]
mov rdx, rax
mov rax, qword [0x1401a0468]
mov qword [rax + rcx*8], rdx
mov ecx, dword [0x1401a0470]
mov rax, qword [0x1401a0468]
cmp qword [rax + rcx*8], r15
jne 0x14006ec4e
lea rcx, str.Could_not_store_string_in_array
jmp 0x14006ebee
lea eax, [rcx + 1]
mov dword [0x1401a0470], eax
jmp 0x14006ebf3
mov r9d, 0xcf
mov dword [rsp + 0x20], 1
xor r8d, r8d
mov edx, 0xcfd
mov ecx, 8
call fcn.140066570
test esi, esi
je 0x14006f12c
cmp dword [0x1401a0460], r15d
je 0x14006eccf
xorps xmm0, xmm0
lea rcx, [rbp - 0x28]
xor eax, eax
movups xmmword [rbp - 0x60], xmm0
mov qword [rbp - 0x30], rax
movups xmmword [rbp - 0x50], xmm0
movups xmmword [rbp - 0x40], xmm0
call fcn.14006bbf0
lea rdx, [rbp - 0x60]
mov rcx, rax
mov rbx, rax
call fcn.1401073d4
test rbx, rbx
je 0x14006ecc4
mov rcx, rbx
call fcn.1400e8c70
mov rax, qword [rbp - 0x48]
sub qword [0x1401e79b0], rax
mov ebx, 2
lea rdx, [rbp - 0x28]
mov r8d, ebx
lea rcx, str.Mounting__s__d_...
call fcn.14004f2f0
lea rcx, [rbp - 0x28]
call fcn.14006a000
test eax, eax
jne 0x14006ed21
lea rcx, str.WARNING:_This_image_appears_to_be_an_UNOFFICIAL_Windows_ISO_
call fcn.14004f2f0
lea rcx, str.Rufus_recommends_that_you_only_use_OFFICIAL_retail_Microsoft_Windows_images__such_as
call fcn.14004f2f0
lea rcx, str.the_ones_that_can_be_downloaded_through_the_download_facility_of_this_application.
call fcn.14004f2f0
mov ebx, 1
mov dword [rsp + 0x50], ebx
mov edx, ebx
lea rcx, [rbp - 0x28]
call fcn.140068e70
mov r15, rax
test rax, rax
je 0x14006f07d
lea r9, str._sWindowsSystem32configSYSTEM
mov qword [rsp + 0x20], rax
mov edx, 0x104
lea rcx, [rbp + 0x30]
mov r8, 0xffffffffffffffff
call fcn.140004fd0
mov byte [rbp + 0x133], 0
mov qword [rsp + 0x60], 0xffffffffffffffff
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x60]
mov edx, 0x20
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x14006edab
call fcn.14004fba0
mov rdx, rax
lea rcx, str.Could_not_get_current_process_token:__s
call fcn.14004f2f0
lea rcx, str.Falling_back_to_creating_the_registry_keys_through_unattend.xml
call fcn.14004f2f0
jmp 0x14006f12c
mov rcx, qword [rsp + 0x60]
lea rdx, str.SeRestorePrivilege
call fcn.14004ead0
mov rcx, qword [rsp + 0x60]
lea rdx, str.SeBackupPrivilege
call fcn.14004ead0
lea rdi, str.RUFUS_OFFLINE_HIVE
mov rcx, 0xffffffff80000002
mov rdx, rdi
lea r8, [rbp + 0x30]
call qword [sym.imp.ADVAPI32.dll_RegLoadKeyA]
mov ebx, eax
test eax, eax
je 0x14006ee10
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
mov r8, rax
lea rdx, [rbp + 0x30]
lea rcx, str.Could_not_mount_offline_registry_hive__s:__s
call fcn.14004f2f0
jmp 0x14006ee2a
mov r9, rdi
lea r8, str.HKLM
lea rdx, [rbp + 0x30]
lea rcx, str.Mounted_offline_registry_hive__s_to__s_s
call fcn.14004f2f0
mov rcx, qword [rsp + 0x60]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x14006ee3f
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
je 0x14006ee54
lea rcx, str.Falling_back_to_creating_the_registry_keys_through_unattend.xml
call fcn.14004f2f0
jmp 0x14006f12c
mov edx, 0xcfd
mov dword [rsp + 0x20], 1
mov ecx, 8
mov r9d, 0xcf
mov r8d, 0x65
call fcn.140066570
lea r9, str._sSetup
mov dword [rsp + 0x58], 1
mov edx, 0x40
mov qword [rsp + 0x20], rdi
mov r8, 0xffffffffffffffff
lea rcx, [rbp + 0x140]
call fcn.140004fd0
lea rax, [rsp + 0x78]
mov byte [rbp + 0x17f], 0
mov r9d, 0x2001d
mov qword [rsp + 0x20], rax
xor r8d, r8d
lea rdx, [rbp + 0x140]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x14006eef6
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
mov rdx, rax
lea rcx, str.Could_not_open_HKLMSYSTEMSetup_registry_key:__s
call fcn.14004f2f0
jmp 0x14006f12c
mov rcx, qword [rsp + 0x78]
lea rax, [rbp - 0x80]
mov qword [rsp + 0x40], rax
lea rdx, str.LabConfig
lea rax, [rsp + 0x70]
xor r9d, r9d
mov qword [rsp + 0x38], rax
xor r8d, r8d
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 7
mov dword [rsp + 0x20], 0
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x14006ef5f
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
mov rdx, rax
lea rcx, str.Could_not_create_HKLMSYSTEMSetupLabConfig_registry_key:__s
call fcn.14004f2f0
jmp 0x14006f12c
lea rsi, str.BypassTPMCheck
xor edi, edi
mov rbx, rsi
nop dword [rax + rax]
mov rdx, qword [rbx]
lea rax, [rsp + 0x68]
mov rcx, qword [rsp + 0x70]
mov r9d, 4
mov dword [rsp + 0x28], 4
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x14006f109
mov rdx, qword [rbx]
lea rcx, str.Created_HKLMSYSTEMSetupLabConfig_s_registry_key
call fcn.14004f2f0
inc edi
add rbx, 8
cmp edi, 3
jb 0x14006ef70
mov rcx, qword [0x1401d05d0]
lea r9, str.disabled
lea r8, str.windowsPE
mov dword [rsp + 0x20], 0
lea rdx, str._settings
call fcn.140027fd0
test rax, rax
jne 0x14006eff5
lea rcx, str.Warning:_Could_not_disable_windowsPE_pass_from_unattend.xml
call fcn.14004f2f0
mov edx, 0xcfd
mov dword [rsp + 0x20], 1
mov ecx, 8
mov r9d, 0xcf
mov r8d, 0x66
call fcn.140066570
mov ebx, r13d
lea r9, str._c:_sources_OEM___Panther
mov edx, 0x104
mov dword [rsp + 0x20], ebx
mov r8, 0xffffffffffffffff
lea rcx, [rbp + 0x30]
call fcn.140004fd0
xor r8d, r8d
mov byte [rbp + 0x133], 0
lea rdx, [rbp + 0x30]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHCreateDirectoryExA]
test eax, eax
je 0x14006f204
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
mov r8, rax
lea rdx, [rbp + 0x30]
lea rcx, str.Error:_Could_not_create_directory__s:__s
call fcn.14004f2f0
mov ebx, dword [rsp + 0x50]
mov edi, dword [rsp + 0x54]
mov rcx, qword [rsp + 0x70]
mov r14, qword [rsp + 0x290]
mov r13, qword [rsp + 0x298]
mov r12, qword [rsp + 0x2d8]
mov rsi, qword [rsp + 0x2d0]
test rcx, rcx
je 0x14006f0b1
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x14006f0c1
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [rsp + 0x58], 0
je 0x14006f320
lea rdx, str.RUFUS_OFFLINE_HIVE
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegUnLoadKeyA]
test eax, eax
je 0x14006f2e3
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
mov rdx, rax
lea rcx, str.Could_not_unmount_offline_registry_hive:__s
call fcn.14004f2f0
jmp 0x14006f2fd
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
call fcn.14004fba0
movsxd rdx, edi
lea rcx, str.Could_not_set_HKLMSYSTEMSetupLabConfig_s_registry_key:__s
mov r8, rax
mov rdx, qword [rsi + rdx*8]
call fcn.14004f2f0
test r12b, 1
je 0x14006f018
test r15, r15
jne 0x14006f154
mov r8d, 0x386
lea rdx, str.D:_a_rufus_rufus_srcwue.c
lea rcx, str.mount_path___NULL
call fcn.1400fbe54
lea r9, str._sAutounattend.xml
mov qword [rsp + 0x20], r15
mov edx, 0x104
lea rcx, [rbp + 0x30]
mov r8, 0xffffffffffffffff
call fcn.140004fd0
mov rcx, qword [0x1401d05d0]
mov byte [rbp + 0x133], 0
call fcn.14006bbf0
lea rcx, [rbp + 0x30]
mov rdi, rax
call fcn.14006bbf0
mov r8d, 1
mov rdx, rax
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_CopyFileW]
mov esi, eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r14d, eax
test rdi, rdi
je 0x14006f1c1
mov rcx, rdi
call fcn.1400e8c70
test rbx, rbx
je 0x14006f1ce
mov rcx, rbx
call fcn.1400e8c70
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
test esi, esi
jne 0x14006f1f4
call fcn.14004fba0
mov rdx, rax
lea rcx, str.Could_not_create_boot.wim_Autounattend.xml:__s
call fcn.14004f2f0
jmp 0x14006f079
lea rcx, str.Added_Autounattend.xml_to__s
lea rdx, [rbp - 0x28]
jmp 0x14006f2ad
lea r9, str._c:_sources_OEM___Pantherunattend.xml
mov dword [rsp + 0x20], ebx
mov edx, 0x104
lea rcx, [rbp + 0x30]
mov r8, 0xffffffffffffffff
call fcn.140004fd0
mov rcx, qword [0x1401d05d0]
mov byte [rbp + 0x133], 0
call fcn.14006bbf0
lea rcx, [rbp + 0x30]
mov rdi, rax
call fcn.14006bbf0
mov r8d, 1
mov rdx, rax
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_CopyFileW]
mov esi, eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r14d, eax
test rdi, rdi
je 0x14006f270
mov rcx, rdi
call fcn.1400e8c70
test rbx, rbx
je 0x14006f27d
mov rcx, rbx
call fcn.1400e8c70
mov ecx, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
test esi, esi
jne 0x14006f2a2
call fcn.14004fba0
mov r8, rax
lea rdx, [rbp + 0x30]
lea rcx, str.Could_not_create__s:__s
jmp 0x14006f074
lea rcx, str.Created__s
lea rdx, [rbp + 0x30]
call fcn.14004f2f0
mov edx, 0xcfd
mov dword [rsp + 0x20], 1
mov ecx, 8
mov r9d, 0xcf
mov r8d, 0x67
call fcn.140066570
mov ebx, dword [rsp + 0x50]
mov edi, 1
jmp 0x14006f081
lea r8, str.RUFUS_OFFLINE_HIVE
lea rdx, str.HKLM
lea rcx, str.Unmounted_offline_registry_hive__s_s
call fcn.14004f2f0
mov edx, 0xcfd
mov dword [rsp + 0x20], 1
mov ecx, 8
mov r9d, 0xcf
mov r8d, 0x68
call fcn.140066570
test r15, r15
je 0x14006f4ee
mov r8d, ebx
lea rdx, [rbp - 0x28]
lea rcx, str.Unmounting__s__d_...
call fcn.14004f2f0
lea rax, [rbp - 0x28]
mov qword [rsp + 0x28], 0
lea r9, [rbp - 0x78]
mov qword [rbp - 0x70], rax
lea r8, [0x1400690d0]
mov dword [rsp + 0x58], 0
xor edx, edx
mov qword [rbp - 0x68], 0
xor ecx, ecx
mov dword [rbp - 0x78], ebx
mov dword [rbp - 0x74], 1
mov dword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [0x1401d05c8], rax
test rax, rax
jne 0x14006f39e
lea rcx, str.Unable_to_start_unmount_image_thread
call fcn.14004f2f0
jmp 0x14006f3dc
mov edx, dword [0x140196f64]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetThreadPriority]
mov rcx, qword [0x1401d05c8]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [0x1401d05c8]
lea rdx, [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov qword [0x1401d05c8], 0
cmp dword [0x1401a0460], 0
je 0x14006f4ce
xorps xmm0, xmm0
lea rcx, [rbp - 0x28]
xor eax, eax
movups xmmword [rbp - 0x60], xmm0
mov qword [rbp - 0x30], rax
movups xmmword [rbp - 0x50], xmm0
movups xmmword [rbp - 0x40], xmm0
call fcn.14006bbf0
lea rdx, [rbp - 0x60]
mov rcx, rax
mov rbx, rax
call fcn.1401073d4
test rbx, rbx
je 0x14006f423
mov rcx, rbx
call fcn.1400e8c70
mov rax, qword [rbp - 0x48]
add qword [0x1401e79b0], rax
mov rbx, qword [0x1401a0468]
test rbx, rbx
je 0x14006f4ce
mov eax, dword [0x1401a0474]
cmp dword [0x1401a0470], eax
jne 0x14006f484
add eax, eax
mov rcx, rbx
mov edx, eax
shl rdx, 3
mov dword [0x1401a0474], eax
call fcn.1400c5b50
mov qword [0x1401a0468], rax
test rax, rax
jne 0x14006f484
mov rcx, rbx
call fcn.1400e8c70
lea rcx, str.Could_not_reallocate_string_array
call fcn.14004f2f0
jmp 0x14006f4ce
lea rcx, [rbp - 0x28]
call fcn.1400fc834
mov edx, dword [0x1401a0470]
mov r8, rax
mov rax, qword [0x1401a0468]
mov qword [rax + rdx*8], r8
mov r9d, dword [0x1401a0470]
mov rax, qword [0x1401a0468]
cmp qword [rax + r9*8], 0
jne 0x14006f4c4
lea rcx, str.Could_not_store_string_in_array
call fcn.14004f2f0
jmp 0x14006f4ce
inc r9d
mov dword [0x1401a0470], r9d
mov r9d, 0xcf
mov dword [rsp + 0x20], 0
mov r8d, r9d
mov edx, 0xcfd
mov ecx, 8
call fcn.140066570
mov rcx, r15
call fcn.1400e8c70
mov rbx, qword [rsp + 0x2c8]
mov eax, edi
mov rcx, qword [rbp + 0x180]
xor rcx, rsp
call fcn.1400b2a30
add rsp, 0x2a0
pop r15
pop rdi
pop rbp
ret