Function at 0x47e970
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x15c
mov eax, dword [0x5b66c0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x15c], eax
push esi
push edi
mov eax, dword [ebx + 0x54]
mov ecx, eax
mov dword [ebp - 0x158], ebx
and ecx, reloc.WS2_32.dll_closesocket
jns 0x47e9aa
dec ecx
or ecx, 0xfffffffc
inc ecx
add eax, 3
mov dword [ebp - 0x148], ecx
cdq
xor esi, esi
and edx, 3
add eax, edx
sar eax, 2
test eax, eax
mov eax, dword [sym.imp.WS2_32.dll_ntohl]
jle 0x47e9fd
lea edi, [ebx + 0x14]
nop word [eax + eax]
push dword [edi]
call eax
mov dword [ebp + esi*4 - 0x144], eax
lea edi, [edi + 4]
mov eax, dword [ebx + 0x54]
inc esi
add eax, 3
cdq
and edx, 3
add eax, edx
sar eax, 2
cmp esi, eax
mov eax, dword [sym.imp.WS2_32.dll_ntohl]
jl 0x47e9d0
mov ecx, dword [ebp - 0x148]
cmp ecx, 3
ja case.default.0x47ea02
jmp dword [ecx*4 + 0x47ef7c]
push dword [ebx + esi*4 + 0x10]
call eax
and eax, 0xffffff80
mov dword [ebp + esi*4 - 0x144], 0
or eax, 0x80
mov dword [ebp + esi*4 - 0x148], eax
jmp case.default.0x47ea02
push dword [ebx + esi*4 + 0x10]
call eax
and eax, 0xffff8000
mov dword [ebp + esi*4 - 0x144], 0
or eax, 0x8000
mov dword [ebp + esi*4 - 0x148], eax
jmp case.default.0x47ea02
push dword [ebx + esi*4 + 0x10]
call eax
and eax, 0xff800000
mov dword [ebp + esi*4 - 0x144], 0
or eax, 0x800000
mov dword [ebp + esi*4 - 0x148], eax
jmp case.default.0x47ea02
mov dword [ebp + esi*4 - 0x144], htonl
lea edx, [esi + 1]
cmp edx, 0xf
jge 0x47ea9f
shl edx, 2
lea edi, [ebp - 0x144]
mov ecx, 0x3c
xor eax, eax
sub ecx, edx
shr ecx, 2
add edi, edx
rep stosd dword es:[edi], eax
mov ecx, dword [ebx + 0x54]
cmp ecx, 0x38
jge 0x47eaac
mov eax, dword [ebx + 0x58]
jmp 0x47eaba
mov eax, dword [ebp - 0x108]
xor edx, edx
cmp ecx, 0x3c
cmovl eax, edx
mov dword [ebp - 0x108], eax
lea ecx, [ebp - 0x13c]
mov edx, 0x40
nop dword [eax + eax]
mov eax, dword [ecx + 0x2c]
lea ecx, [ecx + 4]
xor eax, dword [ecx + 0x14]
xor eax, dword [ecx - 0xc]
xor eax, dword [ecx - 4]
ror eax, 0x1f
mov dword [ecx + 0x34], eax
sub edx, 1
jne 0x47ead0
mov eax, dword [ebx + 0xc]
mov ecx, dword [ebx]
mov edi, dword [ebx + 4]
mov esi, dword [ebx + 8]
mov dword [ebp - 0x14c], eax
mov eax, dword [ebx + 0x10]
mov ebx, dword [ebp - 0x14c]
mov dword [ebp - 0x154], ecx
mov dword [ebp - 0x150], eax
mov dword [ebp - 0x148], edx
mov edx, ecx
mov eax, esi
mov ecx, edi
ror edx, 0x1b
and eax, edi
not ecx
and ecx, ebx
or ecx, eax
mov eax, dword [ebp - 0x148]
add edx, ecx
add edx, dword [ebp + eax*4 - 0x144]
inc eax
add edx, dword [0x5b3dcc]
add edx, dword [ebp - 0x150]
mov dword [ebp - 0x150], ebx
mov ecx, edx
mov ebx, esi
mov dword [ebp - 0x148], eax
mov esi, edi
shr edi, 2
shl esi, 0x1e
or esi, edi
mov edi, dword [ebp - 0x154]
mov dword [ebp - 0x154], ecx
cmp eax, 0x14
jl 0x47eb16
mov dword [ebp - 0x14c], ebx
mov eax, ebx
mov dword [ebp - 0x154], 0x14
xor eax, esi
ror edx, 0x1b
xor eax, edi
add edx, eax
mov eax, dword [ebp - 0x154]
inc dword [ebp - 0x154]
add edx, dword [ebp + eax*4 - 0x144]
add edx, dword [0x5b3dd0]
add edx, dword [ebp - 0x150]
mov eax, dword [ebp - 0x14c]
mov dword [ebp - 0x150], eax
mov eax, esi
mov esi, edi
mov dword [ebp - 0x14c], eax
shr edi, 2
shl esi, 0x1e
or esi, edi
cmp dword [ebp - 0x154], 0x28
mov edi, ecx
mov ecx, edx
jl 0x47eb80
mov dword [ebp - 0x154], ecx
mov ebx, edx
mov dword [ebp - 0x148], 0x28
mov ecx, esi
ror edx, 0x1b
or ecx, edi
and ecx, eax
mov eax, esi
and eax, edi
or ecx, eax
mov eax, dword [ebp - 0x14c]
add edx, ecx
mov ecx, dword [ebp - 0x148]
add edx, dword [ebp + ecx*4 - 0x144]
inc ecx
add edx, dword [0x5b3dd4]
add edx, dword [ebp - 0x150]
mov dword [ebp - 0x150], eax
mov eax, esi
mov esi, edi
mov dword [ebp - 0x14c], eax
shr edi, 2
shl esi, 0x1e
or esi, edi
mov dword [ebp - 0x148], ecx
mov edi, ebx
mov ebx, edx
cmp ecx, 0x3c
jl 0x47ebe5
mov dword [ebp - 0x154], ebx
mov ecx, edx
mov ebx, dword [ebp - 0x158]
mov dword [ebp - 0x148], 0x3c
xor eax, esi
ror edx, 0x1b
xor eax, edi
add edx, eax
mov eax, dword [ebp - 0x148]
inc dword [ebp - 0x148]
add edx, dword [ebp + eax*4 - 0x144]
add edx, dword [0x5b3dd8]
add edx, dword [ebp - 0x150]
mov eax, dword [ebp - 0x14c]
mov dword [ebp - 0x150], eax
mov eax, esi
mov esi, edi
mov dword [ebp - 0x14c], eax
shr edi, 2
shl esi, 0x1e
or esi, edi
cmp dword [ebp - 0x148], 0x50
mov edi, ecx
mov ecx, edx
jl 0x47ec55
add dword [ebx + 0xc], eax
add edx, dword [ebx]
mov eax, dword [ebp - 0x150]
add dword [ebx + 4], edi
add dword [ebx + 8], esi
add dword [ebx + 0x10], eax
mov dword [ebx], edx
mov eax, dword [0x5b3dc4]
test eax, eax
je 0x47ece3
push dword [0x5b3dc8]
push str._s:__final__running_srtp_sha1_core___n
push 3
call fcn.0047a540
mov edx, dword [ebx]
add esp, 0xc
mov eax, dword [0x5b3dc4]
cmp dword [ebx + 0x54], 0x38
jl 0x47ef30
test eax, eax
je 0x47ed06
push dword [0x5b3dc8]
push str._s:__final__running_srtp_sha1_core___again_n
push 3
call fcn.0047a540
add esp, 0xc
mov eax, dword [ebx + 0x58]
lea ecx, [ebp - 0x13c]
xorps xmm0, xmm0
mov dword [ebp - 0x10c], 0
movups xmmword [ebp - 0x144], xmm0
mov dword [ebp - 0x108], eax
mov edx, 0x40
movups xmmword [ebp - 0x134], xmm0
movups xmmword [ebp - 0x124], xmm0
movq qword [ebp - 0x114], xmm0
mov eax, dword [ecx + 0x2c]
lea ecx, [ecx + 4]
xor eax, dword [ecx + 0x14]
xor eax, dword [ecx - 0xc]
xor eax, dword [ecx - 4]
ror eax, 0x1f
mov dword [ecx + 0x34], eax
sub edx, 1
jne 0x47ed44
mov edx, dword [ebx]
mov eax, dword [ebx + 0x10]
mov edi, dword [ebx + 4]
mov esi, dword [ebx + 8]
mov ecx, dword [ebx + 0xc]
mov ebx, ecx
mov dword [ebp - 0x154], edx
mov dword [ebp - 0x14c], eax
mov dword [ebp - 0x148], 0
mov eax, edx
mov ecx, esi
mov edx, edi
ror eax, 0x1b
and ecx, edi
not edx
and edx, ebx
or edx, ecx
mov ecx, dword [ebp - 0x148]
add eax, edx
add eax, dword [ebp + ecx*4 - 0x144]
inc ecx
add eax, dword [0x5b3dcc]
add eax, dword [ebp - 0x14c]
mov dword [ebp - 0x14c], ebx
mov edx, eax
mov ebx, esi
mov dword [ebp - 0x148], ecx
mov esi, edi
shr edi, 2
shl esi, 0x1e
or esi, edi
mov edi, dword [ebp - 0x154]
mov dword [ebp - 0x154], eax
cmp ecx, 0x14
jl 0x47ed84
mov dword [ebp - 0x150], ebx
mov ecx, ebx
mov dword [ebp - 0x148], 0x14
nop
xor ecx, esi
ror eax, 0x1b
xor ecx, edi
add eax, ecx
mov ecx, dword [ebp - 0x148]
inc dword [ebp - 0x148]
add eax, dword [ebp + ecx*4 - 0x144]
add eax, dword [0x5b3dd0]
add eax, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x150]
mov dword [ebp - 0x14c], ecx
mov ecx, esi
mov esi, edi
mov dword [ebp - 0x150], ecx
shr edi, 2
shl esi, 0x1e
or esi, edi
cmp dword [ebp - 0x148], 0x28
mov edi, edx
mov edx, eax
jl 0x47edf0
mov dword [ebp - 0x154], edx
mov ebx, eax
mov dword [ebp - 0x148], 0x28
mov edx, esi
ror eax, 0x1b
or edx, edi
and edx, ecx
mov ecx, esi
and ecx, edi
or edx, ecx
mov ecx, dword [ebp - 0x150]
add eax, edx
mov edx, dword [ebp - 0x148]
add eax, dword [ebp + edx*4 - 0x144]
inc edx
add eax, dword [0x5b3dd4]
add eax, dword [ebp - 0x14c]
mov dword [ebp - 0x14c], ecx
mov ecx, esi
mov esi, edi
mov dword [ebp - 0x150], ecx
shr edi, 2
shl esi, 0x1e
or esi, edi
mov dword [ebp - 0x148], edx
mov edi, ebx
mov ebx, eax
cmp edx, 0x3c
jl 0x47ee55
mov dword [ebp - 0x154], ebx
mov edx, eax
mov ebx, dword [ebp - 0x158]
mov dword [ebp - 0x148], 0x3c
xor ecx, esi
ror eax, 0x1b
xor ecx, edi
add eax, ecx
mov ecx, dword [ebp - 0x148]
inc dword [ebp - 0x148]
add eax, dword [ebp + ecx*4 - 0x144]
add eax, dword [0x5b3dd8]
add eax, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x150]
mov dword [ebp - 0x150], esi
mov dword [ebp - 0x14c], ecx
mov ecx, esi
mov esi, edi
shr edi, 2
shl esi, 0x1e
or esi, edi
cmp dword [ebp - 0x148], 0x50
mov edi, edx
mov edx, eax
jl 0x47eec5
mov edx, dword [ebx]
add dword [ebx + 0xc], ecx
add edx, eax
add dword [ebx + 4], edi
add dword [ebx + 8], esi
mov ecx, dword [ebp - 0x14c]
add dword [ebx + 0x10], ecx
mov dword [ebx], edx
mov esi, dword [sym.imp.WS2_32.dll_ntohl]
push edx
call esi
mov edi, dword [ebp - 0x15c]
mov dword [edi], eax
push dword [ebx + 4]
call esi
mov dword [edi + 4], eax
push dword [ebx + 8]
call esi
mov dword [edi + 8], eax
push dword [ebx + 0xc]
call esi
mov dword [edi + 0xc], eax
push dword [ebx + 0x10]
call esi
mov ecx, dword [ebp - 4]
mov dword [edi + 0x10], eax
xor ecx, ebp
pop edi
pop esi
mov dword [ebx + 0x54], 0
pop ebx
call fcn.0050101b
mov esp, ebp
pop ebp
ret