Function at 0x14005b280
Capabilities:
Open clipboard
Read clipboard data

Disassembly:
push rbx
push rdi
push r13
sub rsp, 0x150
mov rax, qword [0x140131048]
xor rax, rsp
mov qword [rsp + 0x100], rax
mov qword [rsp + 0x68], rdx
mov rbx, r9
movsxd r9, r8d
mov r13, rdx
lea r10, [0x140000000]
test r8d, r8d
je 0x14005b9ec
cmp byte [r9 + r10 + 0x1325a0], 0
je 0x14005b2ef
mov r8, qword [0x140105858]
mov rax, rbx
sub r8, rbx
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x14005b2e7
inc rax
test ecx, ecx
jne 0x14005b2d4
test edx, edx
je 0x14005b9ec
xor ecx, ecx
call qword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x14005ba8b
mov r8, qword [0x140105858]
mov rax, rbx
sub r8, rbx
nop dword [rax]
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x14005b323
inc rax
test ecx, ecx
jne 0x14005b310
mov qword [rsp + 0x170], rbp
mov qword [rsp + 0x148], rsi
test edx, edx
jne 0x14005b422
mov ecx, 0xd
call qword [sym.imp.USER32.dll_GetClipboardData]
mov rbp, rax
test rax, rax
je 0x14005b9d1
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GlobalLock]
mov rsi, rax
mov rbx, 0xffffffffffffffff
inc rbx
cmp word [rax + rbx*2], 0
jne 0x14005b365
lea rcx, [rbx*4 + 1]
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
lea edx, [rbx*4]
mov r9d, ebx
mov r8, rsi
mov rcx, rax
mov rdi, rax
call fcn.140081100
mov ecx, eax
mov byte [rcx + rdi], 0
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GlobalUnlock]
movzx r8d, byte [rdi]
mov rdx, rdi
mov rax, rdi
test r8b, r8b
je 0x14005b3dd
lea rcx, [rax + 1]
cmp r8b, 0xd
jne 0x14005b3c9
cmp byte [rcx], 0xa
jne 0x14005b3c9
mov rax, rcx
mov r8b, 0xa
jmp 0x14005b3b2
movzx eax, byte [rax]
mov byte [rdx], al
inc rdx
movzx r8d, byte [rcx]
mov rax, rcx
test r8b, r8b
jne 0x14005b3b2
mov byte [rdx], 0
mov rcx, r13
mov rax, qword [0x140105858]
sub edx, edi
mov dword [0x140131efc], edx
mov edx, select
mov qword [0x14012d570], rax
mov qword [0x14012d568], rdi
mov rax, qword [r13]
call qword [rax + select]
mov rcx, rdi
call fcn.1400466d0
xor edi, edi
mov qword [0x14012d568], rdi
jmp 0x14005b9d1
mov rdx, qword [str.image]
sub rdx, rbx
nop dword [rax]
movzx ecx, byte [rbx]
movzx eax, byte [rbx + rdx]
sub ecx, eax
jne 0x14005b442
inc rbx
test eax, eax
jne 0x14005b430
test ecx, ecx
jne 0x14005b9d1
mov qword [rsp + 0x140], r12
mov ecx, 8
mov qword [rsp + 0x138], r14
mov qword [rsp + 0x130], r15
call qword [sym.imp.USER32.dll_GetClipboardData]
mov qword [rsp + 0x78], rax
test rax, rax
je 0x14005b746
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GlobalLock]
mov rsi, rax
movzx edx, word [rax + 0xe]
mov r14d, dword [rax + 4]
mov ebp, dword [rax + 8]
mov eax, 0xfff7
lea ecx, [rdx - 0x18]
test ax, cx
jne 0x14005b5f4
cmp dword [rsi + 0x10], 0
jne 0x14005b5f4
cmp dword [rsi + 0x20], 0
jne 0x14005b5f4
mov r12d, edx
shr r12d, 3
cmp r12d, 3
jne 0x14005b4d9
lea eax, [r14 + 1]
lea eax, [rax + rax*2]
cdq
and edx, r12d
lea r13d, [rdx + rax]
sar r13d, 2
jmp 0x14005b4dc
mov r13d, r14d
mov eax, ebp
neg eax
cmovs eax, ebp
imul eax, r12d
imul eax, r14d
movsxd rcx, eax
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
mov qword [rsp + 0x70], rax
mov r9, rax
test ebp, ebp
mov eax, 1
mov rbx, 0xffffffffffffffff
cmovg eax, ebx
mov dword [rsp + 0x60], eax
jle 0x14005b51d
xor edi, edi
lea r11d, [rbp - 1]
mov r15d, edi
jmp 0x14005b528
xor edi, edi
mov r15d, ebp
mov r11d, edi
not r15d
mov ebx, r13d
imul r13d, eax
imul ebx, r11d
shl ebx, 2
shl r13d, 2
nop word [rax + rax]
mov eax, edi
test ebp, ebp
jle 0x14005b54e
cmp r11d, r15d
setge al
jmp 0x14005b554
cmp r11d, r15d
setle al
test eax, eax
je 0x14005b6da
movsxd r8, ebx
add r8, 0x28
add r8, rsi
test r14d, r14d
jle 0x14005b5e7
mov r10, r14
cmp r12d, 4
jne 0x14005b5c0
nop dword [rax]
nop dword [rax + rax]
movzx eax, byte [r8 + 2]
movzx edx, byte [r8]
movzx ecx, byte [r8 + 1]
lea r8, [r8 + 4]
mov byte [r9], al
mov byte [r9 + 1], cl
mov byte [r9 + 2], dl
movzx eax, byte [r8 - 1]
mov byte [r9 + 3], al
add r9, 4
sub r10, 1
jne 0x14005b580
add r11d, dword [rsp + 0x60]
add ebx, r13d
jmp 0x14005b540
movzx eax, byte [r8 + 2]
movzx edx, byte [r8]
movzx ecx, byte [r8 + 1]
lea r8, [r8 + 3]
mov byte [r9], al
mov byte [r9 + 1], cl
mov byte [r9 + 2], dl
add r9, 3
sub r10, 1
jne 0x14005b5c0
add r11d, dword [rsp + 0x60]
add ebx, r13d
jmp 0x14005b540
cmp dword [rsi + 0x10], 3
lea r12, [rsi + 0x428]
jne 0x14005b607
lea r12, [rsi + 0x34]
jmp 0x14005b616
mov eax, dword [rsi + 0x20]
test eax, eax
je 0x14005b616
lea r12, [rax + 0xa]
lea r12, [rsi + r12*4]
mov ecx, 0x20
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
test rax, rax
je 0x14005b649
mov r8d, ebp
mov edx, r14d
neg r8d
mov rcx, rax
cmovs r8d, ebp
xor edi, edi
xor r9d, r9d
mov qword [rsp + 0x20], rdi
call fcn.14008eb80
mov r15, rax
jmp 0x14005b64e
xor edi, edi
mov r15d, edi
mov rcx, r15
call fcn.14008b8b0
mov rcx, qword [0x1401335e0]
mov ebx, ebp
neg ebx
cmovs ebx, ebp
mov rax, qword [rcx]
call qword [rax + 0x2e0]
mov dword [rsp + 0x58], edi
mov r9d, r14d
mov qword [rsp + 0x50], rsi
mov rcx, rax
mov qword [rsp + 0x48], r12
xor r8d, r8d
mov dword [rsp + 0x40], ebx
xor edx, edx
mov dword [rsp + 0x38], edi
mov dword [rsp + 0x30], edi
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], ebx
call qword [sym.imp.GDI32.dll_SetDIBitsToDevice]
mov r9d, r14d
mov dword [rsp + 0x28], edi
xor r8d, r8d
mov dword [rsp + 0x20], ebx
xor edx, edx
xor ecx, ecx
call fcn.14008ba60
mov rbx, rax
mov r12d, 3
call fcn.14008b870
test r15, r15
je 0x14005b6e4
mov rax, qword [r15]
mov edx, 1
mov rcx, r15
call qword [rax + 0x18]
jmp 0x14005b6e4
mov r13, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x70]
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_GlobalUnlock]
test rbx, rbx
je 0x14005b9b9
mov ecx, 0x58
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
test rax, rax
je 0x14005b737
mov r9d, ebp
mov dword [rsp + 0x28], edi
neg r9d
mov dword [rsp + 0x20], r12d
mov r8d, r14d
mov rdx, rbx
cmovs r9d, ebp
mov rcx, rax
call fcn.14004e7e0
mov rbx, rax
mov dword [rax + 0x38], 1
jmp 0x14005b96e
mov rbx, rdi
mov dword [rbx + 0x38], 1
jmp 0x14005b96e
mov ecx, select
call qword [sym.imp.USER32.dll_GetClipboardData]
mov r14, rax
test rax, rax
je 0x14005b9b9
movaps xmmword [rsp + 0x120], xmm6
lea r8, [rsp + 0x90]
mov edx, 0x6c
movaps xmmword [rsp + 0x110], xmm7
mov rcx, rax
call qword [sym.imp.GDI32.dll_GetEnhMetaFileHeader]
mov ebp, dword [rsp + 0xb0]
xor ecx, ecx
mov r15d, dword [rsp + 0xb4]
sub ebp, dword [rsp + 0xa8]
sub r15d, dword [rsp + 0xac]
inc ebp
inc r15d
call qword [sym.imp.USER32.dll_GetDC]
mov rcx, rax
mov edx, 4
mov rsi, rax
call qword [sym.imp.GDI32.dll_GetDeviceCaps]
mov edx, 8
mov rcx, rsi
movd xmm7, eax
call qword [sym.imp.GDI32.dll_GetDeviceCaps]
mov rdx, rsi
xor ecx, ecx
mov ebx, eax
call qword [sym.imp.USER32.dll_ReleaseDC]
cvtdq2ps xmm7, xmm7
movd xmm0, ebx
mulss xmm7, dword [0x140106a24]
cvtdq2ps xmm0, xmm0
divss xmm7, xmm0
call fcn.140052140
mov rcx, r13
mov rdi, rax
call fcn.14005e300
mov rbx, qword [rdi]
mov rcx, qword [rax + 0xd0]
call fcn.140087b70
mov edx, eax
mov rcx, rdi
call qword [rbx + select]
movaps xmm6, xmm0
call fcn.14005db80
test rax, rax
jne 0x14005b83c
call fcn.140061710
movaps xmm1, xmm6
mov rcx, rax
mov rdx, qword [rax]
call qword [rdx + 0xa8]
movd xmm0, ebp
movaps xmm2, xmm6
mulss xmm2, xmm7
xor edi, edi
mov ecx, 0x20
mov qword [rsp + 0x78], rdi
movd xmm1, r15d
cvtdq2ps xmm0, xmm0
cvtdq2ps xmm1, xmm1
divss xmm0, xmm2
divss xmm1, xmm2
cvttss2si ebx, xmm0
cvttss2si ebp, xmm1
mov dword [rsp + 0x80], ebx
mov dword [rsp + 0x84], ebp
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
movaps xmm7, xmmword [rsp + 0x110]
test rax, rax
je 0x14005b8ab
mov r9d, 1
mov qword [rsp + 0x20], rdi
mov r8d, ebp
mov edx, ebx
mov rcx, rax
call fcn.14008eb80
mov rsi, rax
jmp 0x14005b8ae
mov rsi, rdi
mov rcx, rsi
call fcn.14008b8b0
mov rcx, qword [0x1401335e0]
mov edx, 0xff
mov rax, qword [rcx]
call qword [rax + 0x260]
mov rcx, qword [0x1401335e0]
mov r9d, ebx
xor r8d, r8d
mov dword [rsp + 0x20], ebp
xor edx, edx
mov rax, qword [rcx]
call qword [rax + 0xd0]
movd xmm0, dword [rsp + 0x80]
movd xmm1, dword [rsp + 0x84]
mov rcx, qword [0x1401335e0]
cvtdq2ps xmm0, xmm0
cvtdq2ps xmm1, xmm1
mulss xmm0, xmm6
mulss xmm1, xmm6
cvttss2si eax, xmm0
mov dword [rsp + 0x80], eax
cvttss2si eax, xmm1
mov dword [rsp + 0x84], eax
mov rax, qword [rcx]
call qword [rax + 0x2e0]
lea r8, [rsp + 0x78]
mov rdx, r14
mov rcx, rax
call qword [sym.imp.GDI32.dll_PlayEnhMetaFile]
mov rcx, rsi
call fcn.14008ef50
mov rbx, rax
call fcn.14008b870
movaps xmm6, xmmword [rsp + 0x120]
test rsi, rsi
je 0x14005b969
mov rax, qword [rsi]
mov edx, 1
mov rcx, rsi
call qword [rax + 0x18]
test rbx, rbx
je 0x14005b9b9
mov rax, qword [str.image]
mov edx, select
mov qword [0x14012d570], rax
mov rcx, r13
mov qword [0x140131f00], rbx
mov rax, qword [r13]
call qword [rax + select]
lea rcx, [0x140105588]
mov qword [0x14012d570], rcx
test eax, eax
jne 0x14005b9b9
mov qword [0x140131f00], rdi
mov edx, 1
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 0x18]
mov r14, qword [rsp + 0x138]
mov r12, qword [rsp + 0x140]
mov r15, qword [rsp + 0x130]
call qword [sym.imp.USER32.dll_CloseClipboard]
mov rsi, qword [rsp + 0x148]
mov rbp, qword [rsp + 0x170]
jmp 0x14005ba8b
mov rbx, qword [r10 + r9*8 + 0x132580]
test rbx, rbx
je 0x14005ba82
mov eax, dword [r10 + r9*4 + 0x132590]
inc eax
movsxd rcx, eax
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
movzx r8d, byte [rbx]
mov rdi, rax
mov rdx, rax
test r8b, r8b
je 0x14005ba4b
nop
lea rcx, [rbx + 1]
cmp r8b, 0xd
jne 0x14005ba37
cmp byte [rcx], 0xa
jne 0x14005ba37
mov rbx, rcx
mov r8b, 0xa
jmp 0x14005ba20
movzx eax, byte [rbx]
mov rbx, rcx
mov byte [rdx], al
inc rdx
movzx r8d, byte [rcx]
test r8b, r8b
jne 0x14005ba20
mov byte [rdx], 0
mov rcx, r13
mov rax, qword [0x140105858]
sub edx, edi
mov dword [0x140131efc], edx
mov edx, select
mov qword [0x14012d570], rax
mov qword [0x14012d568], rdi
mov rax, qword [r13]
call qword [rax + select]
mov rcx, rdi
call fcn.1400466d0
xor edi, edi
mov qword [0x14012d568], rdi
mov rcx, qword [rsp + 0x100]
xor rcx, rsp
call fcn.1400ea730
add rsp, 0x150
pop r13
pop rdi
pop rbx
ret