Function at 0x58740
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x284
mov ebx, dword [0x6df9c]
mov ebp, dword [0x6df98]
mov eax, ebp
or eax, ebx
jne 0x5880e
mov dword [esp + 0x54], 0x51ba4fa2
mov dword [esp + 0x58], 0x55be53b4
mov dword [esp + 0x5c], 0x597857b8
mov dword [esp + 0x60], 0x5db65bbc
mov dword [esp + 0x64], 0x615e5fb0
mov dword [esp + 0x68], 0
mov dword [esp + 0x154], 0
mov eax, dword [esp + 0x154]
cmp eax, 0x17
ja 0x587ea
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [esp + 0x154]
movzx eax, byte [esp + eax + 0x54]
push dword [esp + 0x154]
push eax
call fcn.000591c0
add esp, 8
mov ecx, dword [esp + 0x154]
mov byte [esp + ecx + 0x54], al
inc dword [esp + 0x154]
mov eax, dword [esp + 0x154]
cmp eax, 0x18
jb 0x587b0
lea eax, [esp + 0x54]
push eax
call fcn.00058390
add esp, 4
mov ebp, eax
mov dword [0x6df9c], edx
mov dword [0x6df98], eax
or eax, edx
je 0x588e8
mov ebx, edx
lea eax, [esp + 0x244]
push 0x40
push eax
push ebx
push ebp
call fcn.00058190
add esp, 0x10
test eax, eax
js 0x588e8
mov eax, dword [esp + 0x280]
mov ecx, eax
sar ecx, 0x1f
add eax, ebp
adc ecx, ebx
add eax, 0x18
adc ecx, 0
lea edx, [esp + 0x154]
push 0xf0
push edx
push ecx
push eax
call fcn.00058190
add esp, 0x10
xor edi, edi
test eax, eax
js 0x588ea
cmp dword [esp + 0x1c8], 0
je 0x588ea
mov eax, dword [esp + 0x1c4]
mov esi, 0
test eax, eax
je 0x588ec
add eax, ebp
mov ecx, ebx
adc ecx, 0
lea edx, [esp + 0x2c]
push 0x28
push edx
push ecx
push eax
call fcn.00058190
add esp, 0x10
test eax, eax
js 0x588e8
mov ecx, dword [esp + 0x40]
lea esi, [ecx*4]
mov eax, 0xffffffff
cmp ecx, 0x40000000
jae 0x588b1
mov eax, esi
push eax
call fcn.0001cb00
add esp, 4
mov edx, dword [esp + 0x48]
add edx, ebp
mov ecx, ebx
adc ecx, 0
push esi
mov dword [esp + 0x10], eax
push eax
push ecx
push edx
call fcn.00058190
add esp, 0x10
test eax, eax
js 0x588fb
mov eax, dword [esp + 0x40]
test eax, eax
jns 0x58904
mov eax, 0xffffffff
jmp 0x58906
xor edi, edi
xor esi, esi
mov eax, edi
mov edx, esi
add esp, 0x284
pop esi
pop edi
pop ebx
pop ebp
ret
xor edi, edi
xor esi, esi
jmp 0x58b3c
add eax, eax
push eax
call fcn.0001cb00
add esp, 4
mov esi, dword [esp + 0x44]
add esi, esi
mov ecx, dword [esp + 0x50]
add ecx, ebp
mov edx, ebx
adc edx, 0
push esi
mov dword [esp + 0xc], eax
push eax
push edx
push ecx
call fcn.00058190
add esp, 0x10
test eax, eax
js 0x58b2c
mov ecx, dword [esp + 0x44]
lea esi, [ecx*4]
mov eax, 0xffffffff
cmp ecx, 0x40000000
jae 0x58952
mov eax, esi
push eax
call fcn.0001cb00
add esp, 4
mov edi, eax
mov eax, dword [esp + 0x4c]
add eax, ebp
mov ecx, ebx
adc ecx, 0
push esi
push edi
push ecx
push eax
call fcn.00058190
add esp, 0x10
test eax, eax
mov dword [esp + 4], edi
js 0x58b1a
mov esi, dword [esp + 0x40]
mov eax, dword [esp + 0x44]
cmp esi, eax
jb 0x5898e
mov esi, eax
test esi, esi
je 0x58b1a
xor eax, eax
mov dword [esp + 0x28], ebx
mov dword [esp + 0x24], ebp
mov dword [esp + 0x20], esi
jmp 0x589d1
mov edx, 0xb14a5e2
cmp edx, dword [esp + 0x298]
mov ebx, dword [esp + 0x28]
mov ebp, dword [esp + 0x24]
mov esi, dword [esp + 0x20]
je 0x58b4d
mov eax, dword [esp + 0x10]
inc eax
cmp eax, esi
je 0x58b1a
mov dword [esp + 0x10], eax
mov eax, dword [edi + eax*4]
add eax, ebp
mov ecx, ebx
adc ecx, 0
push 0x100
lea edx, [esp + 0x58]
push edx
push ecx
push eax
call fcn.00058190
add esp, 0x10
test eax, eax
jns 0x589fe
cmp eax, 0x8000000d
jne 0x589c4
mov ebx, 0xffffffff
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, eax
cmp byte [esp + ebx + 0x55], 0
lea ebx, [ebx + 1]
lea eax, [eax + 1]
jne 0x58a10
mov dword [esp + 0x18], 0x323230a3
lea eax, [esp + 0x1c]
mov byte [eax + 2], 0
mov word [eax], 0
mov dword [esp], 0
mov eax, dword [esp]
cmp eax, 6
ja 0x58a76
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [esp]
movzx eax, byte [esp + eax + 0x18]
push dword [esp]
push eax
call fcn.00059240
add esp, 8
mov ecx, dword [esp]
mov byte [esp + ecx + 0x18], al
inc dword [esp]
mov eax, dword [esp]
cmp eax, 7
jb 0x58a50
test ebx, ebx
je 0x589a6
mov eax, dword [esp + 0x18]
mov ecx, eax
not ecx
mov edx, 0xb14a5e2
lea ebp, [esp + 0x54]
cmp ebx, 1
je 0x58aee
and esi, 0xfffffffe
mov dword [esp + 0x14], ecx
nop
nop
nop
nop
nop
movsx edi, byte [ebp]
xor edi, edx
mov edx, edi
and edx, ecx
mov ecx, edi
not ecx
and ecx, eax
imul ecx, edx
mov edx, edi
and edx, eax
or edi, eax
imul edi, edx
add edi, ecx
movsx edx, byte [ebp + 1]
add ebp, 2
xor edx, edi
mov ecx, edx
and ecx, dword [esp + 0x14]
mov edi, edx
not edi
and edi, eax
imul edi, ecx
mov ecx, edx
and ecx, eax
or edx, eax
imul edx, ecx
mov ecx, dword [esp + 0x14]
add edx, edi
add esi, 0xfffffffe
jne 0x58aa0
mov edi, dword [esp + 4]
test bl, 1
je 0x589ab
mov esi, ecx
movsx ecx, byte [ebp]
xor edx, ecx
and esi, edx
mov ecx, edx
not ecx
and ecx, eax
imul ecx, esi
mov esi, edx
and esi, eax
or edx, eax
imul edx, esi
add edx, ecx
jmp 0x589ab
xor edi, edi
xor esi, esi
push dword [esp + 4]
call fcn.0001cb10
add esp, 4
jmp 0x58b30
xor edi, edi
xor esi, esi
push dword [esp + 8]
call fcn.0001cb10
add esp, 4
push dword [esp + 0xc]
call fcn.0001cb10
add esp, 4
jmp 0x588ec
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0x10]
movzx eax, word [eax + ecx*2]
mov ecx, dword [esp + 0xc]
add ebp, dword [ecx + eax*4]
adc ebx, 0
mov edi, ebp
mov esi, ebx
jmp 0x58b1e