Function at 0x4984d7
Capabilities:
Encrypt data using speck

Disassembly:
sub esp, 0x14
push ebx
push ebp
push esi
mov esi, dword [esp + 0x28]
xor edx, edx
inc edx
push edi
mov edi, dword [esp + 0x28]
mov bl, byte [esi]
movzx ebp, bl
and ebp, edx
mov dword [esp + 0x18], ebp
cmp edi, 0x100
jae 0x498542
mov al, bl
and al, 2
test bl, 4
jne 0x49851f
test al, al
je 0x498538
mov ecx, edi
shr edi, 3
and ecx, 7
shl edx, cl
push 0
test byte [edi + esi + 1], dl
pop eax
setne al
jmp 0x49853a
test al, al
je 0x498542
mov eax, edi
mov ecx, edi
and ecx, 7
shr eax, 3
shl edx, cl
test byte [eax + esi + 1], dl
je 0x498542
xor ebp, 1
mov eax, ebp
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret
inc esi
test bl, 2
je 0x49854b
add esi, 0x20
mov cl, byte [esi]
test cl, cl
je 0x498538
mov eax, edi
mov ebp, 0x80
cdq
idiv ebp
mov dword [esp + 0x20], edx
mov dword [esp + 0x1c], eax
cmp cl, 1
jne 0x498677
movzx edx, byte [esi + 1]
add esi, 2
cmp edx, 0xc0
jb 0x498663
lea ebx, [esi + 1]
test dl, 0x20
jne 0x49859c
movzx eax, byte [esi]
and edx, 0x1f
and eax, 0x3f
shl edx, 6
or edx, eax
mov esi, ebx
jmp 0x498663
lea ebp, [esi + 2]
test dl, 0x10
jne 0x4985c4
movzx ecx, byte [esi]
and edx, 0xf
movzx eax, byte [ebx]
and ecx, 0x3f
shl edx, 6
and eax, 0x3f
or edx, ecx
mov esi, ebp
shl edx, 6
or edx, eax
jmp 0x498663
movzx eax, byte [esi]
lea ecx, [esi + 3]
and eax, 0x3f
mov dword [esp + 0x14], ecx
test dl, 8
jne 0x4985f9
and edx, 7
mov esi, ecx
shl edx, 6
or edx, eax
movzx eax, byte [ebx]
and eax, 0x3f
shl edx, 6
or edx, eax
movzx eax, byte [ebp]
shl edx, 6
and eax, 0x3f
or edx, eax
jmp 0x498663
lea ecx, [esi + 4]
mov dword [esp + 0x2c], ecx
movzx ecx, byte [ebx]
movzx ebx, byte [ebp]
and ecx, 0x3f
mov ebp, dword [esp + 0x14]
and ebx, 0x3f
movzx ebp, byte [ebp]
and ebp, 0x3f
test dl, 4
jne 0x49863a
mov esi, dword [esp + 0x2c]
and edx, 3
shl edx, 6
or edx, eax
shl edx, 6
or edx, ecx
shl edx, 6
or edx, ebx
shl edx, 6
or edx, ebp
jmp 0x498663
and edx, 1
shl edx, 6
or edx, eax
mov eax, dword [esp + 0x2c]
shl edx, 6
or edx, ecx
shl edx, 6
movzx eax, byte [eax]
or edx, ebx
shl edx, 6
and eax, 0x3f
or edx, ebp
shl edx, 6
or edx, eax
add esi, 5
cmp edi, edx
jne 0x498960
mov eax, dword [esp + 0x18]
xor eax, 1
jmp 0x49853a
cmp cl, 2
jne 0x498899
movzx edx, byte [esi + 1]
add esi, 2
cmp edx, 0xc0
jb 0x498777
lea ebx, [esi + 1]
test dl, 0x20
jne 0x4986b0
movzx eax, byte [esi]
and edx, 0x1f
and eax, 0x3f
shl edx, 6
or edx, eax
mov esi, ebx
jmp 0x498777
lea ebp, [esi + 2]
test dl, 0x10
jne 0x4986d8
movzx ecx, byte [esi]
and edx, 0xf
movzx eax, byte [ebx]
and ecx, 0x3f
shl edx, 6
and eax, 0x3f
or edx, ecx
mov esi, ebp
shl edx, 6
or edx, eax
jmp 0x498777
movzx eax, byte [esi]
lea ecx, [esi + 3]
and eax, 0x3f
mov dword [esp + 0x14], ecx
test dl, 8
jne 0x49870d
and edx, 7
mov esi, ecx
shl edx, 6
or edx, eax
movzx eax, byte [ebx]
and eax, 0x3f
shl edx, 6
or edx, eax
movzx eax, byte [ebp]
shl edx, 6
and eax, 0x3f
or edx, eax
jmp 0x498777
lea ecx, [esi + 4]
mov dword [esp + 0x2c], ecx
movzx ecx, byte [ebx]
movzx ebx, byte [ebp]
and ecx, 0x3f
mov ebp, dword [esp + 0x14]
and ebx, 0x3f
movzx ebp, byte [ebp]
and ebp, 0x3f
test dl, 4
jne 0x49874e
mov esi, dword [esp + 0x2c]
and edx, 3
shl edx, 6
or edx, eax
shl edx, 6
or edx, ecx
shl edx, 6
or edx, ebx
shl edx, 6
or edx, ebp
jmp 0x498777
and edx, 1
shl edx, 6
or edx, eax
mov eax, dword [esp + 0x2c]
shl edx, 6
or edx, ecx
shl edx, 6
movzx eax, byte [eax]
or edx, ebx
shl edx, 6
and eax, 0x3f
or edx, ebp
shl edx, 6
or edx, eax
add esi, 5
movzx ebx, byte [esi]
inc esi
cmp ebx, 0xc0
jb 0x498884
lea ebp, [esi + 1]
test bl, 0x20
jne 0x4987a4
movzx eax, byte [esi]
and ebx, 0x1f
and eax, 0x3f
shl ebx, 6
or ebx, eax
mov esi, ebp
jmp 0x498884
lea ecx, [esi + 2]
mov dword [esp + 0x2c], ecx
test bl, 0x10
jne 0x4987d3
movzx ecx, byte [esi]
and ebx, 0xf
movzx eax, byte [ebp]
and ecx, 0x3f
mov esi, dword [esp + 0x2c]
and eax, 0x3f
shl ebx, 6
or ebx, ecx
shl ebx, 6
or ebx, eax
jmp 0x498884
lea eax, [esi + 3]
mov dword [esp + 0x10], eax
movzx eax, byte [esi]
and eax, 0x3f
test bl, 8
jne 0x49880a
mov esi, dword [esp + 0x10]
and ebx, 7
shl ebx, 6
or ebx, eax
movzx eax, byte [ebp]
and eax, 0x3f
shl ebx, 6
or ebx, eax
movzx eax, byte [ecx]
shl ebx, 6
and eax, 0x3f
or ebx, eax
jmp 0x498884
mov edi, dword [esp + 0x10]
lea ecx, [esi + 4]
mov dword [esp + 0x14], ecx
movzx ecx, byte [ebp]
mov ebp, dword [esp + 0x2c]
and ecx, 0x3f
movzx edi, byte [edi]
and edi, 0x3f
mov dword [esp + 0x2c], edi
movzx ebp, byte [ebp]
mov edi, dword [esp + 0x28]
and ebp, 0x3f
test bl, 4
jne 0x498859
mov esi, dword [esp + 0x14]
and ebx, 3
shl ebx, 6
or ebx, eax
shl ebx, 6
or ebx, ecx
shl ebx, 6
or ebx, ebp
shl ebx, 6
or ebx, dword [esp + 0x2c]
jmp 0x498884
and ebx, 1
shl ebx, 6
or ebx, eax
mov eax, dword [esp + 0x14]
shl ebx, 6
or ebx, ecx
shl ebx, 6
movzx eax, byte [eax]
or ebx, ebp
shl ebx, 6
and eax, 0x3f
or ebx, dword [esp + 0x2c]
shl ebx, 6
or ebx, eax
add esi, 5
cmp edi, edx
jb 0x498960
cmp edi, ebx
jbe 0x49866b
jmp 0x498960
movzx eax, word [eax*2 + 0x550a58]
xor ebx, ebx
shl eax, 7
add eax, edx
movzx eax, word [eax*2 + 0x554e58]
imul edx, eax, 0xc
movzx eax, byte [esi + 1]
add edx, 0x54c848
cmp cl, 3
sete bl
cmp eax, 0x10
ja case.0x4988cc.10
jmp dword [eax*4 + 0x498c03]
cmp cl, 3
jmp 0x498957
mov al, byte [edx + 1]
cmp al, 9
je 0x498952
cmp al, 5
je 0x498952
cmp al, 8
jmp 0x498bee
movzx eax, byte [edx + 1]
movzx ecx, byte [esi + 2]
sub ecx, dword [eax*4 + 0x5683c8]
neg ecx
sbb ecx, ecx
inc ecx
cmp ecx, ebx
jmp 0x498957
mov al, byte [esi + 2]
xor ecx, ecx
cmp al, byte [edx + 1]
sete cl
jmp 0x4988fe
mov al, byte [esi + 2]
xor ecx, ecx
cmp al, byte [edx]
jmp 0x49890a
mov al, byte [esi + 2]
cmp al, byte [edx]
je 0x498952
movzx edx, word [edx + 8]
movzx ecx, al
and edx, 0x3ff
mov eax, ecx
shr eax, 5
add edx, eax
and ecx, 0x8000001f
jns 0x498940
dec ecx
or ecx, 0xffffffe0
inc ecx
xor eax, eax
inc eax
shl eax, cl
test dword [edx*4 + 0x54c550], eax
je 0x498bf4
xor eax, eax
inc eax
cmp eax, ebx
je 0x49866b
add esi, 3
mov cl, byte [esi]
mov ebp, 0x80
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
test cl, cl
jne 0x498563
mov ebp, dword [esp + 0x18]
jmp 0x498538
movzx eax, byte [edx + 1]
xor ecx, ecx
inc ecx
mov eax, dword [eax*4 + 0x5683c8]
cmp eax, ecx
je 0x49899b
cmp eax, 3
jne 0x498bf4
mov eax, ecx
jmp 0x498955
cmp edi, 0x2003
ja 0x498a32
je case.0x4988cc.0
cmp edi, 0x85
ja 0x4989f6
je case.0x4988cc.0
mov eax, edi
sub eax, 9
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 0x13
jmp 0x498a91
mov eax, edi
sub eax, 0xa0
je case.0x4988cc.0
sub eax, 0x15e0
je case.0x4988cc.0
sub eax, 0x18e
je case.0x4988cc.0
sub eax, 0x7f2
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
jmp 0x498a91
cmp edi, 0x200a
ja 0x498a64
je case.0x4988cc.0
mov eax, edi
sub eax, 0x2004
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 1
jmp 0x498a1e
mov eax, edi
sub eax, 0x2028
je case.0x4988cc.0
sub eax, 1
je case.0x4988cc.0
sub eax, 6
je case.0x4988cc.0
sub eax, 0x30
je case.0x4988cc.0
sub eax, 0xfa1
je case.0x4988cc.0
movzx eax, byte [edx + 1]
xor ecx, ecx
cmp dword [eax*4 + 0x5683c8], 6
jmp 0x49890a
movzx eax, byte [edx + 1]
xor ecx, ecx
inc ecx
mov eax, dword [eax*4 + 0x5683c8]
cmp eax, ecx
je 0x49899b
cmp eax, 3
je 0x49899b
cmp edi, 0x5f
je 0x49899b
jmp 0x498bf4
cmp edi, 0xa0
jae 0x498af9
cmp edi, 0x24
je 0x498952
cmp edi, 0x40
je 0x498952
cmp edi, 0x60
jmp 0x498bee
lea eax, [edi - 0xd800]
mov ecx, 0x7ff
cmp ecx, eax
sbb eax, eax
neg eax
jmp 0x498955
mov ax, word [edx + 8]
xor ecx, ecx
shr ax, 0xb
cmp al, byte [esi + 2]
jmp 0x49890a
movzx ecx, byte [esi + 2]
movzx edx, word [edx + 0xa]
mov eax, ecx
and edx, 0xfff
shr eax, 5
add edx, eax
and ecx, 0x8000001f
jns 0x498b43
dec ecx
or ecx, 0xffffffe0
inc ecx
xor eax, eax
inc eax
shl eax, cl
mov ecx, dword [edx*4 + 0x54bcf8]
and ecx, eax
neg ecx
sbb ecx, ecx
neg ecx
jmp 0x4988fe
mov cl, byte [edx + 1]
movzx eax, cl
mov eax, dword [eax*4 + 0x5683c8]
cmp eax, 6
je 0x498bf4
test eax, eax
jne 0x498952
cmp cl, 1
jne 0x498bf4
cmp edi, 0x61c
je 0x498bf4
cmp edi, 0x180e
je 0x498bf4
cmp edi, 0x2066
jb 0x498952
cmp edi, 0x2069
jbe 0x498bf4
jmp 0x498952
mov cl, byte [edx + 1]
cmp cl, 0x1b
je 0x498bf4
cmp cl, 0x1c
je 0x498bf4
movzx eax, cl
cmp dword [eax*4 + 0x5683c8], 0
jne 0x498952
cmp cl, 1
jne 0x498bf4
cmp edi, 0x61c
jmp 0x498b8d
movzx eax, byte [edx + 1]
mov eax, dword [eax*4 + 0x5683c8]
cmp eax, 4
je 0x498952
cmp edi, ebp
jae 0x498bf4
cmp eax, 5
je 0x498952
xor eax, eax
jmp 0x498955
xor eax, eax
jmp 0x49853a