Function at 0x543f30
Capabilities:
Encode data using xor
Encrypt data using xtea

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x4c
mov edx, dword [ebp + 0xc]
movzx eax, word [edx + 4]
sub eax, 6
test al, 7
je 0x54403c
mov dword [esp + 4], str._Failure___Protocol::XTEA_decrypt__Not_valid_encrypted_message_size
mov dword [esp], 0x7bfa20
call fcn.0076107c
mov ecx, dword [ebp + 8]
mov dword [esp], ecx
call fcn.00543e96
test eax, eax
je 0x544029
lea edx, [ebp - 0x24]
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.0058a3e6
sub esp, 4
mov dword [esp + 4], str.__IP:
mov dword [esp], 0x7bfa20
call fcn.0076107c
mov edx, dword [ebp - 0x24]
mov ecx, dword [edx - 0xc]
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.00757358
mov dword [esp + 4], 0x7e6487
mov dword [esp], eax
call fcn.0076107c
jmp 0x543fd5
mov esi, dword [ebp - 0x24]
sub esi, 0xc
cmp esi, 0x7bf7a4
je 0x544029
cmp dword [0x8e6f60], 0
je 0x544003
mov dword [esp + 4], 0xffffffff
lea eax, [esi + 8]
mov dword [esp], eax
call fcn.006b2de0
mov ebx, eax
jmp 0x54400c
mov ebx, dword [esi + 8]
lea eax, [ebx - 1]
mov dword [esi + 8], eax
test ebx, ebx
jg 0x544029
lea eax, [ebp - 0x1a]
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.00702c78
jmp 0x544029
mov dword [esp], 0x7bfa20
call fcn.0075c288
mov al, 0
jmp 0x544215
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x1c]
mov dword [ebp - 0x34], edx
mov edx, dword [ecx + 0x20]
mov dword [ebp - 0x30], edx
mov edx, dword [ecx + 0x24]
mov dword [ebp - 0x2c], edx
mov edx, dword [ecx + 0x28]
mov dword [ebp - 0x28], edx
mov ecx, dword [ebp + 0xc]
movzx edx, word [ecx + 6]
lea edx, [ecx + edx + 8]
mov dword [ebp - 0x40], edx
test eax, eax
jns 0x54406c
add eax, 3
sar eax, 2
mov dword [ebp - 0x48], eax
test eax, eax
jle 0x5440f4
mov dword [ebp - 0x3c], 0
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x44], eax
mov edx, dword [ebp - 0x40]
mov esi, dword [edx + eax*4]
mov edi, dword [edx + eax*4 + 4]
mov ebx, 0xc6ef3720
mov eax, ebx
shr eax, 0xb
and eax, 3
mov ecx, dword [ebp + eax*4 - 0x34]
lea eax, [ebx + ecx]
mov ecx, esi
shr ecx, 5
mov edx, esi
shl edx, 4
xor edx, ecx
add edx, esi
xor eax, edx
sub edi, eax
add ebx, 0x61c88647
mov eax, ebx
and eax, 3
mov edx, dword [ebp + eax*4 - 0x34]
lea eax, [ebx + edx]
mov ecx, edi
shr ecx, 5
mov edx, edi
shl edx, 4
xor edx, ecx
add edx, edi
xor eax, edx
sub esi, eax
test ebx, ebx
jne 0x544092
mov ecx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x40]
mov dword [eax + ecx*4], esi
mov dword [eax + ecx*4 + 4], edi
add dword [ebp - 0x3c], 2
mov edx, dword [ebp - 0x48]
cmp dword [ebp - 0x3c], edx
jl 0x54407d
mov ecx, dword [ebp + 0xc]
mov ax, word [ecx + 6]
movzx edx, ax
mov bx, word [ecx + edx + 8]
add eax, 2
mov word [ecx + 6], ax
movzx esi, bx
movzx eax, word [ecx + 4]
sub eax, 8
cmp esi, eax
jle 0x54420c
mov dword [esp + 4], str._Failure___Protocol::XTEA_decrypt__Not_valid_unencrypted_message_size
mov dword [esp], 0x7bfa20
call fcn.0076107c
mov eax, dword [ebp + 8]
mov dword [esp], eax
call fcn.00543e96
mov ebx, eax
test eax, eax
je 0x5441fc
lea eax, [ebp - 0x20]
mov dword [esp + 4], ebx
mov dword [esp], eax
call fcn.0058a3e6
sub esp, 4
mov dword [esp + 4], str.__IP:
mov dword [esp], 0x7bfa20
call fcn.0076107c
mov edx, dword [ebp - 0x20]
mov ecx, dword [edx - 0xc]
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.00757358
mov dword [esp + 4], 0x7e6487
mov dword [esp], eax
call fcn.0076107c
jmp 0x5441a8
mov esi, dword [ebp - 0x20]
sub esi, 0xc
cmp esi, 0x7bf7a4
je 0x5441fc
cmp dword [0x8e6f60], 0
je 0x5441d6
mov dword [esp + 4], 0xffffffff
lea eax, [esi + 8]
mov dword [esp], eax
call fcn.006b2de0
mov ebx, eax
jmp 0x5441df
mov ebx, dword [esi + 8]
lea eax, [ebx - 1]
mov dword [esi + 8], eax
test ebx, ebx
jg 0x5441fc
lea eax, [ebp - 0x19]
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.00702c78
jmp 0x5441fc
mov dword [esp], 0x7bfa20
call fcn.0075c288
mov al, 0
jmp 0x544215
mov edx, dword [ebp + 0xc]
mov word [edx + 4], bx
mov al, 1
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
leave
ret