Function at 0x140058440
Capabilities:
Copy file

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x2d0
mov rax, qword [0x140106438]
xor rax, rsp
mov qword [rsp + 0x2a0], rax
xorps xmm0, xmm0
xor eax, eax
xor ebx, ebx
mov qword [rsp + 0x70], rax
cmp dword [0x14015a218], 1
mov rdi, rcx
movups xmmword [rsp + 0x40], xmm0
movups xmmword [rsp + 0x50], xmm0
movups xmmword [rsp + 0x60], xmm0
jne 0x140058785
cmp byte [0x14015b41d], al
je 0x140058785
cmp word [0x14015b42e], 0xa
jb 0x140058785
cmp dword [0x1401429c4], eax
je 0x140058785
cmp dword [0x140142ab8], eax
je 0x140058785
lea rax, [0x140159ea0]
mov qword [rsp + 0x2f0], rsi
lea r9, str._sSecureBootUpdatesSKUSiPolicy.p7b
mov qword [rsp + 0x20], rax
mov edx, 0x104
lea r8, [rbx - 1]
lea rcx, [rsp + 0x80]
call fcn.1400034e0
lea r9, str._sEFIMicrosoftBootSKUSiPolicy.p7b
mov byte [rsp + 0x183], bl
mov edx, 0x104
mov qword [rsp + 0x20], rdi
lea r8, [rbx - 1]
lea rcx, [rsp + 0x190]
call fcn.1400034e0
lea rcx, [rsp + 0x190]
mov byte [rsp + 0x293], bl
call fcn.140003550
lea rdx, [rsp + 0x40]
mov rcx, rax
mov rdi, rax
call fcn.1400a5624
mov esi, eax
test rdi, rdi
je 0x140058549
mov rcx, rdi
call fcn.14009b5a0
test esi, esi
je 0x14005877b
lea rcx, [rsp + 0x80]
call fcn.140003550
lea rdx, [rsp + 0x40]
mov rcx, rax
mov rdi, rax
call fcn.1400a5624
mov esi, eax
test rdi, rdi
je 0x14005857d
mov rcx, rdi
call fcn.14009b5a0
test esi, esi
jne 0x14005877b
cmp dword [0x1401128e0], ebx
lea rdi, [0x1400e6704]
mov rcx, qword [rsp + 0x58]
lea rax, [0x1400d756a]
cmove rdi, rax
mov qword [rsp + 0x2e8], rbp
movaps xmmword [rsp + 0x2b0], xmm8
xorps xmm8, xmm8
test rcx, rcx
js 0x1400585c3
cvtsi2sd xmm8, rcx
jmp 0x1400585d9
mov rax, rcx
and ecx, 1
shr rax, 1
or rax, rcx
cvtsi2sd xmm8, rax
addsd xmm8, xmm8
mov rsi, qword [0x140111658]
movsd xmm1, qword [0x1400f64b8]
movsd xmm0, qword [0x1400f6440]
comisd xmm1, xmm8
ja 0x140058603
inc ebx
mulsd xmm8, xmm0
cmp ebx, 5
jl 0x1400585f0
test ebx, ebx
jne 0x140058645
mov rax, qword [rsi + 0xa0]
lea edx, [rbx + 0x20]
mov qword [rsp + 0x38], rax
lea r9, str._s_d_s__s
cvttsd2si ecx, xmm8
mov qword [rsp + 0x30], rdi
lea r8, [rdx - 0x21]
mov dword [rsp + 0x28], ecx
lea rcx, [0x140155350]
mov qword [rsp + 0x20], rdi
call fcn.1400034e0
jmp 0x1400586ca
movaps xmmword [rsp + 0x2c0], xmm7
movaps xmm0, xmm8
movaps xmm7, xmm8
movsxd rbx, ebx
mulsd xmm7, qword [0x1400f6498]
call fcn.1400bf1f0
mulsd xmm0, qword [0x1400f6498]
lea rax, str._s_0.0f_s__s
mov edx, 0x20
lea r9, str._s_0.1f_s__s
lea rcx, [0x140155350]
subsd xmm7, xmm0
movsd xmm0, qword [0x1400f6468]
lea r8, [rdx - 0x21]
comisd xmm0, xmm7
cmova r9, rax
mov rax, qword [rsi + rbx*8 + 0xa0]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rdi
movsd qword [rsp + 0x28], xmm8
mov qword [rsp + 0x20], rdi
call fcn.1400034e0
movaps xmm7, xmmword [rsp + 0x2c0]
lea r9, [rsp + 0x80]
mov byte [0x14015536f], 0
lea r8, [0x140155350]
lea rdx, [rsp + 0x190]
lea rcx, str.Copying:__s___s___from__s_
call fcn.140041aa0
lea rcx, [rsp + 0x80]
call fcn.140003550
lea rcx, [rsp + 0x190]
mov rsi, rax
call fcn.140003550
mov r8d, 1
mov rdx, rax
mov rcx, rsi
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_CopyFileW]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
movaps xmm8, xmmword [rsp + 0x2b0]
mov ebp, eax
test rsi, rsi
je 0x140058746
mov rcx, rsi
call fcn.14009b5a0
test rdi, rdi
je 0x140058753
mov rcx, rdi
call fcn.14009b5a0
mov ecx, ebp
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rbp, qword [rsp + 0x2e8]
test ebx, ebx
jne 0x14005877b
call fcn.140041e50
mov rdx, rax
lea rcx, str.__Error_writing_file:__s
call fcn.140041aa0
mov rsi, qword [rsp + 0x2f0]
mov eax, ebx
mov rcx, qword [rsp + 0x2a0]
xor rcx, rsp
call fcn.140092060
mov rbx, qword [rsp + 0x2f8]
add rsp, 0x2d0
pop rdi
ret