Function at 0x47be00
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0xc
push ebx
push ebp
mov ebp, dword [esp + 0x18]
push esi
push edi
mov esi, dword [ebp + 0x440]
mov esi, dword [esi]
cmp byte [esi + 0xcf], 0
jne 0x47bf97
mov edi, dword [esi + 0x138]
lea ebx, [esi + 0x21]
test edi, edi
jne 0x47be4c
push 0x130
push 1
call fcn.00681a00
mov edi, eax
add esp, 8
mov dword [esi + 0x138], edi
test edi, edi
je 0x47bfd8
mov dword [edi + 0x12c], 0xffffffe7
test ebx, ebx
je 0x47bff5
cmp byte [ebx], 0x6c
jne 0x47bff5
cmp byte [ebx + 1], 0x68
jne 0x47bff5
movsx eax, byte [ebx + 2]
sub eax, 0x35
je 0x47be94
sub eax, 1
je 0x47be8d
sub eax, 1
jne 0x47bff5
lea ebx, [eax + 0x10]
jmp 0x47be99
mov ebx, 0xf
jmp 0x47be99
mov ebx, 0xd
mov eax, dword [edi + 0xc]
mov dword [edi + 0x12c], 0xffffffe2
mov dword [edi + 4], 0x20000
mov dword [edi + 8], 0x1ffff
test eax, eax
jne 0x47bed0
push 0x20000
call fcn.006883b5
add esp, 4
mov dword [edi + 0xc], eax
test eax, eax
je 0x47bfd8
mov ecx, ebx
mov edx, 1
shl edx, cl
push edx
sub eax, edx
add eax, dword [edi + 4]
push 0x20
push eax
call fcn.0067ddd0
add esp, 0xc
mov dword [edi + 0x10], 0
mov dword [edi], 0
lea eax, [ebx + 1]
mov dword [edi + 0x114], eax
cmp ebx, 0xf
je 0x47bf0f
mov eax, 4
cmp ebx, 0x10
jne 0x47bf14
mov eax, 5
push 0x10
mov dword [edi + 0x118], eax
lea eax, [edi + 0x30]
push 0x1fe
push eax
mov dword [edi + 0x11c], 0x13
mov dword [edi + 0x120], 5
mov dword [edi + 0x20], 0
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
call fcn.0047dd30
add esp, 0xc
test eax, eax
jne 0x47bfd8
push 0x10
lea eax, [edi + 0xa0]
mov dword [edi + 0x38], 9
push 0x13
push eax
call fcn.0047dd30
add esp, 0xc
test eax, eax
jne 0x47bfd8
mov dword [edi + 0x12c], eax
mov byte [esi + 0xcf], 1
mov dword [esi + 0x12c], eax
mov dword [esi + 0x130], eax
mov dword [esi + 0x134], eax
lea eax, [esp + 0x10]
push eax
push 1
push ebp
lea edi, [esi + 0x118]
call fcn.00468650
mov dword [edi], eax
add esp, 0xc
mov ecx, dword [esp + 0x10]
test ecx, ecx
jg 0x47c04c
push str.Truncated_LHa_file_body
push 0x2a
push ebp
call fcn.00469db0
add esp, 0xc
mov eax, 0xffffffe2
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
push str.Couldnt_allocate_memory_for_lzh_decompression
push 0xc
push ebp
call fcn.00469db0
add esp, 0xc
mov eax, 0xffffffe2
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
mov eax, dword [esp + 0x24]
mov dword [eax], 0
mov eax, dword [esp + 0x28]
mov dword [eax], 0
mov eax, dword [esp + 0x2c]
mov dword [eax], 0
mov dword [eax + 4], 0
movsx eax, byte [esi + 0x23]
push eax
movsx eax, byte [esi + 0x22]
push eax
movsx eax, byte [esi + 0x21]
push eax
push str.Unsupported_lzh_compression_method___c_c_c_
push 0x2a
push ebp
call fcn.00469db0
push ebp
call fcn.0047b040
add esp, 0x1c
mov eax, 0xffffffec
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
mov ebx, dword [esi + 8]
mov eax, ecx
cdq
cmp edx, dword [esi + 0xc]
jl 0x47c063
jg 0x47c05d
cmp eax, ebx
jbe 0x47c063
mov ecx, ebx
mov dword [esp + 0x10], ecx
mov dword [esi + 0x11c], ecx
mov dword [esi + 0x120], 0
mov dword [esi + 0x124], 0
mov dword [esi + 0x12c], 0
mov eax, dword [esp + 0x10]
cdq
cmp eax, dword [esi + 8]
jne 0x47c09d
cmp edx, dword [esi + 0xc]
jne 0x47c09d
mov ebx, 1
jmp 0x47c09f
xor ebx, ebx
mov ecx, dword [edi + 0x20]
mov dword [esp + 0x14], ecx
mov ecx, dword [ecx + 0x12c]
test ecx, ecx
jne 0x47c0f0
mov eax, dword [edi + 4]
mov ebp, dword [esp + 0x14]
mov dword [esp + 0x18], eax
nop dword [eax + eax]
cmp dword [ebp], 9
push ebx
push edi
jge 0x47c0cf
call fcn.0047e260
jmp 0x47c0d4
call fcn.0047d760
mov ecx, eax
add esp, 8
cmp ecx, 0x64
je 0x47c0c0
mov eax, dword [esp + 0x18]
sub eax, dword [edi + 4]
mov ebp, dword [esp + 0x20]
cdq
add dword [edi + 8], eax
adc dword [edi + 0xc], edx
sub ecx, 0
je 0x47c11e
sub ecx, 1
je 0x47c117
push str.Bad_lzh_data
push 0xffffffffffffffff
push ebp
call fcn.00469db0
add esp, 0xc
mov eax, 0xffffffe7
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
mov byte [esi + 0xd0], 1
mov eax, dword [esi + 0x120]
sub dword [esi + 8], eax
mov edx, dword [esi + 0x124]
mov edi, dword [esi + 0x12c]
mov ecx, dword [esi]
mov dword [esi + 0x10], eax
mov eax, dword [esi + 0xc]
sbb eax, edx
mov dword [esi + 0x14], edx
mov edx, dword [esi + 4]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 0x2c]
mov dword [eax], ecx
mov dword [eax + 4], edx
test edi, edi
je 0x47c2a6
mov ebp, dword [esp + 0x28]
mov eax, dword [esi + 0x12c]
mov dword [ebp], eax
mov eax, dword [esp + 0x24]
mov edx, dword [esi + 0x128]
mov dword [eax], edx
mov edi, dword [ebp]
movzx ecx, word [esi + 0x18]
mov dword [esp + 0x20], ecx
test edi, edi
je 0x47c28a
test dl, 1
je 0x47c1a5
movzx eax, byte [edx]
inc edx
xor eax, ecx
shr cx, 8
movzx eax, al
xor cx, word [eax*2 + 0x75b520]
dec edi
movzx ecx, cx
mov dword [esp + 0x20], ecx
cmp edi, 8
jb 0x47c25e
mov ebx, edi
shr ebx, 3
mov ax, word [esp + 0x20]
sub edi, 8
xor ax, word [edx]
movzx eax, ax
mov ecx, eax
movzx eax, al
shr ecx, 8
movzx ecx, word [ecx*2 + 0x75b520]
xor cx, word [eax*2 + 0x75b720]
movzx eax, cx
mov dword [esp + 0x20], eax
xor ax, word [edx + 2]
movzx eax, ax
mov ecx, eax
movzx eax, al
shr ecx, 8
movzx ecx, word [ecx*2 + 0x75b520]
xor cx, word [eax*2 + 0x75b720]
movzx eax, cx
mov dword [esp + 0x20], eax
xor ax, word [edx + 4]
movzx eax, ax
mov ecx, eax
movzx eax, al
shr ecx, 8
movzx ecx, word [ecx*2 + 0x75b520]
xor cx, word [eax*2 + 0x75b720]
movzx eax, cx
mov dword [esp + 0x20], eax
xor ax, word [edx + 6]
add edx, 8
movzx eax, ax
mov ecx, eax
movzx eax, al
shr ecx, 8
movzx ecx, word [ecx*2 + 0x75b520]
xor cx, word [eax*2 + 0x75b720]
movzx ecx, cx
mov dword [esp + 0x20], ecx
sub ebx, 1
jne 0x47c1b3
test edi, edi
je 0x47c28a
movzx eax, byte [edx]
lea edx, [edx + 1]
xor eax, ecx
mov cx, word [esp + 0x20]
movzx eax, al
shr cx, 8
xor cx, word [eax*2 + 0x75b520]
movzx ecx, cx
mov dword [esp + 0x20], ecx
sub edi, 1
jne 0x47c262
mov ax, word [esp + 0x20]
mov word [esi + 0x18], ax
mov eax, dword [ebp]
add dword [esi], eax
adc dword [esi + 4], 0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xc
ret
mov eax, dword [esp + 0x28]
mov dword [eax], 0
mov eax, dword [esp + 0x24]
mov dword [eax], 0
cmp byte [esi + 0xd0], 0
je 0x47c29c
push ebp
call fcn.0047bdb0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret