Function at 0x14003da80
Capabilities:
Authenticate hmac
Check if file exists
Extract resource via kernel32 functions
Move file
Write file on windows

Disassembly:
mov rax, rsp
mov qword [rax + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0xf8]
sub rsp, 0x1c0
movaps xmmword [rax - 0x48], xmm6
movaps xmmword [rax - 0x58], xmm7
movaps xmmword [rax - 0x68], xmm8
movaps xmmword [rax - 0x78], xmm9
movaps xmmword [rax - 0x88], xmm10
movaps xmmword [rax - 0x98], xmm11
mov rax, qword [0x140106438]
xor rax, rsp
mov qword [rbp + 0x50], rax
cmp byte [0x14015b416], 0
mov r15d, 1
mov qword [rsp + 0x68], rcx
mov qword [rsp + 0x48], 0
jne 0x14003dafa
cmp dword [0x1401429c0], 0
je 0x14003e61e
mov qword [rsp + 0x28], rdx
lea r9, [0x1400dcc14]
mov edx, 0x40
mov qword [rsp + 0x20], rcx
lea rcx, [rbp + 0x10]
lea r8, [rdx - 0x41]
call fcn.1400034e0
lea rdx, [rsp + 0x48]
mov byte [rbp + 0x4f], 0
lea rcx, [rbp + 0x10]
call fcn.140041c50
mov dword [rsp + 0x50], eax
mov r13d, eax
test eax, eax
je 0x14003e61e
mov r14, qword [rsp + 0x48]
xor esi, esi
cmp dword [0x1401429d0], esi
jbe 0x14003dee2
lea r12d, [rsi + 0x57]
movabs r13, 0x7e0000007e03ff
nop
mov r8, qword [0x1401429c8]
xor edx, edx
mov rax, 0xffffffffffffffff
mov rcx, qword [r8 + rsi*8]
inc rax
cmp byte [rcx + rax], dl
jne 0x14003db74
test eax, eax
je 0x14003dbad
cmp byte [rdx + rcx], 0x5c
jne 0x14003db91
mov byte [rdx + rcx], 0x2f
mov r8, qword [0x1401429c8]
mov rcx, qword [r8 + rsi*8]
inc edx
mov rax, 0xffffffffffffffff
nop
inc rax
cmp byte [rcx + rax], 0
jne 0x14003dba0
cmp edx, eax
jb 0x14003db80
mov rdx, qword [r8 + rsi*8]
mov rcx, r14
add rdx, 2
call fcn.1400930e8
mov rbx, rax
test rax, rax
je 0x14003decf
test r15d, r15d
je 0x14003dbe1
lea rdx, [rbp + 0x10]
lea rcx, str.Updating__s:
call fcn.140041aa0
xor r15d, r15d
mov rcx, qword [0x1401429c8]
mov rdx, qword [rcx + rsi*8]
lea rcx, [0x1400e4e60]
add rdx, 2
call fcn.140041aa0
mov rdx, qword [0x1401429c8]
lea r8, [rsp + 0x78]
xor ecx, ecx
sub rbx, r14
mov rdx, qword [rdx + rsi*8]
call fcn.14003c000
test rbx, rbx
jle 0x14003dc32
lea rax, [r14 - 1]
add rax, rbx
cmp byte [rax], 0xa
je 0x14003dc32
dec rbx
dec rax
test rbx, rbx
jg 0x14003dc22
movzx eax, byte [rbx + r14]
sub al, 0x30
cmp al, 0x36
ja 0x14003dc43
bt r13, rax
jb 0x14003dc5c
mov r8d, 0x882
lea rdx, str.C:_src_r3dusb_srchash.c
lea rcx, str.IS_HEXASCII_md5_data_pos__
call fcn.1400a15c4
mov r10d, 3
lea r11, [rsp + 0x7a]
nop word [rax + rax]
movzx r8d, byte [r11 - 2]
lea r9d, [r10*2 - 6]
movzx eax, r8b
mov edx, r9d
and al, 0xf0
add rdx, rbx
cmp al, 0xa0
mov ecx, 0x30
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11 - 1]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r9 + 2]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r10*2 - 2]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11 + 1]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r10 + r10]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
mov byte [rdx + r14 + 1], cl
movzx r8d, byte [r11 + 2]
lea edx, [r10*2 + 2]
add rdx, rbx
lea r11, [r11 + 8]
movzx eax, r8b
mov ecx, 0x30
and al, 0xf0
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11 - 5]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r10*2 + 4]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11 - 4]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r10*2 + 6]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
movzx r8d, byte [r11 - 3]
mov byte [rdx + r14 + 1], cl
movzx eax, r8b
and al, 0xf0
lea edx, [r10*2 + 8]
add rdx, rbx
mov ecx, 0x30
cmp al, 0xa0
mov eax, r8d
cmovae ecx, r12d
shr eax, 4
add cl, al
movzx eax, r8b
mov byte [rdx + r14], cl
and al, 0xf
cmp al, 0xa
mov ecx, 0x30
cmovae ecx, r12d
and r8b, 0xf
add cl, r8b
mov byte [rdx + r14 + 1], cl
lea r10d, [r10 + 8]
lea eax, [r10 - 3]
cmp eax, 0x10
jb 0x14003dc70
inc esi
cmp esi, dword [0x1401429d0]
jb 0x14003db60
mov r13d, dword [rsp + 0x50]
cmp dword [0x1401429c0], 0
je 0x14003e57c
lea eax, [r13 + 0x400]
mov edi, r13d
mov ecx, eax
mov qword [rsp + 0x58], rdi
mov ebx, eax
call fcn.14009b5b4
mov qword [rsp + 0x78], rax
mov r15, rax
test rax, rax
jne 0x14003df32
mov r8d, 0x88d
lea rdx, str.C:_src_r3dusb_srchash.c
lea rcx, str.new_data___NULL
call fcn.1400a15c4
jmp 0x14003e61e
mov r9, qword [0x140159be8]
test r9, r9
je 0x14003df8f
lea r8, str._md5sum_totalbytes__0x_llx_n
mov rdx, rbx
mov rcx, r15
call fcn.140037d60
mov rdi, 0xffffffffffffffff
nop word [rax + rax]
inc rdi
cmp byte [r15 + rdi], 0
jne 0x14003df60
add edi, r13d
mov rsi, 0xffffffffffffffff
mov qword [rsp + 0x58], rdi
nop dword [rax]
inc rsi
cmp byte [r15 + rsi], 0
jne 0x14003df80
add rsi, r15
jmp 0x14003df92
mov rsi, r15
movsd xmm9, qword [0x1400f64b8]
lea rbx, str.boot.efi
movsd xmm8, qword [0x1400f6440]
mov eax, 1
movsd xmm10, qword [0x1400f6498]
mov r12, r14
movsd xmm11, qword [0x1400f6468]
mov r14d, 0x258
mov dword [rsp + 0x40], eax
nop
mov r13d, eax
lea r9, str._sefi_boot_s
mov edx, 0x40
lea rcx, [rbp - 0x70]
mov rax, qword [rbx + r13*8]
mov qword [rsp + 0x28], rax
lea r8, [rdx - 0x41]
mov rax, qword [rsp + 0x68]
mov qword [rsp + 0x20], rax
call fcn.1400034e0
lea rcx, [rbp - 0x70]
mov byte [rbp - 0x31], 0
call qword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x14003e3e2
movzx eax, word [rsp + 0x40]
xor r15d, r15d
mov r13, qword [rbx + r13*8]
add ax, r14w
mov rbx, qword [0x14015a338]
movzx edx, ax
mov rcx, rbx
lea r8d, [r15 + 0xa]
mov qword [rsp + 0x70], r15
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov r14, rax
test rax, rax
jne 0x14003e062
call fcn.140041e50
mov r8, rax
lea rcx, str.Could_not_locate_resource__s:__s
mov rdx, r13
call fcn.140041aa0
jmp 0x14003e0b0
mov rdx, r14
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov r15, rax
test rax, rax
jne 0x14003e094
call fcn.140041e50
mov r8, rax
lea rcx, str.Could_not_load_resource__s:__s
mov rdx, r13
call fcn.140041aa0
mov r15, qword [rsp + 0x70]
jmp 0x14003e0b0
mov rdx, r14
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov rcx, r15
mov dword [rsp + 0x60], eax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov r15, rax
lea rcx, [rbp - 0x70]
mov rax, 0xffffffffffffffff
nop dword [rax + rax]
inc rax
cmp byte [rcx + rax], 0
jne 0x14003e0c0
inc rax
lea rdx, [rbp - 0x70]
mov ebx, 0x40
lea rcx, [rbp - 0x30]
cmp rax, rbx
cmovb rbx, rax
mov r8, rbx
call fcn.140093550
lea rcx, [rbp - 0x30]
mov byte [rbp + rbx - 0x31], 0
mov rax, 0xffffffffffffffff
nop dword [rax + rax]
inc rax
cmp byte [rcx + rax], 0
jne 0x14003e100
sub rax, 4
cmp rax, 0x40
jae 0x14003e686
mov r9, 0xffffffffffffffff
mov byte [rbp + rax - 0x30], 0
lea r8, str._original.efi
lea rcx, [rbp - 0x30]
lea edx, [r9 + 0x41]
call fcn.14009b5bc
test r15, r15
je 0x14003e3c1
lea rcx, [rbp - 0x70]
call fcn.140003550
lea rcx, [rbp - 0x30]
mov rbx, rax
call fcn.140003550
mov rdx, rax
mov rcx, rbx
mov r14, rax
call qword [sym.imp.KERNEL32.dll_MoveFileW]
mov r13d, eax
test r14, r14
je 0x14003e174
mov rcx, r14
call fcn.14009b5a0
test rbx, rbx
je 0x14003e181
mov rcx, rbx
call fcn.14009b5a0
test r13d, r13d
je 0x14003e3c1
lea r8, [rbp - 0x30]
lea rdx, [rbp - 0x70]
lea rcx, str.Renamed:__s___s
call fcn.140041aa0
xor r9d, r9d
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
lea rcx, [rbp - 0x70]
mov edx, 0xc0000000
mov dword [rsp + 0x20], 2
lea r8d, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbx, rax
lea rcx, [rax - 1]
cmp rcx, 0xfffffffffffffffd
ja 0x14003e369
mov r14d, dword [rsp + 0x60]
xor r9d, r9d
mov r8d, r14d
mov rdx, r15
mov rcx, rax
call fcn.140042b10
test eax, eax
jne 0x14003e260
call fcn.140041e50
mov r8, rax
lea rdx, [rbp - 0x70]
lea rcx, str.Could_not_write__s:__s.
call fcn.140041aa0
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, [rbp - 0x30]
call fcn.140003550
lea rcx, [rbp - 0x70]
mov rbx, rax
call fcn.140003550
mov rdx, rax
mov rcx, rbx
mov r14, rax
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test r14, r14
je 0x14003e24a
mov rcx, r14
call fcn.14009b5a0
test rbx, rbx
je 0x14003e3d5
mov rcx, rbx
call fcn.14009b5a0
jmp 0x14003e3d5
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [0x1401128e0], 0
lea rax, [0x1400d756a]
mov rcx, r14
xorps xmm7, xmm7
lea r14, [0x1400e6704]
cmove r14, rax
test rcx, rcx
js 0x14003e294
cvtsi2sd xmm7, rcx
jmp 0x14003e2a9
mov rax, rcx
and ecx, 1
shr rax, 1
or rax, rcx
cvtsi2sd xmm7, rax
addsd xmm7, xmm7
mov r15, qword [0x140111658]
xor ebx, ebx
comisd xmm9, xmm7
ja 0x14003e2c7
inc rbx
mulsd xmm7, xmm8
cmp rbx, 5
jl 0x14003e2b2
test rbx, rbx
jne 0x14003e2ee
mov rax, qword [r15 + 0xa0]
lea r9, str._s_d_s__s
mov qword [rsp + 0x38], rax
cvttsd2si ecx, xmm7
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], ecx
jmp 0x14003e336
movaps xmm6, xmm7
movaps xmm0, xmm7
mulsd xmm6, xmm10
call fcn.1400bf1f0
lea rax, str._s_0.0f_s__s
mulsd xmm0, xmm10
lea r9, str._s_0.1f_s__s
subsd xmm6, xmm0
comisd xmm11, xmm6
cmova r9, rax
mov rax, qword [r15 + rbx*8 + 0xa0]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], r14
movsd qword [rsp + 0x28], xmm7
mov r8, 0xffffffffffffffff
mov qword [rsp + 0x20], r14
lea rcx, [0x140155350]
lea edx, [r8 + 0x21]
call fcn.1400034e0
lea r8, [0x140155350]
mov byte [0x14015536f], 0
lea rcx, str.Created:__s___s_
jmp 0x14003e3cc
call fcn.140041e50
mov r8, rax
lea rdx, [rbp - 0x70]
lea rcx, str.Could_not_create__s:__s.
call fcn.140041aa0
lea rcx, [rbp - 0x30]
call fcn.140003550
lea rcx, [rbp - 0x70]
mov rbx, rax
call fcn.140003550
mov rdx, rax
mov rcx, rbx
mov r14, rax
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test r14, r14
je 0x14003e3b2
mov rcx, r14
call fcn.14009b5a0
test rbx, rbx
je 0x14003e3d5
mov rcx, rbx
call fcn.14009b5a0
jmp 0x14003e3d5
lea r8, [rbp - 0x30]
lea rcx, str.Could_not_rename:__s___s
lea rdx, [rbp - 0x70]
call fcn.140041aa0
mov r14d, 0x258
lea rbx, str.boot.efi
mov eax, dword [rsp + 0x40]
inc eax
mov dword [rsp + 0x40], eax
cmp eax, 0xa
jb 0x14003dfd0
mov rbx, qword [rsp + 0x48]
lea rdx, str._._efi_boot_boot
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_StrStrIA]
mov r14, rax
test rax, rax
je 0x14003e556
nop word [rax + rax]
lea r15, str.bootia32.efi
mov r13d, 9
nop dword [rax]
mov rdx, qword [r15]
mov rax, 0xffffffffffffffff
nop word [rax + rax]
cmp byte [rdx + rax + 1], 0
lea rax, [rax + 1]
jne 0x14003e440
cmp byte [rax + r14 + 0xc], 0xa
jne 0x14003e521
mov rax, 0xffffffffffffffff
nop
cmp byte [rdx + rax + 1], 0
lea rax, [rax + 1]
jne 0x14003e460
lea rcx, [r14 + 0xc]
mov byte [rax + r14 + 0xc], 0
call qword [sym.imp.KERNEL32.dll_lstrcmpiA]
mov rdi, qword [r15]
test eax, eax
jne 0x14003e503
mov rcx, 0xffffffffffffffff
nop dword [rax]
inc rcx
cmp byte [rdi + rcx], 0
jne 0x14003e490
add rcx, 8
mov rax, r14
sub rax, r12
mov rdx, r12
add rax, rcx
mov rcx, rsi
mov r8d, eax
mov ebx, eax
call fcn.140093550
movsd xmm0, qword [str._original.efi_n]
add rsi, rbx
add dword [rsp + 0x58], 9
movsd qword [rsi], xmm0
mov eax, dword [0x1400e4ff0]
mov dword [rsi + 8], eax
movzx eax, word [0x1400e4ff4]
mov word [rsi + 0xc], ax
movzx eax, byte [0x1400e4ff6]
mov byte [rsi + 0xe], al
add rsi, 0xe
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rdi + rax], 0
jne 0x14003e4f3
lea r12, [r14 + 0xd]
add r12, rax
mov rax, 0xffffffffffffffff
nop word [rax + rax]
cmp byte [rdi + rax + 1], 0
lea rax, [rax + 1]
jne 0x14003e510
mov byte [rax + r14 + 0xc], 0xa
add r15, 8
sub r13, 1
jne 0x14003e430
lea rcx, [r14 + 0xc]
lea rdx, str._._efi_boot_boot
call qword [sym.imp.SHLWAPI.dll_StrStrIA]
mov r14, rax
test rax, rax
jne 0x14003e420
mov rdi, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x48]
mov r8d, dword [rsp + 0x50]
mov rdx, r12
sub r8, r12
mov rcx, rsi
add r8, rbx
call fcn.140093550
mov rcx, rbx
call fcn.14009b5a0
mov r14, qword [rsp + 0x78]
mov r13d, edi
lea rcx, [rbp + 0x10]
mov qword [rsp + 0x48], 0
call fcn.140003550
lea rcx, [0x1400dcc1c]
mov rdi, rax
call fcn.140003550
mov r8, rax
lea rcx, [rsp + 0x48]
mov rdx, rdi
mov rbx, rax
call fcn.14009b840
test rdi, rdi
je 0x14003e5bd
mov rcx, rdi
call fcn.14009b5a0
test rbx, rbx
je 0x14003e5ca
mov rcx, rbx
call fcn.14009b5a0
mov rbx, qword [rsp + 0x48]
test rbx, rbx
jne 0x14003e5e6
lea rdx, [rbp + 0x10]
lea rcx, str.Error:_Cant_create__s
call fcn.140041aa0
jmp 0x14003e616
mov r8d, r13d
mov r9, rbx
mov edx, 1
mov rcx, r14
call fcn.1400a6548
cmp eax, r13d
je 0x14003e60e
lea rdx, [rbp + 0x10]
lea rcx, str.Error:_Cant_write__s
call fcn.140041aa0
mov rcx, rbx
call fcn.14009b928
mov rcx, r14
call fcn.14009b5a0
lea rcx, [0x1401429c8]
call fcn.14003ff20
mov rcx, qword [0x1401429c8]
call fcn.14009b5a0
mov qword [0x1401429c8], 0
mov rcx, qword [rbp + 0x50]
xor rcx, rsp
call fcn.140092060
lea r11, [rsp + 0x1c0]
mov rbx, qword [r11 + 0x50]
movaps xmm6, xmmword [r11 - 0x10]
movaps xmm7, xmmword [r11 - 0x20]
movaps xmm8, xmmword [r11 - 0x30]
movaps xmm9, xmmword [r11 - 0x40]
movaps xmm10, xmmword [r11 - 0x50]
movaps xmm11, xmmword [r11 - 0x60]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.140092188
int3