Function at 0xffd9e08
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
xor edi, edi
cmp dword [ebp + 0x1c], edi
mov dword [ebp - 8], edi
mov dword [ebp - 0xc], edi
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x14], edi
je 0xffd9e2e
mov esi, 0x80090009
jmp 0xffda2f7
mov esi, dword [ebp + 8]
push edi
push esi
call fcn.0ffdf81e
test eax, eax
jne 0xffd9e46
mov esi, 0x80090001
jmp 0xffda2f7
mov ebx, dword [ebp + 0x18]
cmp ebx, edi
jne 0xffd9e54
push 0x57
jmp 0xffda063
lea eax, [ebp + 0x1c]
push eax
push 1
push esi
push dword [ebp + 0xc]
call fcn.0ffdf839
cmp eax, edi
je 0xffd9e7c
cmp eax, 0x80090020
jne 0xffd9f63
mov esi, 0x80090002
jmp 0xffda2f7
mov eax, dword [ebp + 0x10]
dec eax
je 0xffda2cf
dec eax
je 0xffd9f28
dec eax
dec eax
je 0xffd9e9b
mov esi, 0x8009000a
jmp 0xffda2f7
mov esi, dword [ebp + 0x14]
test esi, esi
push 4
pop edi
je 0xffda2eb
cmp dword [ebx], edi
jb 0xffda2eb
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax + 4]
cmp ecx, 0x8001
jb 0xffd9f1e
cmp ecx, 0x8004
jbe 0xffd9f13
cmp ecx, 0x8005
je 0xffd9eef
cmp ecx, 0x8008
je 0xffd9ee4
cmp ecx, 0x8009
jne 0xffd9f1e
push dword [eax + 0x18]
jmp 0xffd9f14
mov dword [esi], 0x24
jmp 0xffda2e5
lea ecx, [ebp - 4]
push ecx
push 2
push dword [ebp + 8]
push dword [eax + 0x10]
call fcn.0ffdf839
test eax, eax
jne 0xffda1a7
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x78]
jmp 0xffda2e3
push ecx
call fcn.0ffd9de6
jmp 0xffda2e3
mov esi, 0x80090008
jmp 0xffda2f7
mov eax, dword [ebp + 0x1c]
mov edx, dword [eax + 4]
mov ecx, edx
sub ecx, 0x8005
je 0xffda191
sub ecx, 3
je 0xffda151
dec ecx
je 0xffd9f71
dec ecx
push ebx
push dword [ebp + 0x14]
push dword [eax + 0xc]
je 0xffd9f6a
push dword [eax + 0x14]
push edx
call fcn.0ffd9cac
cmp eax, edi
je 0xffda2e7
mov esi, eax
jmp 0xffda2f7
call fcn.0ffe1ebe
jmp 0xffd9f5b
test byte [eax + 0x1c], 2
jne 0xffda138
lea ecx, [ebp + 8]
push ecx
lea ecx, [ebp - 0x2c]
push ecx
push dword [eax + 0xc]
mov dword [ebp + 8], 0x14
push dword [eax + 0x14]
push dword [eax + 0x18]
call fcn.0ffd9cac
cmp eax, edi
jne 0xffd9f63
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp + 0x1c]
push 2
push esi
push dword [eax + 0x10]
call fcn.0ffdf839
cmp eax, edi
jne 0xffda1a7
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
push 0x40
pop edi
cmp eax, edi
jbe 0xffda042
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp + 0x1c]
push dword [eax + 0x18]
call fcn.0ffd6c58
test eax, eax
jne 0xffd9f63
mov eax, dword [ebp - 4]
push dword [eax + 0xc]
push dword [eax + 0x10]
mov eax, dword [ebp + 0x1c]
push dword [ebp - 0x10]
push dword [eax + 0x18]
call fcn.0ffd6fcf
test eax, eax
jne 0xffd9f63
push edi
call fcn.0ffe82b0
test eax, eax
mov dword [ebp - 8], eax
je 0xffda061
lea ecx, [ebp + 0x18]
push ecx
push eax
push dword [ebp - 0x10]
mov eax, dword [ebp + 0x1c]
push 0
push dword [eax + 0x18]
mov dword [ebp + 0x18], edi
call fcn.0ffd9cac
test eax, eax
jne 0xffd9f63
xor ecx, ecx
mov edx, dword [ebp + 0x1c]
mov edx, dword [edx + 0x28]
mov eax, dword [ebp - 8]
mov dl, byte [edx + ecx]
add eax, ecx
xor byte [eax], dl
inc ecx
cmp ecx, edi
jb 0xffda028
mov dword [ebp + 0x18], edi
jmp 0xffda0a3
mov ecx, dword [ebp + 0x1c]
mov ecx, dword [ecx + 0x2c]
cmp eax, ecx
mov dword [ebp + 0x18], ecx
jb 0xffda052
mov dword [ebp + 0x18], eax
push dword [ebp + 0x18]
call fcn.0ffe82b0
test eax, eax
mov dword [ebp - 8], eax
jne 0xffda069
push 8
pop esi
jmp 0xffda2f7
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax + 0x2c]
mov esi, dword [eax + 0x28]
mov edi, dword [ebp - 8]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp - 4]
xor eax, eax
cmp dword [ecx + 0xc], eax
jbe 0xffda0a3
mov ecx, dword [ecx + 0x10]
mov edx, dword [ebp - 8]
mov cl, byte [ecx + eax]
add edx, eax
xor byte [edx], cl
mov ecx, dword [ebp - 4]
inc eax
cmp eax, dword [ecx + 0xc]
jb 0xffda08d
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0xc]
push eax
mov eax, dword [ebp + 0x1c]
push dword [eax + 0x18]
call fcn.0ffd6c58
test eax, eax
jne 0xffd9f63
push dword [ebp + 0x18]
mov eax, dword [ebp + 0x1c]
push dword [ebp - 8]
push dword [ebp - 0xc]
push dword [eax + 0x18]
call fcn.0ffd6fcf
test eax, eax
jne 0xffd9f63
push dword [ebp + 8]
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0xc]
mov eax, dword [ebp + 0x1c]
push dword [eax + 0x18]
call fcn.0ffd6fcf
test eax, eax
jne 0xffd9f63
mov eax, dword [ebp + 0x1c]
push dword [eax + 0xc]
call fcn.0ffe82e0
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp - 0x18]
mov dword [eax + 8], ecx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp + 0x1c]
mov dword [ecx + 0xc], eax
mov eax, dword [ebp + 0x1c]
and dword [ebp - 0xc], 0
or dword [eax + 0x1c], 2
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call fcn.0ffde663
push dword [ebp + 0x18]
push dword [ebp - 8]
call fcn.0ffde663
mov eax, dword [ebp + 0x1c]
push ebx
push dword [ebp + 0x14]
push dword [eax + 0xc]
push dword [eax + 0x14]
push dword [eax + 0x18]
call fcn.0ffd9cac
test eax, eax
jmp 0xffd9f5d
mov edi, dword [ebp + 0x14]
test edi, edi
push 0x24
pop ecx
je 0xffda17e
cmp dword [ebx], ecx
jb 0xffda17e
test byte [eax + 0x14], 1
jne 0xffda16f
mov esi, 0x8009000c
jmp 0xffda2f7
mov dword [ebx], ecx
mov esi, dword [eax + 0xc]
push 9
pop ecx
rep movsd dword es:[edi], dword [esi]
jmp 0xffda2e7
neg edi
sbb edi, edi
and edi, 0xea
mov dword [ebx], ecx
mov esi, edi
jmp 0xffda2f7
mov ebx, dword [eax + 0xc]
lea ecx, [ebp - 4]
push ecx
push 2
push esi
push dword [eax + 0x10]
call fcn.0ffdf839
test eax, eax
je 0xffda1bc
cmp eax, 0x80090020
jne 0xffd9f63
mov esi, 0x80090003
jmp 0xffda2f7
mov esi, dword [ebp + 0x14]
test esi, esi
mov eax, dword [ebp - 4]
je 0xffda2c5
mov ecx, dword [eax + 0x78]
mov edx, dword [ebp + 0x18]
cmp dword [edx], ecx
jb 0xffda2c5
xor edx, edx
inc edx
cmp dword [ebx + 0x24], edx
jne 0xffda201
mov edx, dword [ebp + 0x18]
mov edi, dword [ebp + 0x14]
mov dword [edx], ecx
mov ecx, dword [eax + 0x78]
lea esi, [eax + 0x2c]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0xffda2e7
cmp dword [ebx], 0
mov dword [ebx + 0x24], edx
je 0xffda2a8
push 8
xor eax, eax
pop edx
mov ecx, edx
lea edi, [ebp - 0x4c]
rep stosd dword es:[edi], eax
mov ecx, dword [ebx]
mov eax, ecx
shr ecx, 2
lea esi, [ebx + 0x14]
lea edi, [ebp - 0x4c]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [ebp - 4]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [eax + 4]
cmp ecx, 0x6601
je 0xffda2b3
cmp ecx, 0x6602
je 0xffda28b
cmp ecx, 0x6603
je 0xffda279
cmp ecx, 0x6609
je 0xffda279
cmp ecx, 0x660d
jbe 0xffda2ab
cmp ecx, 0x6610
ja 0xffda2ab
push 0x20
push ebx
lea ecx, [ebp - 0x4c]
push ecx
push 1
push dword [eax + 0x78]
push eax
push fcn.0ffe52a0
jmp 0xffda29b
push 0x20
push ebx
lea ecx, [ebp - 0x4c]
push ecx
push 1
push edx
push eax
push fcn.0ffe47e0
jmp 0xffda29b
push 0x20
push ebx
lea ecx, [ebp - 0x4c]
push ecx
push 1
push edx
push eax
push fcn.0ffe3a00
call fcn.0ffd6040
test eax, eax
jne 0xffd9f63
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x78]
jmp 0xffda1e0
push 0x20
push ebx
lea ecx, [ebp - 0x4c]
push ecx
push 1
push edx
push eax
push fcn.0ffe2960
jmp 0xffda29b
mov eax, dword [eax + 0x78]
mov ecx, dword [ebp + 0x18]
mov dword [ecx], eax
jmp 0xffda2ed
mov esi, dword [ebp + 0x14]
test esi, esi
push 4
pop edi
je 0xffda2eb
cmp dword [ebx], edi
jb 0xffda2eb
mov eax, dword [ebp + 0x1c]
mov eax, dword [eax + 4]
mov dword [esi], eax
mov dword [ebx], edi
xor esi, esi
jmp 0xffda2f7
mov dword [ebx], edi
neg esi
sbb esi, esi
and esi, 0xea
xor eax, eax
test esi, esi
sete al
xor ebx, ebx
cmp dword [ebp - 8], ebx
mov edi, eax
je 0xffda30f
push dword [ebp - 8]
call fcn.0ffe82e0
cmp dword [ebp - 0xc], ebx
je 0xffda31c
push dword [ebp - 0xc]
call fcn.0ffe82e0
cmp dword [ebp - 0x10], ebx
je 0xffda329
push dword [ebp - 0x10]
call fcn.0ffe82e0
cmp edi, ebx
jne 0xffda334
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 0x18