Function at 0x590410
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5b5610
mov eax, dword fs:[0]
push eax
sub esp, 0x148
mov eax, dword [0x68cc00]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x14]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
push 0x138
mov dword [ebp - 0x154], eax
lea eax, [ebp - 0x148]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea ecx, [ebp - 0x148]
call fcn.004498e0
lea eax, [edi + 0x34]
mov dword [ebp - 4], 0
lea ebx, [edi + 0x30]
mov dword [ebp - 0x150], eax
mov ecx, eax
mov dword [ebp - 0x14c], ebx
call fcn.00402f10
mov edi, dword [ebp - 0x150]
test eax, eax
jne 0x5904aa
push 0x10
push eax
mov ecx, edi
call fcn.004354c0
mov dword [ebx], 0xc
jmp 0x5904b0
mov dword [ebp - 0x14c], ebx
cmp dword [esi + 0x534], 0
je 0x5904c3
push str.Not_in_IV_mode.
jmp 0x5906bc
mov ecx, dword [esi + 0x538]
cmp ecx, 0xf
ja 0x5906b7
mov eax, dword [ebx]
add eax, ecx
cmp eax, 0xc
jbe 0x5904e2
or dword [esi + 0x530], 1
mov ecx, edi
call fcn.00438b90
xor edi, edi
mov ebx, eax
cmp dword [esi + 0x538], edi
jne 0x59056c
mov eax, dword [ebp - 0x14c]
test dword [eax], 0xfffffff0
jbe 0x59056a
lea ecx, [esi + 0x4f0]
nop dword [eax]
mov eax, dword [edi + ebx]
xor dword [ecx], eax
mov eax, dword [edi + ebx + 4]
xor dword [ecx + 4], eax
mov eax, dword [edi + ebx + 8]
xor dword [esi + 0x4f8], eax
mov eax, dword [edi + ebx + 0xc]
xor dword [esi + 0x4fc], eax
lea eax, [ebp - 0x148]
push eax
push ecx
push esi
call fcn.00592c30
mov eax, dword [ebp - 0x14c]
lea ecx, [esi + 0x4f0]
add esp, 0xc
add dword [esi + 0x540], 0x80
adc dword [esi + 0x544], 0
add edi, 0x10
mov eax, dword [eax]
and eax, 0xfffffff0
cmp edi, eax
jb 0x590510
add ebx, edi
mov eax, dword [ebp - 0x14c]
cmp edi, dword [eax]
jae 0x5906b3
nop word [eax + eax]
mov ecx, dword [esi + 0x538]
lea ebx, [ebx + 1]
mov al, byte [ebx - 1]
mov byte [ecx + esi + 0x520], al
inc dword [esi + 0x538]
cmp dword [esi + 0x538], 0x10
jne 0x5906a4
movzx eax, byte [esi + 0x520]
lea ecx, [esi + 0x4f0]
xor byte [ecx], al
movzx eax, byte [esi + 0x521]
xor byte [esi + 0x4f1], al
movzx eax, byte [esi + 0x522]
xor byte [esi + 0x4f2], al
movzx eax, byte [esi + 0x523]
xor byte [esi + 0x4f3], al
movzx eax, byte [esi + 0x524]
xor byte [esi + 0x4f4], al
movzx eax, byte [esi + 0x525]
xor byte [esi + 0x4f5], al
movzx eax, byte [esi + 0x526]
xor byte [esi + 0x4f6], al
movzx eax, byte [esi + 0x527]
xor byte [esi + 0x4f7], al
movzx eax, byte [esi + 0x528]
xor byte [esi + 0x4f8], al
movzx eax, byte [esi + 0x529]
xor byte [esi + 0x4f9], al
movzx eax, byte [esi + 0x52a]
xor byte [esi + 0x4fa], al
movzx eax, byte [esi + 0x52b]
xor byte [esi + 0x4fb], al
movzx eax, byte [esi + 0x52c]
xor byte [esi + 0x4fc], al
movzx eax, byte [esi + 0x52d]
xor byte [esi + 0x4fd], al
movzx eax, byte [esi + 0x52e]
xor byte [esi + 0x4fe], al
movzx eax, byte [esi + 0x52f]
xor byte [esi + 0x4ff], al
lea eax, [ebp - 0x148]
push eax
push ecx
push esi
call fcn.00592c30
add esp, 0xc
mov dword [esi + 0x538], 0
add dword [esi + 0x540], 0x80
adc dword [esi + 0x544], 0
mov eax, dword [ebp - 0x14c]
inc edi
cmp edi, dword [eax]
jb 0x590580
mov bl, 1
jmp 0x5906c9
push str.buflen_error.
mov ecx, dword [ebp - 0x154]
mov eax, dword [ecx]
call dword [eax + 0x14]
xor bl, bl
lea ecx, [ebp - 0x148]
call fcn.00449900
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005af5a8
mov esp, ebp
pop ebp
ret 0x10