Function at 0x10055bb0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x488
mov dword [ebp - 0x64], edx
lea edx, [ebp - 0x88]
push esi
mov esi, ecx
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x6c], 0xff
call fcn.100556c0
test eax, eax
je 0x10055c0a
mov eax, dword [esi + 4]
mov dword [ebp - 0x4c], eax
cdq
xor eax, edx
sub eax, edx
mov dword [esi + 4], eax
cmp eax, 0x1000000
jbe 0x10055c11
mov ecx, dword [0x101a0df4]
mov eax, dword fs:[0x2c]
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x1015ea40
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
push ebx
mov ebx, dword [esi]
cmp ebx, 0x1000000
jbe 0x10055c3d
mov ecx, dword [0x101a0df4]
mov eax, dword fs:[0x2c]
pop ebx
pop esi
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x1015ea34
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x7c]
mov ecx, dword [ebp - 0x80]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x78]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x74]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 0x70]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x6c]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x30], eax
push edi
mov edi, dword [ebp - 0x84]
mov dword [ebp - 0x2c], edi
cmp ecx, 0xc
jne 0x10055c9b
mov edx, dword [ebp - 0x88]
mov dword [ebp - 0x24], edx
cmp edx, 0x18
jge 0x10055cba
mov ecx, edi
sub ecx, eax
mov eax, 0x55555556
sub ecx, 0x18
imul ecx
mov eax, edx
shr eax, 0x1f
add eax, edx
jmp 0x10055cb3
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x24], eax
cmp eax, 0x10
jge 0x10055cba
mov eax, edi
sub eax, dword [ebp - 0x30]
sub eax, ecx
sar eax, 2
mov dword [ebp - 0xc], eax
test eax, eax
jne 0x10055d22
mov eax, dword [esi + 0xa8]
sub eax, dword [esi + 0xb4]
add eax, dword [esi + 0xac]
cmp edi, eax
je 0x10055ce7
push 0x1515
push 0x1015eb30
push str.info.offset__s__callback_already_read___int___s__img_buffer___s__img_buffer_original_
call fcn.100ea0b8
add esp, 0xc
mov ecx, dword [esi + 0xac]
mov eax, dword [esi + 0xa8]
sub ecx, esi
add eax, 0xffffffd8
add eax, ecx
cmp edi, eax
je 0x10055d20
mov ecx, dword [0x101a0df4]
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], str.bad_offset
xor eax, eax
mov esp, ebp
pop ebp
ret
mov ebx, dword [esi]
cmp dword [ebp - 0x24], 0x18
mov ecx, dword [ebp - 0x14]
jne 0x10055d3c
cmp ecx, 0xff000000
jne 0x10055d3a
mov eax, 3
jmp 0x10055d46
mov ebx, dword [esi]
xor eax, eax
test ecx, ecx
setne al
add eax, 3
mov dword [esi + 8], eax
mov ecx, dword [esi + 4]
test ebx, ebx
js 0x10056a0f
jne 0x10055d5f
lea edi, [ebx*4]
jmp 0x10055d7f
mov eax, 0x7fffffff
cdq
idiv ebx
cmp eax, 4
jl 0x10056a0f
lea edi, [ebx*4]
test edi, edi
js 0x10056a0f
test ecx, ecx
js 0x10056a0f
je 0x10055d99
mov eax, 0x7fffffff
cdq
idiv ecx
cmp edi, eax
jg 0x10056a0f
test ebx, ebx
je 0x10055dae
mov eax, 0x7fffffff
cdq
idiv ebx
cmp eax, 4
jl 0x100569ed
lea edi, [ebx*4]
test ecx, ecx
je 0x10055dc9
mov eax, 0x7fffffff
cdq
idiv ecx
cmp edi, eax
jg 0x100569ed
imul ebx, ecx
lea eax, [ebx*4]
push eax
call fcn.100ea1ba
mov ebx, eax
add esp, 4
mov dword [ebp - 0x44], ebx
test ebx, ebx
je 0x100569ed
xor edi, edi
cmp dword [ebp - 0x24], 0x10
jge 0x100563cf
mov eax, dword [ebp - 0xc]
test eax, eax
je 0x100563a4
cmp eax, 0x100
jg 0x100563a4
mov dword [ebp - 8], edi
test eax, eax
jle 0x10055f37
lea ebx, [esi + 0x20]
nop dword [eax]
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x10055e39
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055e5c
cmp dword [esi + 0x20], 0
lea ebx, [esi + 0x20]
je 0x10055e5a
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055e5c
xor cl, cl
mov edx, ebx
mov ebx, dword [ebp - 8]
mov dword [ebp - 0x1c], edx
mov byte [ebp + ebx*4 - 0x486], cl
cmp eax, dword [esi + 0xb0]
jae 0x10055e7e
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055ea0
cmp dword [edx], 0
je 0x10055e9e
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov edx, dword [ebp - 0x1c]
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055ea0
xor cl, cl
mov byte [ebp + ebx*4 - 0x487], cl
mov ecx, dword [esi + 0xb0]
cmp eax, ecx
jae 0x10055ebf
mov dl, byte [eax]
lea ebx, [esi + 0x20]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055ee6
cmp dword [edx], 0
mov ebx, edx
je 0x10055ee4
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov ecx, dword [esi + 0xb0]
mov dl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055ee6
xor dl, dl
cmp dword [ebp - 0x34], 0xc
mov edi, dword [ebp - 8]
mov byte [ebp + edi*4 - 0x488], dl
mov edi, dword [ebp - 0xc]
je 0x10055f1b
cmp eax, ecx
jae 0x10055f06
inc eax
mov dword [esi + 0xac], eax
jmp 0x10055f1b
mov eax, dword [ebp - 0x1c]
cmp dword [eax], 0
je 0x10055f1b
mov ecx, esi
call fcn.1004c6e0
inc dword [esi + 0xac]
mov ecx, dword [ebp - 8]
mov byte [ebp + ecx*4 - 0x485], 0xff
inc ecx
mov dword [ebp - 8], ecx
cmp ecx, edi
jl 0x10055e20
mov ebx, dword [ebp - 0x44]
xor edi, edi
mov ecx, dword [ebp - 0x2c]
xor eax, eax
cmp dword [ebp - 0x34], 0xc
setne al
add eax, 3
imul eax, dword [ebp - 0xc]
sub ecx, eax
sub ecx, dword [ebp - 0x30]
sub ecx, dword [ebp - 0x34]
je 0x10055f9a
test ecx, ecx
jns 0x10055f66
mov eax, dword [esi + 0xb0]
mov dword [esi + 0xac], eax
jmp 0x10055f9a
cmp dword [esi + 0x10], 0
je 0x10055f94
mov edx, dword [esi + 0xb0]
mov eax, edx
sub eax, dword [esi + 0xac]
cmp eax, ecx
jge 0x10055f94
sub ecx, eax
mov dword [esi + 0xac], edx
mov eax, dword [esi + 0x14]
push ecx
push dword [esi + 0x1c]
call eax
add esp, 8
jmp 0x10055f9a
add dword [esi + 0xac], ecx
mov eax, dword [ebp - 0x24]
cmp eax, 1
jne 0x10055fac
mov ecx, dword [esi]
lea eax, [ecx + 7]
shr eax, 3
jmp 0x10055fc7
cmp eax, 4
jne 0x10055fba
mov ecx, dword [esi]
lea eax, [ecx + 1]
shr eax, 1
jmp 0x10055fc7
cmp eax, 8
jne 0x10056379
mov eax, dword [esi]
mov ecx, eax
mov edx, dword [esi + 4]
neg eax
and eax, 3
mov dword [ebp - 8], edx
cmp dword [ebp - 0x24], 1
mov dword [ebp - 0x38], eax
jne 0x10056195
mov dword [ebp - 0x3c], 0
test edx, edx
jle 0x10056371
nop
mov ecx, dword [esi + 0xac]
mov dword [ebp - 8], 7
cmp ecx, dword [esi + 0xb0]
jae 0x10056010
mov dl, byte [ecx]
inc ecx
mov dword [esi + 0xac], ecx
jmp 0x10056032
cmp dword [esi + 0x20], 0
je 0x10056030
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov dl, byte [eax]
lea ecx, [eax + 1]
mov dword [esi + 0xac], ecx
jmp 0x10056032
xor dl, dl
movzx edx, dl
mov eax, ecx
mov dword [ebp - 0x1c], edx
mov edx, dword [esi]
mov dword [ebp - 0x14], 0
test edx, edx
jle 0x1005613c
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x10], edx
mov ecx, dword [ebp - 8]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x1c]
sar eax, cl
and eax, 1
lea ecx, [eax*4]
movzx eax, byte [ebp + ecx - 0x488]
mov byte [edi + ebx], al
movzx eax, byte [ebp + ecx - 0x487]
mov byte [edi + ebx + 1], al
movzx eax, byte [ebp + ecx - 0x486]
mov ecx, dword [ebp - 0x18]
mov byte [edi + ebx + 2], al
mov eax, dword [ebp - 0x14]
inc eax
mov byte [edi + ebx + 3], 0xff
add edi, 4
mov dword [ebp - 0x14], eax
cmp eax, edx
je 0x1005613c
sub dword [ebp - 8], 1
jns 0x10056125
mov eax, ecx
mov dword [ebp - 8], 7
cmp eax, dword [esi + 0xb0]
jae 0x100560d9
mov cl, byte [eax]
mov edx, dword [ebp - 0x10]
mov byte [ebp - 1], cl
lea ecx, [eax + 1]
movzx ebx, byte [ebp - 1]
mov eax, ecx
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x44]
mov dword [esi + 0xac], ecx
jmp 0x1005612d
cmp dword [esi + 0x20], 0
je 0x1005610a
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov cl, byte [eax]
mov byte [ebp - 1], cl
lea ecx, [eax + 1]
movzx ebx, byte [ebp - 1]
mov eax, ecx
mov dword [esi + 0xac], ecx
mov edx, dword [esi]
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x44]
jmp 0x1005612d
mov edx, dword [ebp - 0x10]
mov ecx, eax
mov eax, dword [esi + 0xac]
mov byte [ebp - 1], 0
movzx ebx, byte [ebp - 1]
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x44]
jmp 0x1005612d
mov eax, dword [ebp - 0x28]
mov ecx, eax
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x10], edx
cmp dword [ebp - 0x14], edx
jl 0x10056051
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x10056179
cmp dword [esi + 0x10], 0
je 0x10056171
mov edx, dword [esi + 0xb0]
sub edx, ecx
cmp edx, eax
jge 0x10056171
mov ecx, dword [esi + 0xb0]
sub eax, edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
mov dword [esi + 0xac], ecx
call eax
add esp, 8
jmp 0x10056179
add eax, ecx
mov dword [esi + 0xac], eax
mov ecx, dword [ebp - 0x3c]
mov edx, dword [esi + 4]
inc ecx
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 8], edx
cmp ecx, edx
jl 0x10055ff0
mov ecx, edx
jmp 0x100568ed
xor eax, eax
mov dword [ebp - 0xc], eax
test edx, edx
jle 0x10056371
mov dword [ebp - 0x20], 0
mov edx, ecx
test ecx, ecx
jle 0x1005631e
nop dword [eax]
nop word [eax + eax]
mov eax, dword [esi + 0xb0]
mov ecx, edx
mov edx, dword [esi + 0xac]
mov dword [ebp - 0x10], edx
mov dword [ebp - 0x14], eax
cmp edx, eax
jae 0x100561e6
mov al, byte [edx]
inc edx
mov dword [ebp - 0x10], edx
mov dword [esi + 0xac], edx
jmp 0x1005621e
cmp dword [esi + 0x20], 0
je 0x10056214
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov cl, byte [eax]
lea edx, [eax + 1]
mov eax, dword [esi + 0xb0]
mov byte [ebp - 1], cl
mov ecx, dword [esi]
mov dword [ebp - 0x10], edx
mov dword [esi + 0xac], edx
jmp 0x10056218
mov byte [ebp - 1], 0
mov dword [ebp - 0x14], eax
mov al, byte [ebp - 1]
mov ebx, esi
movzx eax, al
mov edx, 0x20
mov dword [ebp - 0x18], eax
add edx, ebx
mov dword [ebp - 8], 0
cmp dword [ebp - 0x24], 4
mov ebx, dword [ebp - 0x44]
mov dword [ebp - 0x28], edx
mov edx, dword [ebp - 0x10]
jne 0x10056250
mov dword [ebp - 8], eax
and dword [ebp - 8], 0xf
shr eax, 4
mov dword [ebp - 0x18], eax
movzx eax, byte [ebp + eax*4 - 0x488]
mov byte [edi + ebx], al
mov eax, dword [ebp - 0x18]
movzx eax, byte [ebp + eax*4 - 0x487]
mov byte [edi + ebx + 1], al
mov eax, dword [ebp - 0x18]
movzx eax, byte [ebp + eax*4 - 0x486]
mov byte [edi + ebx + 2], al
mov eax, dword [ebp - 0x20]
mov byte [edi + ebx + 3], 0xff
inc eax
add edi, 4
cmp eax, ecx
je 0x1005631e
cmp dword [ebp - 0x24], 8
jne 0x100562da
cmp edx, dword [ebp - 0x14]
jae 0x100562ae
mov al, byte [edx]
mov byte [ebp - 1], al
lea eax, [edx + 1]
mov dl, byte [ebp - 1]
mov dword [esi + 0xac], eax
movzx edx, dl
jmp 0x100562dd
mov eax, dword [ebp - 0x28]
cmp dword [eax], 0
je 0x100562d3
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov dl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
mov ecx, dword [esi]
movzx edx, dl
jmp 0x100562dd
xor dl, dl
movzx edx, dl
jmp 0x100562dd
mov edx, dword [ebp - 8]
movzx eax, byte [ebp + edx*4 - 0x488]
mov byte [edi + ebx], al
movzx eax, byte [ebp + edx*4 - 0x487]
mov byte [edi + ebx + 1], al
movzx eax, byte [ebp + edx*4 - 0x486]
mov edx, ecx
mov byte [edi + ebx + 2], al
mov eax, dword [ebp - 0x20]
add eax, 2
mov byte [edi + ebx + 3], 0xff
add edi, 4
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x20], eax
cmp eax, ecx
jl 0x100561c0
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x1005635f
cmp dword [esi + 0x10], 0
je 0x10056359
mov edx, dword [esi + 0xb0]
sub edx, dword [esi + 0xac]
cmp edx, eax
jge 0x10056359
mov ecx, dword [esi + 0xb0]
sub eax, edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
mov dword [esi + 0xac], ecx
call eax
mov ecx, dword [esi]
add esp, 8
jmp 0x1005635f
add dword [esi + 0xac], eax
inc dword [ebp - 0xc]
mov edx, dword [esi + 4]
mov dword [ebp - 8], edx
cmp dword [ebp - 0xc], edx
jl 0x100561a2
mov ecx, dword [ebp - 8]
jmp 0x100568ed
push ebx
call fcn.100e467a
mov ecx, dword [0x101a0df4]
add esp, 4
mov eax, dword fs:[0x2c]
pop edi
mov eax, dword [eax + ecx*4]
pop ebx
pop esi
mov dword [eax + 0x10], str.bad_bpp
xor eax, eax
mov esp, ebp
pop ebp
ret
push ebx
call fcn.100e467a
mov ecx, dword [0x101a0df4]
add esp, 4
mov eax, dword fs:[0x2c]
pop edi
mov eax, dword [eax + ecx*4]
pop ebx
pop esi
mov dword [eax + 0x10], str.invalid
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x2c]
sub eax, dword [ebp - 0x30]
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x5c], 0
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], edi
sub eax, dword [ebp - 0x34]
je 0x1005645d
test eax, eax
jns 0x1005642a
mov eax, dword [esi + 0xb0]
mov dword [esi + 0xac], eax
jmp 0x1005645d
cmp dword [esi + 0x10], edi
je 0x10056457
mov edx, dword [esi + 0xb0]
mov ecx, edx
sub ecx, dword [esi + 0xac]
cmp ecx, eax
jge 0x10056457
sub eax, ecx
mov dword [esi + 0xac], edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
add esp, 8
jmp 0x1005645d
add dword [esi + 0xac], eax
mov ecx, dword [ebp - 0x24]
cmp ecx, 0x18
jne 0x1005646c
mov eax, dword [esi]
lea eax, [eax + eax*2]
jmp 0x10056479
cmp ecx, 0x10
jne 0x10056477
mov eax, dword [esi]
add eax, eax
jmp 0x10056479
xor eax, eax
neg eax
and eax, 3
mov dword [ebp - 0x60], eax
cmp ecx, 0x18
jne 0x10056492
mov dword [ebp - 0x18], 1
jmp 0x10056661
mov edx, dword [ebp - 8]
cmp ecx, 0x20
mov ecx, dword [ebp - 0x20]
jne 0x100564cb
cmp edx, 0xff
jne 0x100564cb
cmp dword [ebp - 0x10], 0xff00
jne 0x100564cb
cmp ecx, 0xff0000
jne 0x100564cb
cmp dword [ebp - 0x14], 0xff000000
jne 0x100564e9
mov dword [ebp - 0x18], 2
jmp 0x10056661
xor eax, eax
mov dword [ebp - 0x18], eax
test ecx, ecx
je 0x100569c2
cmp dword [ebp - 0x10], eax
je 0x100569c2
test edx, edx
je 0x100569c2
call fcn.100555e0
sub eax, 7
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x20]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x10]
movzx eax, al
mov dword [ebp - 0x48], eax
call fcn.100555e0
sub eax, 7
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x10]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 8]
movzx eax, al
mov dword [ebp - 0x38], eax
call fcn.100555e0
sub eax, 7
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 8]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x14]
movzx eax, al
mov dword [ebp - 0x3c], eax
call fcn.100555e0
sub eax, 7
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x14]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
cmp dword [ebp - 0x48], 8
movzx eax, al
mov dword [ebp - 0x5c], eax
ja 0x10056997
cmp dword [ebp - 0x38], 8
ja 0x10056997
cmp dword [ebp - 0x3c], 8
ja 0x10056997
cmp eax, 8
ja 0x10056997
mov edx, dword [esi + 4]
mov ecx, edx
mov dword [ebp - 0x30], edi
test edx, edx
jle 0x100568ed
cmp dword [ebp - 0x18], 0
mov eax, dword [esi]
je 0x100567f1
mov dword [ebp - 0x34], 0
test eax, eax
jle 0x1005689c
lea edx, [esi + 0x20]
nop
mov eax, dword [esi + 0xac]
mov dword [ebp - 0xc], edx
cmp eax, dword [esi + 0xb0]
jae 0x100566af
mov cl, byte [eax]
inc eax
mov byte [ebp - 1], cl
mov dword [esi + 0xac], eax
jmp 0x100566e0
cmp dword [esi + 0x20], 0
lea edx, [esi + 0x20]
mov dword [ebp - 0xc], edx
je 0x100566d9
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov edx, dword [ebp - 0xc]
mov cl, byte [eax]
inc eax
mov byte [ebp - 1], cl
mov dword [esi + 0xac], eax
jmp 0x100566e0
mov byte [ebp - 1], 0
mov dword [ebp - 0xc], edx
mov ecx, eax
mov dword [ebp - 0x1c], edx
mov dl, byte [ebp - 1]
mov byte [edi + ebx + 2], dl
mov edx, dword [ebp - 0xc]
cmp eax, dword [esi + 0xb0]
jae 0x10056707
mov cl, byte [eax]
inc eax
mov byte [ebp - 1], cl
mov ecx, eax
mov dword [esi + 0xac], eax
jmp 0x1005672d
cmp dword [edx], 0
je 0x10056729
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov cl, byte [eax]
inc eax
mov byte [ebp - 1], cl
mov ecx, eax
mov dword [esi + 0xac], eax
jmp 0x1005672d
mov byte [ebp - 1], 0
mov dl, byte [ebp - 1]
mov byte [edi + ebx + 1], dl
mov edx, dword [esi + 0xb0]
cmp eax, edx
mov dword [ebp - 0x2c], edx
mov edx, dword [ebp - 0xc]
jae 0x10056757
mov dl, byte [eax]
lea ecx, [eax + 1]
lea eax, [esi + 0x20]
mov dword [esi + 0xac], ecx
mov dword [ebp - 0xc], eax
jmp 0x10056786
cmp dword [edx], 0
je 0x1005677c
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov dl, byte [eax]
lea ecx, [eax + 1]
mov eax, dword [esi + 0xb0]
mov dword [esi + 0xac], ecx
jmp 0x10056789
mov byte [ebp - 1], 0
mov dword [ebp - 0xc], edx
mov dl, byte [ebp - 1]
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x18], 2
mov byte [edi + ebx], dl
jne 0x100567c7
cmp ecx, eax
jae 0x100567a3
mov dl, byte [ecx]
lea eax, [ecx + 1]
mov dword [esi + 0xac], eax
jmp 0x100567ca
mov eax, dword [ebp - 0x1c]
cmp dword [eax], 0
je 0x100567c3
mov ecx, esi
call fcn.1004c6e0
mov eax, dword [esi + 0xac]
mov dl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x100567ca
xor dl, dl
jmp 0x100567ca
or dl, 0xff
mov ecx, dword [ebp - 0x34]
movzx eax, dl
inc ecx
or dword [ebp - 0x40], eax
mov byte [edi + ebx + 3], dl
add edi, 4
mov edx, dword [ebp - 0xc]
mov dword [ebp - 0x34], ecx
cmp ecx, dword [esi]
jl 0x10056690
mov dword [ebp - 0x1c], edi
jmp 0x1005689c
mov dword [ebp - 0x2c], 0
test eax, eax
jle 0x1005689c
mov ecx, esi
call fcn.1004c870
cmp dword [ebp - 0x24], 0x10
je 0x1005681e
mov ecx, esi
mov edi, eax
call fcn.1004c870
shl eax, 0x10
add eax, edi
mov edi, dword [ebp - 0x1c]
push dword [ebp - 0x48]
mov edx, dword [ebp - 0x50]
mov ecx, eax
and ecx, dword [ebp - 0x20]
mov dword [ebp - 0xc], eax
call fcn.10055640
mov ecx, dword [ebp - 0xc]
push dword [ebp - 0x38]
and ecx, dword [ebp - 0x10]
mov edx, dword [ebp - 0x54]
mov byte [edi + ebx], al
call fcn.10055640
mov ecx, dword [ebp - 0xc]
push dword [ebp - 0x3c]
and ecx, dword [ebp - 8]
mov edx, dword [ebp - 0x58]
mov byte [edi + ebx + 1], al
call fcn.10055640
mov ecx, dword [ebp - 0x14]
add esp, 0xc
mov byte [edi + ebx + 2], al
test ecx, ecx
je 0x1005687b
push dword [ebp - 0x5c]
and ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x28]
call fcn.10055640
add esp, 4
jmp 0x10056880
mov eax, 0xff
or dword [ebp - 0x40], eax
mov byte [edi + ebx + 3], al
add edi, 4
mov eax, dword [ebp - 0x2c]
inc eax
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x2c], eax
cmp eax, dword [esi]
jl 0x10056800
mov edx, dword [ebp - 0x60]
test edx, edx
je 0x100568d9
cmp dword [esi + 0x10], 0
je 0x100568d3
mov eax, dword [esi + 0xb0]
mov ecx, eax
sub ecx, dword [esi + 0xac]
cmp ecx, edx
jge 0x100568d3
mov dword [esi + 0xac], eax
mov eax, edx
sub eax, ecx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
add esp, 8
jmp 0x100568d9
add dword [esi + 0xac], edx
mov eax, dword [ebp - 0x30]
mov edx, dword [esi + 4]
inc eax
mov dword [ebp - 0x30], eax
mov ecx, edx
cmp eax, edx
jl 0x10056671
cmp dword [ebp - 0x40], 0
jne 0x1005690f
mov eax, dword [esi]
imul eax, edx
lea eax, [eax*4 - 1]
test eax, eax
js 0x1005690f
mov byte [eax + ebx], 0xff
sub eax, 4
jns 0x10056903
mov ecx, dword [esi + 4]
cmp dword [ebp - 0x4c], 0
jle 0x1005697f
xor edi, edi
mov dword [ebp - 0x28], edi
test ecx, 0xfffffffe
jle 0x1005697f
mov eax, dword [esi]
sub ecx, edi
dec ecx
mov edx, eax
imul ecx, eax
imul edx, edi
xor edi, edi
shl eax, 2
shl ecx, 2
shl edx, 2
mov dword [ebp - 0x4c], edx
lea edx, [ecx + ebx]
test eax, eax
jle 0x1005696d
mov ebx, dword [ebp - 0x4c]
sub ebx, ecx
nop dword [eax]
mov al, byte [edx]
lea edx, [edx + 1]
mov cl, byte [edx + ebx - 1]
inc edi
mov byte [edx + ebx - 1], al
mov byte [edx - 1], cl
mov eax, dword [esi]
shl eax, 2
cmp edi, eax
jl 0x10056950
mov ebx, dword [ebp - 0x44]
mov edi, dword [ebp - 0x28]
mov ecx, dword [esi + 4]
inc edi
mov eax, ecx
mov dword [ebp - 0x28], edi
sar eax, 1
cmp edi, eax
jl 0x10056922
mov ecx, dword [ebp - 0x64]
mov eax, dword [esi]
pop edi
mov dword [ecx], eax
mov eax, dword [ebp + 8]
mov ecx, dword [esi + 4]
mov dword [eax], ecx
mov eax, ebx
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
push ebx
call fcn.100e467a
mov ecx, dword [0x101a0df4]
add esp, 4
mov eax, dword fs:[0x2c]
pop edi
mov eax, dword [eax + ecx*4]
pop ebx
pop esi
mov dword [eax + 0x10], str.bad_masks
xor eax, eax
mov esp, ebp
pop ebp
ret
push ebx
call fcn.100e467a
mov ecx, dword [0x101a0df4]
add esp, 4
mov eax, dword fs:[0x2c]
pop edi
mov eax, dword [eax + ecx*4]
pop ebx
pop esi
mov dword [eax + 0x10], 0x1015eda4
xor eax, eax
mov esp, ebp
pop ebp
ret
mov ecx, dword [0x101a0df4]
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x1015ed98
xor eax, eax
mov esp, ebp
pop ebp
ret
mov ecx, dword [0x101a0df4]
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x1015ed78
xor eax, eax
mov esp, ebp
pop ebp
ret