Function at 0x42f3b4
Capabilities:
Encode data using xor
Encrypt data using twofish

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x258
mov eax, dword [0x46af24]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
xor esi, esi
xor edi, edi
mov dword [ebp - 0x250], ebx
cmp dword [0x46a628], esi
je 0x42f3e4
call fcn.0042ef61
mov eax, dword [ebx + 0x50]
and dword [ebp - 0x23c], esi
lea eax, [eax + eax + 8]
mov dword [ebp - 0x258], eax
mov eax, dword [ebx + 4]
mov dword [ebp - 0x254], eax
add eax, 0x3f
cdq
and edx, 0x3f
add eax, edx
sar eax, 6
mov dword [ebp - 0x244], eax
test eax, eax
jle 0x42f49b
lea ecx, [ebp + eax*4 - 0x21c]
lea eax, [ebx + eax*4 + 0x70]
mov dword [ebp - 0x248], eax
lea eax, [ebx + 0x58]
mov dword [ebp - 0x24c], ecx
mov dword [ebp - 0x240], eax
mov edx, dword [ebp - 0x240]
mov ecx, dword [edx - 4]
mov edx, dword [edx]
mov eax, dword [ebp - 0x23c]
push edx
push ecx
mov dword [ebp + eax*4 - 0x228], ecx
mov dword [ebp + eax*4 - 0x238], edx
call fcn.0042eee3
inc dword [ebp - 0x23c]
add dword [ebp - 0x240], 8
pop ecx
pop ecx
mov ecx, dword [ebp - 0x248]
sub dword [ebp - 0x248], 4
mov dword [ecx], eax
mov ecx, dword [ebp - 0x24c]
sub dword [ebp - 0x24c], 4
mov dword [ecx], eax
mov eax, dword [ebp - 0x23c]
cmp eax, dword [ebp - 0x244]
jl 0x42f43a
mov eax, dword [ebp - 0x258]
and dword [ebp - 0x240], esi
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x42f83a
mov ecx, dword [ebp - 0x244]
and ecx, 3
mov dword [ebp - 0x244], ecx
lea ecx, [ebx + 0x88]
mov dword [ebp - 0x24c], ecx
mov dword [ebp - 0x248], eax
mov eax, dword [ebp - 0x240]
mov dword [ebp - 0x23c], eax
mov eax, dword [ebp - 0x244]
sub eax, 0
je 0x42f555
dec eax
dec eax
je 0x42f5ac
dec eax
jne 0x42f66a
mov al, byte [ebp - 0x239]
mov cl, byte [ebp - 0x23a]
mov dl, byte [ebp - 0x23c]
movzx edx, dl
mov dl, byte [edx + 0x46a528]
xor dl, byte [ebp - 0x220]
movzx ecx, cl
mov cl, byte [ecx + 0x46a428]
xor cl, byte [ebp - 0x21e]
mov byte [ebp - 0x23c], dl
movzx edx, byte [ebp - 0x23b]
mov dl, byte [edx + 0x46a528]
xor dl, byte [ebp - 0x21f]
movzx eax, al
mov al, byte [eax + 0x46a428]
xor al, byte [ebp - 0x21d]
jmp 0x42f5be
movzx eax, byte [ebp - 0x240]
mov dl, byte [eax + 0x46a528]
movzx eax, byte [ebp - 0x23b]
mov al, byte [eax + 0x46a428]
xor al, byte [ebp - 0x21b]
xor dl, byte [ebp - 0x21c]
mov byte [ebp - 0x23b], al
movzx eax, byte [ebp - 0x23a]
mov cl, byte [eax + 0x46a428]
movzx eax, byte [ebp - 0x239]
mov al, byte [eax + 0x46a528]
xor cl, byte [ebp - 0x21a]
xor al, byte [ebp - 0x219]
jmp 0x42f50d
mov al, byte [ebp - 0x239]
mov cl, byte [ebp - 0x23a]
mov dl, byte [ebp - 0x23b]
movzx edi, byte [ebp - 0x221]
movzx eax, al
movzx eax, byte [eax + 0x46a528]
xor eax, edi
movzx eax, byte [eax + 0x46a528]
movzx edi, byte [ebp - 0x225]
xor eax, edi
movzx edi, byte [ebp - 0x222]
movzx ecx, cl
movzx ecx, byte [ecx + 0x46a428]
xor ecx, edi
movzx ecx, byte [ecx + 0x46a528]
movzx edi, byte [ebp - 0x226]
xor ecx, edi
mov edi, dword [eax*4 + 0x46eca0]
xor edi, dword [ecx*4 + 0x46e8a0]
movzx ecx, byte [ebp - 0x223]
movzx eax, dl
movzx eax, byte [eax + 0x46a528]
xor eax, ecx
movzx eax, byte [eax + 0x46a428]
movzx ecx, byte [ebp - 0x227]
xor eax, ecx
xor edi, dword [eax*4 + 0x46e4a0]
movzx eax, byte [ebp - 0x23c]
movzx eax, byte [eax + 0x46a428]
movzx ecx, byte [ebp - 0x224]
xor eax, ecx
movzx eax, byte [eax + 0x46a428]
movzx ecx, byte [ebp - 0x228]
xor eax, ecx
xor edi, dword [eax*4 + 0x46e0a0]
mov eax, dword [ebp - 0x240]
add eax, 0x1010101
mov dword [ebp - 0x23c], eax
mov eax, dword [ebp - 0x244]
sub eax, 0
je 0x42f6eb
dec eax
dec eax
je 0x42f73c
dec eax
jne 0x42f802
mov al, byte [ebp - 0x239]
mov cl, byte [ebp - 0x23a]
mov dl, byte [ebp - 0x23b]
mov bl, byte [ebp - 0x23c]
movzx esi, bl
mov bl, byte [esi + 0x46a528]
xor bl, byte [ebp - 0x230]
movzx edx, dl
mov dl, byte [edx + 0x46a528]
xor dl, byte [ebp - 0x22f]
movzx ecx, cl
mov cl, byte [ecx + 0x46a428]
xor cl, byte [ebp - 0x22e]
movzx eax, al
mov al, byte [eax + 0x46a428]
xor al, byte [ebp - 0x22d]
jmp 0x42f754
movzx eax, byte [ebp - 0x23c]
mov bl, byte [eax + 0x46a528]
movzx eax, byte [ebp - 0x23b]
mov dl, byte [eax + 0x46a428]
movzx eax, byte [ebp - 0x23a]
mov cl, byte [eax + 0x46a428]
movzx eax, byte [ebp - 0x239]
mov al, byte [eax + 0x46a528]
xor bl, byte [ebp - 0x22c]
xor dl, byte [ebp - 0x22b]
xor cl, byte [ebp - 0x22a]
xor al, byte [ebp - 0x229]
jmp 0x42f6ad
mov al, byte [ebp - 0x239]
mov cl, byte [ebp - 0x23a]
mov dl, byte [ebp - 0x23b]
mov bl, byte [ebp - 0x23c]
movzx esi, byte [ebp - 0x231]
movzx eax, al
movzx eax, byte [eax + 0x46a528]
xor eax, esi
movzx eax, byte [eax + 0x46a528]
movzx esi, byte [ebp - 0x235]
xor eax, esi
movzx esi, byte [ebp - 0x232]
movzx ecx, cl
movzx ecx, byte [ecx + 0x46a428]
xor ecx, esi
movzx ecx, byte [ecx + 0x46a528]
movzx esi, byte [ebp - 0x236]
xor ecx, esi
mov esi, dword [eax*4 + 0x46eca0]
xor esi, dword [ecx*4 + 0x46e8a0]
movzx ecx, byte [ebp - 0x233]
movzx eax, dl
movzx eax, byte [eax + 0x46a528]
xor eax, ecx
movzx eax, byte [eax + 0x46a428]
movzx ecx, byte [ebp - 0x237]
xor eax, ecx
xor esi, dword [eax*4 + 0x46e4a0]
movzx ecx, byte [ebp - 0x234]
movzx eax, bl
movzx eax, byte [eax + 0x46a428]
mov ebx, dword [ebp - 0x250]
xor eax, ecx
movzx eax, byte [eax + 0x46a428]
movzx ecx, byte [ebp - 0x238]
xor eax, ecx
xor esi, dword [eax*4 + 0x46e0a0]
mov eax, dword [ebp - 0x24c]
add dword [ebp - 0x240], 0x2020202
rol esi, 8
lea ecx, [esi + edi]
mov dword [eax - 4], ecx
lea esi, [edi + esi*2]
mov ecx, esi
rol ecx, 9
mov dword [eax], ecx
add eax, 8
dec dword [ebp - 0x248]
mov dword [ebp - 0x24c], eax
jne 0x42f4d5
mov eax, dword [ebp - 0x254]
sub eax, 0x80
je 0x42fe41
sub eax, 0x40
je 0x42fbe1
sub eax, 0x40
jne 0x430015
push dword [ebp - 0x20c]
lea eax, [ebp - 0x204]
push 0x46a528
push eax
call fcn.0042f0df
add esp, 0xc
xor eax, eax
mov esi, pe_nt_image_headers32
movzx ecx, byte [ebp + eax - 0x204]
mov cl, byte [ecx + 0x46a528]
mov byte [ebp + eax - 0x104], cl
movzx ecx, byte [ebp + eax - 0x203]
mov cl, byte [ecx + 0x46a528]
mov byte [ebp + eax - 0x103], cl
add eax, 2
cmp eax, esi
jl 0x42f87e
push dword [ebp - 0x210]
lea eax, [ebp - 0x104]
push eax
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x12c]
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x214]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x218]
xor edi, edx
mov edx, dword [edi*4 + 0x46e0a0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x214]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x218]
xor edi, edx
mov edx, dword [edi*4 + 0x46e0a0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42f8cd
push dword [ebp - 0x20b]
mov edi, 0x46a428
lea eax, [ebp - 0x204]
push edi
push eax
call fcn.0042f0df
add esp, 0xc
xor eax, eax
movzx ecx, byte [ebp + eax - 0x204]
mov cl, byte [ecx + 0x46a528]
mov byte [ebp + eax - 0x104], cl
movzx ecx, byte [ebp + eax - 0x203]
mov cl, byte [ecx + 0x46a528]
mov byte [ebp + eax - 0x103], cl
add eax, 2
cmp eax, esi
jl 0x42f957
push dword [ebp - 0x20f]
lea eax, [ebp - 0x104]
push eax
push eax
call fcn.0042f0df
add esp, 0xc
and dword [ebp - 0x23c], 0
lea eax, [ebx + 0x130]
mov ecx, dword [ebp - 0x23c]
movzx ecx, byte [ebp + ecx - 0x104]
movzx edx, byte [ecx + 0x46a528]
movzx ecx, byte [ebp - 0x213]
xor edx, ecx
movzx edx, byte [edx + 0x46a428]
movzx ecx, byte [ebp - 0x217]
xor edx, ecx
mov ecx, dword [edx*4 + 0x46e4a0]
mov dword [eax - 8], ecx
mov ecx, dword [ebp - 0x23c]
movzx ecx, byte [ebp + ecx - 0x103]
movzx edx, byte [ecx + 0x46a528]
movzx ecx, byte [ebp - 0x213]
add dword [ebp - 0x23c], 2
xor edx, ecx
movzx edx, byte [edx + 0x46a428]
movzx ecx, byte [ebp - 0x217]
xor edx, ecx
mov ecx, dword [edx*4 + 0x46e4a0]
mov dword [eax], ecx
add eax, 0x10
cmp dword [ebp - 0x23c], esi
jl 0x42f9ab
push dword [ebp - 0x20a]
lea eax, [ebp - 0x204]
push edi
push eax
call fcn.0042f0df
add esp, 0xc
xor eax, eax
movzx ecx, byte [ebp + eax - 0x204]
mov cl, byte [ecx + 0x46a428]
mov byte [ebp + eax - 0x104], cl
movzx ecx, byte [ebp + eax - 0x203]
mov cl, byte [ecx + 0x46a428]
mov byte [ebp + eax - 0x103], cl
add eax, 2
cmp eax, esi
jl 0x42fa48
push dword [ebp - 0x20e]
lea eax, [ebp - 0x104]
push eax
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x92c]
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x212]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x216]
xor edi, edx
mov edx, dword [edi*4 + 0x46e8a0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x212]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x216]
xor edi, edx
mov edx, dword [edi*4 + 0x46e8a0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42fa97
push dword [ebp - 0x209]
lea eax, [ebp - 0x204]
push 0x46a528
push eax
call fcn.0042f0df
add esp, 0xc
xor eax, eax
movzx ecx, byte [ebp + eax - 0x204]
mov cl, byte [ecx + 0x46a428]
mov byte [ebp + eax - 0x104], cl
movzx ecx, byte [ebp + eax - 0x203]
mov cl, byte [ecx + 0x46a428]
mov byte [ebp + eax - 0x103], cl
add eax, 2
cmp eax, esi
jl 0x42fb20
push dword [ebp - 0x20d]
lea eax, [ebp - 0x104]
push eax
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x930]
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x211]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x215]
xor edi, edx
mov edx, dword [edi*4 + 0x46eca0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x211]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x215]
xor edi, edx
mov edx, dword [edi*4 + 0x46eca0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42fb6f
jmp 0x430015
push dword [ebp - 0x210]
lea eax, [ebp - 0x104]
push 0x46a528
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x12c]
mov esi, pe_nt_image_headers32
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x214]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x218]
xor edi, edx
mov edx, dword [edi*4 + 0x46e0a0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a428]
movzx edx, byte [ebp - 0x214]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x218]
xor edi, edx
mov edx, dword [edi*4 + 0x46e0a0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42fc08
push dword [ebp - 0x20f]
lea eax, [ebp - 0x104]
push 0x46a528
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x130]
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x213]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x217]
xor edi, edx
mov edx, dword [edi*4 + 0x46e4a0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x213]
xor edi, edx
movzx edi, byte [edi + 0x46a428]
movzx edx, byte [ebp - 0x217]
xor edi, edx
mov edx, dword [edi*4 + 0x46e4a0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42fc97
push dword [ebp - 0x20e]
mov edi, 0x46a428
lea eax, [ebp - 0x104]
push edi
push eax
call fcn.0042f0df
add esp, 0xc
and dword [ebp - 0x23c], 0
lea eax, [ebx + 0x92c]
mov ecx, dword [ebp - 0x23c]
movzx ecx, byte [ebp + ecx - 0x104]
movzx edx, byte [ecx + 0x46a428]
movzx ecx, byte [ebp - 0x212]
xor edx, ecx
movzx edx, byte [edx + 0x46a528]
movzx ecx, byte [ebp - 0x216]
xor edx, ecx
mov ecx, dword [edx*4 + 0x46e8a0]
mov dword [eax - 8], ecx
mov ecx, dword [ebp - 0x23c]
movzx ecx, byte [ebp + ecx - 0x103]
movzx edx, byte [ecx + 0x46a428]
movzx ecx, byte [ebp - 0x212]
add dword [ebp - 0x23c], 2
xor edx, ecx
movzx edx, byte [edx + 0x46a528]
movzx ecx, byte [ebp - 0x216]
xor edx, ecx
mov ecx, dword [edx*4 + 0x46e8a0]
mov dword [eax], ecx
add eax, 0x10
cmp dword [ebp - 0x23c], esi
jl 0x42fd2c
push dword [ebp - 0x20d]
lea eax, [ebp - 0x104]
push edi
push eax
call fcn.0042f0df
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x930]
movzx edx, byte [ebp + ecx - 0x104]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x211]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x215]
xor edi, edx
mov edx, dword [edi*4 + 0x46eca0]
mov dword [eax - 8], edx
movzx edx, byte [ebp + ecx - 0x103]
movzx edi, byte [edx + 0x46a528]
movzx edx, byte [ebp - 0x211]
xor edi, edx
movzx edi, byte [edi + 0x46a528]
movzx edx, byte [ebp - 0x215]
xor edi, edx
mov edx, dword [edi*4 + 0x46eca0]
mov dword [eax], edx
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42fdcf
jmp 0x430015
push dword [ebp - 0x214]
mov edi, 0x46a428
lea eax, [ebp - 0x104]
push edi
push eax
call fcn.0042f0df
movzx ecx, byte [ebp - 0x218]
add esp, 0xc
and dword [ebp - 0x23c], 0
lea eax, [ebx + 0x12c]
mov esi, pe_nt_image_headers32
mov edx, dword [ebp - 0x23c]
movzx edx, byte [ebp + edx - 0x104]
movzx edx, byte [edx + 0x46a428]
xor edx, ecx
mov edx, dword [edx*4 + 0x46e0a0]
mov dword [eax - 8], edx
mov edx, dword [ebp - 0x23c]
movzx edx, byte [ebp + edx - 0x103]
movzx edx, byte [edx + 0x46a428]
add dword [ebp - 0x23c], 2
xor edx, ecx
mov edx, dword [edx*4 + 0x46e0a0]
mov dword [eax], edx
add eax, 0x10
cmp dword [ebp - 0x23c], esi
jl 0x42fe75
push dword [ebp - 0x213]
lea eax, [ebp - 0x104]
push 0x46a528
push eax
call fcn.0042f0df
movzx ecx, byte [ebp - 0x217]
add esp, 0xc
and dword [ebp - 0x23c], 0
lea eax, [ebx + 0x130]
mov edx, dword [ebp - 0x23c]
movzx edx, byte [ebp + edx - 0x104]
movzx edx, byte [edx + 0x46a428]
xor edx, ecx
mov edx, dword [edx*4 + 0x46e4a0]
mov dword [eax - 8], edx
mov edx, dword [ebp - 0x23c]
movzx edx, byte [ebp + edx - 0x103]
movzx edx, byte [edx + 0x46a428]
add dword [ebp - 0x23c], 2
xor edx, ecx
mov edx, dword [edx*4 + 0x46e4a0]
mov dword [eax], edx
add eax, 0x10
cmp dword [ebp - 0x23c], esi
jl 0x42fef6
push dword [ebp - 0x212]
lea eax, [ebp - 0x104]
push edi
push eax
call fcn.0042f0df
movzx edx, byte [ebp - 0x216]
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x92c]
movzx edi, byte [ebp + ecx - 0x104]
movzx edi, byte [edi + 0x46a528]
xor edi, edx
mov edi, dword [edi*4 + 0x46e8a0]
mov dword [eax - 8], edi
movzx edi, byte [ebp + ecx - 0x103]
movzx edi, byte [edi + 0x46a528]
xor edi, edx
mov edi, dword [edi*4 + 0x46e8a0]
mov dword [eax], edi
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42ff6e
push dword [ebp - 0x211]
lea eax, [ebp - 0x104]
push 0x46a528
push eax
call fcn.0042f0df
movzx edx, byte [ebp - 0x215]
add esp, 0xc
xor ecx, ecx
lea eax, [ebx + 0x930]
movzx edi, byte [ebp + ecx - 0x104]
movzx edi, byte [edi + 0x46a528]
xor edi, edx
mov edi, dword [edi*4 + 0x46eca0]
mov dword [eax - 8], edi
movzx edi, byte [ebp + ecx - 0x103]
movzx edi, byte [edi + 0x46a528]
xor edi, edx
mov edi, dword [edi*4 + 0x46eca0]
mov dword [eax], edi
add ecx, 2
add eax, 0x10
cmp ecx, esi
jl 0x42ffd6
cmp byte [ebx], 0
jne 0x430024
push 0
push ebx
call fcn.0042f09d
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
pop edi
xor eax, eax
pop esi
xor ecx, ebp
inc eax
pop ebx
call fcn.004534b8
leave
ret