Function at 0x10100370
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
mov eax, dword [ebp + 8]
movaps xmm0, xmmword [0x103e9af0]
mov ecx, dword [ebp + 0x14]
push ebx
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0x18]
mov ebx, edi
imul ebx, esi
cmp dword [ebp + 0xc], 0
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x50], eax
mov eax, dword [0x108624e8]
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x20], edi
movups xmmword [ebp - 0x64], xmm0
mov dword [ebp - 0x54], 6
mov dword [ebp - 8], 0x474e5089
mov dword [ebp - 4], 0xa1a0a0d
mov dword [ebp - 0x3c], ebx
jne 0x101003cf
mov dword [ebp + 0xc], ebx
jmp 0x101003d2
mov dword [ebp - 0x3c], ebx
or edx, 0xffffffff
cmp eax, 5
cmovge eax, edx
mov dword [ebp - 0x44], eax
lea eax, [ebx + 1]
mov dword [ebp - 0x4c], eax
imul eax, ecx
cmovo eax, edx
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
add esp, 4
mov dword [ebp - 0x38], eax
test eax, eax
je 0x10100425
mov ecx, esi
mov eax, 0xffffffff
imul ecx, edi
cmovo ecx, eax
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edi, eax
add esp, 4
test edi, edi
jne 0x1010042e
mov ecx, dword [ebp - 0x38]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0xc]
xor edx, edx
mov dword [ebp - 0x10], edx
test eax, eax
jle 0x101005f7
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x34], ecx
mov ecx, dword [ebp - 0x44]
cmp ecx, 0xffffffff
jle 0x1010046a
push edi
push ecx
push dword [ebp - 0x20]
mov dword [ebp - 0x18], ecx
push edx
push eax
push esi
push dword [ebp + 0xc]
push dword [ebp - 0x2c]
call fcn.100ff7a0
mov ecx, dword [ebp - 0x18]
jmp 0x101005cb
xor ecx, ecx
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x14], accept
mov dword [ebp - 0x18], ecx
jmp 0x10100483
mov eax, dword [ebp - 0xc]
push edi
push ecx
push dword [ebp - 0x20]
push edx
push eax
push esi
push dword [ebp + 0xc]
push dword [ebp - 0x2c]
call fcn.100ff7a0
xor esi, esi
add esp, 0x20
xor ecx, ecx
mov dword [ebp - 0x40], esi
test ebx, ebx
jle 0x10100519
cmp ebx, 8
jb 0x10100519
cmp dword [0x1089c988], 2
jl 0x10100519
mov eax, ebx
and eax, reloc.WS2_32.dll_getsockopt
jns 0x101004c0
dec eax
or eax, 0xfffffff8
inc eax
mov edx, ebx
xorps xmm1, xmm1
sub edx, eax
xorps xmm2, xmm2
nop word [eax + eax]
pmovsxbd xmm0, dword [ecx + edi]
pabsd xmm0, xmm0
paddd xmm1, xmm0
pmovsxbd xmm0, dword [ecx + edi + 4]
add ecx, 8
pabsd xmm0, xmm0
paddd xmm2, xmm0
cmp ecx, edx
jl 0x101004d0
paddd xmm1, xmm2
movaps xmm0, xmm1
psrldq xmm0, 8
paddd xmm1, xmm0
movups xmm0, xmm1
psrldq xmm0, 4
paddd xmm1, xmm0
movd esi, xmm1
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x28], 0
cmp ecx, ebx
jge 0x10100582
mov eax, ebx
sub eax, ecx
cmp eax, 2
jl 0x1010056f
lea eax, [ebx - 1]
mov ebx, dword [ebp - 0x24]
mov dword [ebp - 0x48], eax
mov esi, ebx
nop
movsx eax, byte [ecx + edi]
cdq
xor eax, edx
sub eax, edx
add ebx, eax
movsx eax, byte [ecx + edi + 1]
cdq
add ecx, 2
xor eax, edx
sub eax, edx
add esi, eax
cmp ecx, dword [ebp - 0x48]
jl 0x10100540
mov dword [ebp - 0x24], ebx
mov ebx, dword [ebp - 0x3c]
mov dword [ebp - 0x28], esi
mov esi, dword [ebp - 0x40]
cmp ecx, ebx
jge 0x1010057a
movsx eax, byte [ecx + edi]
cdq
xor eax, edx
sub eax, edx
add esi, eax
mov eax, dword [ebp - 0x24]
add eax, dword [ebp - 0x28]
add esi, eax
mov edx, dword [ebp - 0x14]
cmp esi, edx
mov ecx, dword [ebp - 0x18]
mov eax, ecx
cmovge eax, dword [ebp - 0x30]
inc ecx
cmp esi, edx
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x18], ecx
cmovge esi, edx
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x14], esi
mov esi, dword [ebp - 0x1c]
cmp ecx, 5
jl 0x10100480
cmp ecx, eax
je 0x101005ce
mov ecx, dword [ebp - 0xc]
push edi
push eax
push dword [ebp - 0x20]
push edx
push ecx
push esi
push dword [ebp + 0xc]
push dword [ebp - 0x2c]
call fcn.100ff7a0
mov ecx, dword [ebp - 0x30]
add esp, 0x20
mov eax, dword [ebp - 0x34]
push ebx
push edi
mov byte [eax], cl
inc eax
push eax
call sub.VCRUNTIME140.dll_memcpy
mov edx, dword [ebp - 0x10]
lea eax, [ebx + 1]
add dword [ebp - 0x34], eax
inc edx
mov eax, dword [ebp - 0xc]
add esp, 0xc
mov dword [ebp - 0x10], edx
cmp edx, eax
jl 0x10100444
mov ebx, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
push edi
call ebx
push dword [0x108624e4]
mov edi, dword [ebp - 0x38]
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 0x4c]
imul eax, dword [ebp - 0xc]
push eax
push edi
call fcn.10100760
mov esi, eax
push edi
mov dword [ebp - 0x14], esi
call ebx
add esp, 0x18
test esi, esi
je 0x10100425
mov esi, dword [ebp - 0x10]
mov eax, 0xffffffff
mov ecx, esi
add ecx, 0x39
cmovo ecx, eax
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edi, eax
add esp, 4
test edi, edi
je 0x10100425
mov ecx, dword [ebp - 0x50]
lea eax, [esi + 0x39]
push 0xd
mov dword [ecx], eax
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 4]
mov dword [edi], eax
mov dword [edi + 4], ecx
mov ecx, dword [ebp - 0x1c]
mov eax, ecx
sar eax, 0x18
mov dword [edi + 8], 0xd000000
mov dword [edi + 0xc], 0x52444849
mov byte [edi + 0x10], al
mov eax, ecx
sar eax, 0x10
mov byte [edi + 0x11], al
mov eax, ecx
sar eax, 8
mov byte [edi + 0x12], al
mov byte [edi + 0x13], cl
mov ecx, dword [ebp - 0xc]
mov eax, ecx
sar eax, 0x18
mov byte [edi + 0x14], al
mov eax, ecx
sar eax, 0x10
mov byte [edi + 0x15], al
mov eax, ecx
sar eax, 8
mov byte [edi + 0x16], al
mov eax, dword [ebp - 0x20]
mov byte [edi + 0x17], cl
mov byte [edi + 0x18], 8
mov al, byte [ebp + eax*4 - 0x64]
mov byte [edi + 0x19], al
lea eax, [edi + 0x1d]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
mov word [edi + 0x1a], 0
push eax
mov byte [edi + 0x1c], 0
call fcn.100ffb30
mov ecx, esi
mov esi, dword [ebp - 0xc]
mov eax, ecx
sar eax, 0x18
push ecx
push dword [ebp - 0x14]
mov byte [esi], al
mov eax, ecx
sar eax, 0x10
mov byte [esi + 1], al
mov eax, ecx
sar eax, 8
mov byte [esi + 2], al
mov byte [esi + 3], cl
mov dword [esi + 4], 0x54414449
add esi, 8
push esi
call sub.VCRUNTIME140.dll_memmove
mov eax, dword [ebp - 0x10]
push dword [ebp - 0x14]
add eax, esi
mov dword [ebp - 0xc], eax
call ebx
push dword [ebp - 0x10]
lea eax, [ebp - 0xc]
push eax
call fcn.100ffb30
mov ecx, dword [ebp - 0xc]
lea eax, [ebp - 0xc]
push 0
push eax
mov dword [ecx], 0
mov dword [ecx + 4], 0x444e4549
add ecx, 8
mov dword [ebp - 0xc], ecx
call fcn.100ffb30
add esp, 0x28
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret