Function at 0x42f540
Capabilities:
Encrypt data using speck
Resolve function by parsing pe exports

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x20
mov dword [esp + 8], ecx
mov esi, dword [esp + 0x38]
mov eax, dword [esi + 0x274]
cmp eax, 4
ja case.default.0x42f563
mov ebx, edx
lea ecx, [esi + 8]
mov dword [esp + 4], ecx
jmp dword [eax*4 + 0x869514]
mov ecx, esi
mov edx, dword [esp + 4]
push ebx
call fcn.0042e4a0
add esp, 4
mov ebp, eax
cmp eax, 1
jne 0x42f958
inc dword [ebx]
mov dword [esi + 0x974], 0
push dword [esp + 8]
push dword [esi + 0x20]
call dword [esi + 0x18]
add esp, 8
mov ecx, dword [esp + 0x34]
mov dword [ecx], eax
test eax, eax
je 0x42f5e5
cmp dword [ebx], 1
ja 0x42f5ef
push dword [esp + 8]
push 0
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
add esp, 0xc
mov ebp, 1
jmp 0x42f958
mov ebp, 0xffffffe1
jmp 0x42f958
mov edx, dword [esi + 0x978]
jmp 0x42f662
mov ebx, dword [esi + 0x97c]
jmp 0x42f69c
mov ebp, 0xffffffe7
jmp 0x42f958
mov dword [esi + 0x274], 1
mov ecx, dword [esi + 0xc]
lea eax, [ecx - 0x1c]
cmp eax, 5
jae 0x42f634
mov eax, dword [esi + 0x14]
test eax, eax
je 0x42f962
mov ebp, dword [esi + 8]
mov edi, dword [esi + 0x10]
mov edx, ebp
shr edx, 8
mov dword [esi + 8], edx
movzx edx, byte [edi]
shld edx, ebp, 0x18
mov dword [esi + 8], edx
add ecx, 0xfffffff8
dec eax
mov dword [esi + 0x14], eax
inc edi
mov dword [esi + 0x10], edi
jmp 0x42f63a
mov eax, dword [esp + 4]
mov edx, dword [eax]
shr edx, cl
mov eax, edx
and eax, 1
lea ecx, [ecx + eax*4]
inc ecx
neg eax
shr edx, 1
and edx, 0xf
inc edx
and edx, eax
mov dword [esi + 0x978], edx
mov dword [esi + 0xc], ecx
mov dword [esi + 0x274], 2
add edx, dword [ebx]
lea eax, [esi + 0x980]
mov ecx, edx
push esi
push 0
push eax
call fcn.0042e650
add esp, 0xc
mov ebp, eax
cmp eax, 1
jne 0x42f958
mov dword [esi + 0x97c], 0xffff
mov dword [esi + 0x274], 3
mov ebx, 0xffff
mov ecx, dword [esi + 0x974]
mov eax, dword [esi + 0x978]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x34]
mov eax, dword [eax]
mov dword [esp + 0xc], eax
mov dword [esp + 0x14], ebx
cmp ebx, 0xffff
setne al
mov dword [esp], ecx
cmp ecx, dword [esp + 8]
jb 0x42f742
cmp ebx, 0xffff
jne 0x42f742
mov ecx, dword [esi + 0xc]
cmp ecx, 0x20
jne 0x42f70e
mov ecx, dword [esi + 0x14]
test ecx, ecx
je 0x42f948
mov edx, dword [esi + 8]
mov edi, dword [esi + 0x10]
mov eax, edx
shr eax, 8
mov dword [esi + 8], eax
movzx eax, byte [edi]
shld eax, edx, 0x18
mov dword [esi + 8], eax
dec ecx
mov dword [esi + 0x14], ecx
inc edi
mov dword [esi + 0x10], edi
mov ecx, 0x18
jmp 0x42f714
mov eax, dword [esp + 4]
mov eax, dword [eax]
lea edx, [ecx + 1]
mov dword [esi + 0xc], edx
mov ebp, 1
xor edi, edi
bt eax, ecx
jae 0x42f952
mov eax, dword [esp + 0x34]
mov ecx, dword [eax]
mov edx, dword [esp + 8]
push esi
call fcn.004313d0
add esp, 4
jmp 0x42f952
lea ebp, [esi + 0x980]
mov dword [esp + 0x18], ebp
jmp 0x42f76b
mov eax, dword [esp + 0xc]
mov edi, dword [esp]
mov byte [eax + edi], 0
inc edi
xor ebx, ebx
xor eax, eax
mov dword [esp], edi
cmp edi, dword [esp + 8]
jae case.0x42f563.4
test al, 1
jne 0x42f870
mov ecx, dword [esi + 0xc]
lea eax, [ecx - 0x12]
cmp eax, 0xf
jae 0x42f7cb
mov edx, dword [esi + 0x14]
dec edx
mov edi, ecx
nop word cs:[eax + eax]
cmp edx, 0xffffffff
je 0x42f829
mov ecx, dword [esi + 8]
mov ebx, dword [esi + 0x10]
mov eax, ecx
shr eax, 8
mov dword [esi + 8], eax
movzx eax, byte [ebx]
shld eax, ecx, 0x18
mov dword [esi + 8], eax
lea ecx, [edi - 8]
mov dword [esi + 0xc], ecx
mov dword [esi + 0x14], edx
inc ebx
mov dword [esi + 0x10], ebx
dec edx
add edi, 0xffffffe6
cmp edi, 0xf
mov edi, ecx
jb 0x42f790
jmp 0x42f7d1
mov eax, dword [esp + 4]
mov eax, dword [eax]
shr eax, cl
movzx edi, al
lea edx, [edi*4]
add edx, ebp
movzx ebx, byte [ebp + edi*4]
cmp ebx, 9
jb 0x42f810
add ecx, 8
movzx edi, word [ebp + edi*4 + 2]
mov dword [esp + 0x10], edi
shr eax, 8
mov edi, dword [0x86ae18]
and eax, dword [edi + ebx*4 - 0x20]
and eax, 0x7f
add eax, dword [esp + 0x10]
movzx ebx, byte [edx + eax*4]
lea edx, [edx + eax*4]
movzx eax, bl
add eax, ecx
mov dword [esi + 0xc], eax
movzx ebx, word [edx + 2]
mov dword [esp + 0x14], ebx
test ebx, ebx
jne 0x42f850
jmp 0x42f74e
mov ecx, ebp
mov edx, dword [esp + 4]
lea eax, [esp + 0x14]
push eax
call fcn.00431320
add esp, 4
test eax, eax
je 0x42f970
mov ebx, dword [esp + 0x14]
test ebx, ebx
je 0x42f74e
mov eax, ebx
sub eax, dword [esp + 0x1c]
jbe 0x42f870
mov ecx, dword [esp + 0xc]
mov edi, dword [esp]
mov byte [ecx + edi], al
inc edi
jmp 0x42f75c
mov eax, dword [esi + 0xc]
mov ecx, 0x20
mov edx, esi
mov esi, eax
sub ecx, eax
cmp ecx, ebx
jae 0x42f8e0
mov edi, dword [edx + 0x14]
dec edi
mov dword [esp + 0x10], ebx
nop word [eax + eax]
cmp edi, 0xffffffff
je 0x42f92e
mov eax, dword [esp + 0x38]
mov ebp, dword [eax + 8]
mov ebx, dword [eax + 0x10]
mov edx, ebp
shr edx, 8
mov dword [eax + 8], edx
movzx edx, byte [ebx]
shld edx, ebp, 0x18
mov dword [eax + 8], edx
mov ebp, esi
add ebp, 0xfffffff8
mov esi, ebp
mov dword [eax + 0xc], ebp
mov dword [eax + 0x14], edi
inc ebx
mov dword [eax + 0x10], ebx
mov ebx, dword [esp + 0x10]
dec edi
add ecx, 8
cmp ecx, ebx
jb 0x42f890
jmp 0x42f8e6
mov ecx, dword [esp + 4]
mov edx, dword [ecx]
mov eax, esi
mov ecx, eax
shr edx, cl
mov ecx, dword [0x86ae18]
and edx, dword [ecx + ebx*4]
add eax, ebx
mov ebp, 1
mov ecx, ebx
shl ebp, cl
mov esi, dword [esp + 0x38]
mov dword [esi + 0xc], eax
add ebp, edx
mov eax, dword [esp]
lea edi, [eax + ebp]
cmp edi, dword [esp + 8]
ja 0x42f969
add eax, dword [esp + 0xc]
push ebp
push 0
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
add esp, 0xc
mov ebp, dword [esp + 0x18]
jmp 0x42f75c
mov eax, dword [esp]
mov esi, dword [esp + 0x38]
mov dword [esi + 0x97c], ebx
mov dword [esi + 0x974], eax
mov ebp, 2
jmp 0x42f958
mov ebp, 2
mov edi, 4
mov dword [esi + 0x274], edi
mov eax, ebp
add esp, 0x20
pop esi
pop edi
pop ebx
pop ebp
ret
mov ebp, 2
jmp 0x42f958
mov ebp, 0xfffffff8
jmp 0x42f958
mov ebx, 0xffff
mov eax, dword [esp]
jmp 0x42f935