Function at 0x52f930
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push esi
push edi
mov edi, dword [ebp + 0x14]
push edi
mov dword [ebp - 0x34], 0
call fcn.004c8a40
push edi
call fcn.004c87f0
push edi
mov dword [ebp - 0x20], eax
call fcn.004c87f0
push edi
mov dword [ebp - 0x1c], eax
call fcn.004c87f0
mov esi, eax
push edi
mov dword [ebp - 0x2c], esi
call fcn.004c87f0
mov edi, eax
add esp, 0x14
mov dword [ebp - 0x30], edi
test edi, edi
je 0x52fdac
push ebx
mov ebx, dword [ebp + 0x10]
lea eax, [ebp - 0x58]
push 6
push eax
push ebx
call fcn.00530650
add esp, 0xc
test eax, eax
je 0x52fd90
cmp eax, 6
jg 0x52fd90
lea eax, [ebp - 0x58]
push eax
push dword [ebp + 0xc]
push esi
call fcn.0052f4f0
add esp, 0xc
test eax, eax
je 0x52fdab
push esi
call fcn.0049f8d0
add esp, 4
test eax, eax
jne 0x52fdab
push ebx
push edi
call fcn.0049f640
add esp, 8
test eax, eax
je 0x52fdab
push esi
call fcn.0049f9b0
push edi
mov dword [ebp - 0x14], eax
call fcn.0049f9b0
mov edi, dword [ebx + 4]
push edi
push esi
mov dword [ebp - 0x24], eax
mov dword [ebp - 4], edi
call fcn.004a0130
add esp, 0x10
test eax, eax
je 0x52fdab
mov edx, dword [ebp - 0x2c]
mov esi, dword [esi]
mov dword [ebp - 0x18], esi
mov eax, dword [edx + 4]
cmp eax, edi
jge 0x52fa22
mov ecx, dword [ebp - 4]
lea edi, [esi + eax*4]
sub ecx, eax
xor eax, eax
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 4]
push edi
push dword [ebp - 0x20]
mov dword [edx + 4], edi
call fcn.004a0130
add esp, 8
test eax, eax
je 0x52fdab
mov edx, dword [ebp - 0x20]
mov ebx, dword [edx]
mov dword [ebp - 0xc], ebx
mov dword [ebx], 1
cmp edi, 1
jle 0x52fa59
lea ecx, [edi - 1]
xor eax, eax
lea edi, [ebx + 4]
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 4]
push edi
push dword [ebp - 0x1c]
mov dword [edx + 4], edi
call fcn.004a0130
add esp, 8
test eax, eax
je 0x52fdab
mov eax, dword [ebp - 0x1c]
mov edx, dword [eax]
mov dword [ebp - 0x10], edx
test edi, edi
jle 0x52fa8a
mov ecx, edi
xor eax, eax
mov edi, edx
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 4]
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
mov dword [eax + 4], edi
mov eax, dword [ebp - 0x30]
mov eax, dword [eax]
mov dword [ebp - 8], eax
test ecx, ecx
je 0x52fb64
mov ebx, dword [esi]
test bl, 1
jne 0x52fb5e
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp + 0x10]
mov eax, dword [eax]
mov edx, eax
mov ecx, dword [ecx]
and edx, 1
neg edx
mov dword [ebp - 0x3c], edx
mov ecx, dword [ecx]
and ecx, edx
lea edx, [edi - 1]
xor eax, ecx
xor ecx, ecx
mov dword [ebp - 0x28], ecx
test edx, edx
jle 0x52fb40
mov ecx, dword [ebp - 0xc]
mov edx, esi
sub edx, ecx
mov dword [ebp - 0x40], edx
lea edi, [ecx + 4]
mov ecx, 0xfffffffc
sub ecx, dword [ebp - 0xc]
mov dword [ebp - 0x38], ecx
nop dword [eax]
mov edx, dword [edx + edi]
mov ecx, edx
shl ecx, 0x1f
shr ebx, 1
or ecx, ebx
shr eax, 1
mov ebx, dword [ebp - 0x28]
mov dword [esi + ebx*4], ecx
mov ebx, edx
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp - 0x38]
mov esi, dword [ebp - 0x18]
add edx, edi
mov ecx, dword [ecx]
mov edx, dword [edx + ecx + 4]
and edx, dword [ebp - 0x3c]
xor edx, dword [edi]
mov ecx, edx
shl ecx, 0x1f
or ecx, eax
mov eax, edx
mov edx, dword [ebp - 4]
mov dword [edi - 4], ecx
dec edx
mov ecx, dword [ebp - 0x28]
add edi, 4
inc ecx
cmp ecx, edx
mov dword [ebp - 0x28], ecx
mov edx, dword [ebp - 0x40]
jl 0x52faf0
mov edi, dword [ebp - 4]
shr ebx, 1
mov dword [esi + ecx*4], ebx
mov ebx, dword [ebp - 0xc]
shr eax, 1
mov dword [ebx + ecx*4], eax
mov ecx, dword [ebp - 0x14]
sub ecx, 1
mov dword [ebp - 0x14], ecx
jne 0x52faa0
jmp 0x52fb61
mov ebx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
cmp ecx, 0x20
jg 0x52fb7c
mov eax, dword [esi]
test eax, eax
je 0x52fdab
cmp eax, 1
je 0x52fd6a
cmp ecx, dword [ebp - 0x24]
jge 0x52fbbb
mov ebx, dword [ebp - 0x30]
mov eax, ecx
mov ecx, dword [ebp - 0x24]
mov esi, dword [ebp - 0x1c]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x2c], ebx
mov ebx, eax
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x20], esi
mov esi, dword [ebp - 8]
mov ebx, dword [ebx]
mov dword [ebp - 8], ebx
mov ebx, edx
mov edx, dword [eax]
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], esi
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], edx
xor edx, edx
test edi, edi
jle 0x52fd18
cmp edi, 4
jb 0x52fcd0
mov esi, dword [ebp - 0x10]
lea eax, [edi - 1]
sub esi, 4
lea eax, [ebx + eax*4]
lea edi, [esi + edi*4]
mov esi, dword [ebp - 0x18]
cmp ebx, edi
ja 0x52fbed
cmp eax, dword [ebp - 0x10]
jae 0x52fccd
mov edi, dword [ebp - 4]
dec edi
lea edi, [esi + edi*4]
cmp ebx, edi
ja 0x52fc00
cmp eax, esi
jae 0x52fccd
mov ebx, dword [ebp - 8]
mov esi, dword [ebp - 4]
sub ebx, 4
lea esi, [ebx + esi*4]
mov ebx, dword [ebp - 0xc]
cmp ebx, esi
mov esi, dword [ebp - 0x18]
ja 0x52fc1f
cmp eax, dword [ebp - 8]
jae 0x52fccd
mov ebx, dword [ebp - 4]
mov ecx, dword [ebp - 0x10]
dec ebx
lea eax, [ecx + ebx*4]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
cmp esi, eax
ja 0x52fc3c
cmp edi, dword [ebp - 0x10]
jae 0x52fccd
mov ebx, dword [ebp - 4]
mov ecx, dword [ebp - 8]
dec ebx
lea eax, [ecx + ebx*4]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
cmp esi, eax
ja 0x52fc5b
mov eax, dword [ebp - 8]
cmp edi, eax
jae 0x52fd62
mov ecx, dword [ebp - 4]
mov eax, ecx
and eax, reloc.WS2_32.dll_closesocket
jns 0x52fc6c
dec eax
or eax, 0xfffffffc
inc eax
mov ebx, dword [ebp - 8]
mov edi, ecx
sub ebx, esi
sub edi, eax
mov dword [ebp - 0x40], ebx
mov eax, esi
mov ebx, dword [ebp - 0x10]
sub ebx, esi
mov esi, dword [ebp - 0x18]
mov dword [ebp - 0x3c], ebx
mov ebx, dword [ebp - 0xc]
mov dword [ebp - 0x28], ebx
sub dword [ebp - 0x28], esi
mov ebx, dword [ebp - 0x40]
mov esi, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x28]
movups xmm0, xmmword [eax]
add edx, 4
lea eax, [eax + 0x10]
movups xmm1, xmmword [ebx + eax - 0x10]
pxor xmm1, xmm0
movups xmm0, xmmword [ecx + eax - 0x10]
movups xmmword [eax - 0x10], xmm1
movups xmm1, xmmword [esi + eax - 0x10]
pxor xmm1, xmm0
movups xmmword [ecx + eax - 0x10], xmm1
cmp edx, edi
jl 0x52fc97
mov esi, dword [ebp - 0x18]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
mov edi, dword [ebp - 4]
mov eax, dword [ebp - 8]
cmp edx, edi
jge 0x52fd18
sub eax, esi
lea ecx, [esi + edx*4]
mov dword [ebp - 0x40], eax
sub ebx, esi
mov eax, dword [ebp - 0x10]
sub eax, esi
mov dword [ebp - 0x38], ebx
mov ebx, dword [ebp - 0x40]
sub edi, edx
mov esi, dword [ebp - 0x38]
mov edx, eax
mov dword [ebp - 0x3c], eax
mov eax, dword [ecx + ebx]
lea ecx, [ecx + 4]
xor dword [ecx - 4], eax
mov eax, dword [ecx + edx - 4]
xor dword [ecx + esi - 4], eax
sub edi, 1
jne 0x52fcf6
mov esi, dword [ebp - 0x18]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
mov edi, dword [ebp - 4]
mov edx, dword [ebp - 0x10]
cmp ecx, dword [ebp - 0x24]
jne 0x52fa98
lea eax, [ecx - 1]
cdq
and edx, 0x1f
lea edi, [edx + eax]
sar edi, 5
mov eax, dword [esi + edi*4]
test eax, eax
jne 0x52fd45
test edi, edi
je 0x52fd45
mov eax, dword [esi + edi*4 - 4]
dec edi
test eax, eax
je 0x52fd38
push eax
call fcn.0049fa60
mov edx, dword [ebp - 0x10]
add esp, 4
shl edi, 5
lea ecx, [edi + eax]
mov edi, dword [ebp - 4]
mov dword [ebp - 0x14], ecx
jmp 0x52fa98
mov edi, dword [ebp - 4]
jmp 0x52fcd3
mov ebx, dword [ebp - 0x20]
push ebx
call fcn.0049ffb0
push ebx
push dword [ebp + 8]
call fcn.0049f640
xor ecx, ecx
add esp, 0xc
test eax, eax
mov edx, 1
cmovne ecx, edx
mov dword [ebp - 0x34], ecx
jmp 0x52fdab
push 0x18e
push str.c:_cygwin_home_shachar_zon_new_pkg_lib_openssl_crypto_bn_bn_gf2m.c
push 0x6a
push 0x83
push 3
call fcn.00455e30
add esp, 0x14
pop ebx
push dword [ebp + 0x14]
call fcn.004c86f0
mov eax, dword [ebp - 0x34]
add esp, 4
pop edi
pop esi
mov esp, ebp
pop ebp
ret