Function at 0x497590
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x88
lea eax, [ebp - 0x24]
mov ebx, dword [ebp + 0x14]
mov edi, dword [ebp + 0x18]
push eax
call fcn.0045b440
add esp, 0x10
test ebx, ebx
je 0x4976d8
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push eax
call fcn.0043aba0
add esp, 0x10
mov dword [ebp - 0x7c], eax
test eax, eax
js 0x497680
cmp dword [ebp + 0x1c], 0xffffffff
je 0x497700
cmp dword [ebp + 0x1c], 0xfffffffe
je 0x4975e6
jl 0x4976b8
mov ecx, dword [ebp + 8]
sub esp, 0xc
mov eax, dword [ecx + 0x10]
push eax
call fcn.0041c550
mov ecx, dword [ebp + 8]
lea esi, [eax - 1]
pop eax
push ecx
call fcn.0041c3a0
and esi, 7
mov dword [ebp - 0x84], eax
xor edx, edx
mov eax, 0xff
mov ecx, esi
mov dl, byte [edi]
shl eax, cl
add esp, 0x10
test eax, edx
jne 0x497698
test esi, esi
jne 0x497631
mov edx, dword [ebp - 0x84]
inc edi
dec edx
mov dword [ebp - 0x84], edx
mov edx, dword [ebp - 0x7c]
mov ecx, dword [ebp + 0x1c]
lea eax, [edx + ecx + 2]
cmp dword [ebp - 0x84], eax
jl 0x4976e0
mov eax, dword [ebp - 0x84]
cmp byte [eax + edi - 1], 0xbc
je 0x49770b
sub esp, 0xc
push 0x83
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x86
push 0x95
push 4
call fcn.00424900
add esp, 0x20
lea esi, [esi]
xor ebx, ebx
sub esp, 0xc
lea ecx, [ebp - 0x24]
push ecx
call fcn.0045b320
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
sub esp, 0xc
push 0x74
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x85
push 0x95
push 4
call fcn.00424900
add esp, 0x20
jmp 0x497680
sub esp, 0xc
push 0x6c
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x88
push 0x95
push 4
call fcn.00424900
add esp, 0x20
jmp 0x497680
mov ebx, dword [ebp + 0x10]
jmp 0x4975b6
sub esp, 0xc
push 0x7e
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x6d
push 0x95
push 4
call fcn.00424900
add esp, 0x20
jmp 0x497680
mov edx, dword [ebp - 0x7c]
mov dword [ebp + 0x1c], edx
jmp 0x4975e6
mov eax, dword [ebp - 0x7c]
mov edx, dword [ebp - 0x84]
sub edx, eax
push eax
mov dword [ebp - 0x80], edx
dec edx
push 0x88
mov dword [ebp - 0x78], edx
push str.external_openssl_crypto_rsa_rsa_pss.c
push edx
call fcn.00425130
add esp, 0x10
mov dword [ebp - 0x70], eax
test eax, eax
je 0x497850
sub esp, 0xc
mov eax, dword [ebp - 0x7c]
mov ecx, dword [ebp - 0x78]
push ebx
add ecx, edi
push eax
mov eax, dword [ebp - 0x78]
push ecx
push eax
mov eax, dword [ebp - 0x70]
mov dword [ebp - 0x74], ecx
push eax
call fcn.0044fb20
add esp, 0x20
test eax, eax
js 0x49788c
mov eax, dword [ebp - 0x78]
test eax, eax
jle 0x497782
mov edx, 1
mov ebx, dword [ebp - 0x70]
mov al, byte [edx + edi - 1]
xor byte [edx + ebx - 1], al
inc edx
cmp edx, dword [ebp - 0x80]
jne 0x497771
test esi, esi
jne 0x497820
mov eax, dword [ebp - 0x70]
mov cl, byte [eax]
test cl, cl
jne 0x497950
mov eax, dword [ebp - 0x78]
dec eax
test eax, eax
jle 0x49783c
mov eax, dword [ebp - 0x80]
xor edx, edx
sub eax, 2
jmp 0x4977b8
cmp edx, eax
je 0x49783c
inc edx
mov ebx, dword [ebp - 0x70]
mov cl, byte [edx + ebx]
test cl, cl
je 0x4977b0
lea ebx, [edx + 1]
dec cl
jne 0x49783c
mov edi, dword [ebp + 0x1c]
test edi, edi
js 0x497875
mov eax, dword [ebp - 0x78]
sub eax, ebx
cmp eax, dword [ebp + 0x1c]
je 0x497875
sub esp, 0xc
push 0x9c
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x88
push 0x95
push 4
xor ebx, ebx
call fcn.00424900
add esp, 0x20
sub esp, 0xc
mov esi, dword [ebp - 0x70]
push esi
call fcn.00425260
add esp, 0x10
jmp 0x497682
mov edx, dword [ebp - 0x70]
mov ecx, 8
sub ecx, esi
mov eax, 0xff
sar eax, cl
mov cl, byte [edx]
and ecx, eax
mov byte [edx], cl
jmp 0x49778f
sub esp, 0xc
push 0x97
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x87
jmp 0x4977f5
sub esp, 0xc
xor ebx, ebx
push 0x8b
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x41
push 0x95
push 4
call fcn.00424900
add esp, 0x20
jmp 0x497682
mov ecx, dword [ebp + 0x10]
lea eax, [ebp - 0x24]
push esi
push 0
push ecx
push eax
call fcn.0045b740
add esp, 0x10
test eax, eax
jne 0x497893
xor ebx, ebx
jmp 0x497806
push edx
lea edx, [ebp - 0x24]
push 8
push 0x4d55ce
push edx
call fcn.0045b310
add esp, 0x10
test eax, eax
je 0x49788c
push eax
mov eax, dword [ebp - 0x7c]
push eax
lea ecx, [ebp - 0x24]
mov eax, dword [ebp + 0xc]
push eax
push ecx
call fcn.0045b310
add esp, 0x10
test eax, eax
je 0x49788c
cmp dword [ebp - 0x78], ebx
je 0x4978ec
push eax
mov eax, dword [ebp - 0x78]
sub eax, ebx
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x78]
push eax
mov eax, dword [ebp - 0x70]
add eax, ebx
lea ebx, [ebp - 0x24]
push eax
push ebx
call fcn.0045b310
add esp, 0x10
test eax, eax
je 0x49788c
lea eax, [ebp - 0x24]
lea ebx, [ebp - 0x64]
push edi
push 0
push ebx
push eax
call fcn.0045b680
add esp, 0x10
test eax, eax
je 0x49788c
mov edx, dword [ebp - 0x7c]
mov esi, ebx
cld
cmp edx, edx
mov ecx, edx
mov edi, dword [ebp - 0x74]
mov ebx, 1
repe cmpsb byte [esi], byte es:[edi]
seta dl
setb al
cmp dl, al
je 0x497806
sub esp, 0xc
xor bl, bl
push 0xac
push str.external_openssl_crypto_rsa_rsa_pss.c
push 0x68
push 0x95
push 4
call fcn.00424900
add esp, 0x20
jmp 0x497806
mov ebx, 1
jmp 0x4977c6