Function at 0x584020
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0x2c
call fcn.00490990
push ebx
push edi
xor edi, edi
mov dword [esp + 0xc], edi
mov dword [esp + 8], edi
cmp dword [esp + 0x48], edi
jne 0x584044
mov eax, dword [esp + 0x44]
mov dword [esp + 0x48], eax
mov ecx, dword [esp + 0x44]
push ecx
call fcn.0052ce80
mov ebx, eax
add esp, 4
cmp ebx, edi
mov dword [esp + 0x10], ebx
jl 0x5842a0
push esi
mov esi, dword [esp + 0x50]
cmp esi, 0xffffffff
jne 0x5840b5
mov esi, ebx
mov edi, dword [esp + 0x3c]
mov edx, dword [edi + 0x10]
push ebp
push edx
call fcn.00501f20
mov ebp, eax
dec ebp
and ebp, 7
push edi
mov dword [esp + 0x28], ebp
call fcn.00505590
add esp, 8
mov edi, eax
test ebp, ebp
mov ebp, dword [esp + 0x44]
mov dword [esp + 0x1c], edi
jne 0x5840a4
mov byte [ebp], 0
inc ebp
dec edi
mov dword [esp + 0x1c], edi
lea eax, [ebx + 2]
cmp edi, eax
jge 0x5840e5
push 0xe7
jmp 0x58413c
cmp esi, 0xfffffffe
jne 0x5840bc
jmp 0x58406b
jge 0x58406b
push 0xdb
push str..crypto_rsa_rsa_pss.c
push 0x88
push 0x94
push 4
call fcn.004f6240
add esp, 0x14
pop esi
mov eax, edi
pop edi
pop ebx
add esp, 0x2c
ret
sub edi, ebx
cmp esi, 0xfffffffe
jne 0x584130
lea esi, [edi - 2]
test esi, esi
jle 0x584170
push 0xf2
push str..crypto_rsa_rsa_pss.c
push esi
call fcn.004fbe80
mov ebx, eax
add esp, 0xc
mov dword [esp + 0x10], ebx
test ebx, ebx
jne 0x58415e
push 0xf5
push str..crypto_rsa_rsa_pss.c
push 0x41
push 0x94
push 4
call fcn.004f6240
add esp, 0x14
jmp 0x584283
lea ecx, [edi - 2]
cmp esi, ecx
jle 0x5840ef
push 0xee
push str..crypto_rsa_rsa_pss.c
push 0x6e
push 0x94
push 4
call fcn.004f6240
add esp, 0x14
mov eax, dword [esp + 0x14]
pop ebp
pop esi
pop edi
pop ebx
add esp, 0x2c
ret
push esi
push ebx
call fcn.004f6820
add esp, 8
test eax, eax
jle 0x58427f
lea edx, [esp + 0x24]
push edx
lea ebx, [edi - 1]
call fcn.00504c00
mov eax, dword [esp + 0x50]
push 0
push eax
lea ecx, [esp + 0x30]
push ecx
call fcn.00504c50
add esp, 0x10
test eax, eax
je 0x58427f
push 8
lea edx, [esp + 0x28]
push 0x7c988c
push edx
call fcn.00504e00
add esp, 0xc
test eax, eax
je 0x58427f
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x48]
push eax
push ecx
lea edx, [esp + 0x2c]
push edx
call fcn.00504e00
add esp, 0xc
test eax, eax
je 0x58427f
test esi, esi
je 0x5841f3
mov eax, dword [esp + 0x10]
push esi
push eax
lea ecx, [esp + 0x2c]
push ecx
call fcn.00504e00
add esp, 0xc
test eax, eax
je 0x58427f
push 0
lea eax, [ebx + ebp]
push eax
lea edx, [esp + 0x2c]
push edx
call fcn.00504e10
add esp, 0xc
test eax, eax
je 0x58427f
lea eax, [esp + 0x24]
push eax
call fcn.00504e90
mov ecx, dword [esp + 0x54]
mov edx, dword [esp + 0x1c]
push ecx
push edx
lea eax, [ebx + ebp]
push eax
push ebx
push ebp
call fcn.00555490
add esp, 0x18
test eax, eax
jne 0x58427f
sub edi, esi
xor byte [edi + ebp - 2], 1
lea eax, [edi + ebp - 2]
inc eax
test esi, esi
jle 0x584255
xor ecx, ecx
test esi, esi
jle 0x584255
mov edx, dword [esp + 0x10]
mov dl, byte [ecx + edx]
xor byte [eax], dl
inc ecx
inc eax
cmp ecx, esi
jl 0x584246
mov eax, dword [esp + 0x20]
test eax, eax
je 0x58426e
mov ecx, 8
sub ecx, eax
mov eax, 0xff
sar eax, cl
and byte [ebp], al
mov ecx, dword [esp + 0x1c]
mov byte [ecx + ebp - 1], 0xbc
mov dword [esp + 0x14], 1
mov ebx, dword [esp + 0x10]
test ebx, ebx
je 0x584152
push ebx
call fcn.004fc080
mov eax, dword [esp + 0x18]
add esp, 4
pop ebp
pop esi
pop edi
pop ebx
add esp, 0x2c
ret
mov eax, edi
pop edi
pop ebx
add esp, 0x2c
ret