Function at 0x45dee0
Capabilities:
Encode data using xor
Generate random numbers using the delphi lcg
Hash data with crc32
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov edx, dword [ebp + 0x14]
xor eax, eax
push ebx
xor ebx, ebx
mov dword [ebp - 4], eax
mov dword [ebp - 8], ebx
push esi
test edx, edx
je 0x45defb
mov byte [edx], al
mov esi, dword [ebp + 8]
test esi, esi
je 0x45e1a9
mov esi, dword [esi + 0x7c]
test esi, esi
je 0x45e1a9
cmp dword [esi], eax
jne 0x45df20
pop esi
mov eax, 0xffffff9c
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0x10]
test ecx, ecx
jne 0x45df2f
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
mov dword [esi + 0x10], eax
mov eax, dword [esi + 0x5c]
mov dword [esi + 0x14], ecx
cmp ecx, eax
jbe 0x45df44
mov dword [esi + 0x14], eax
mov ecx, eax
push edi
test ecx, ecx
je 0x45e1a0
lea ecx, [ecx]
mov ebx, dword [esi + 8]
test ebx, ebx
jne 0x45e054
mov eax, dword [esi + 0x58]
test eax, eax
je 0x45e054
mov edi, 0x4000
mov dword [ebp + 8], edi
cmp eax, edi
jae 0x45df77
mov edi, eax
mov dword [ebp + 8], eax
mov ecx, dword [esi + 0x60]
mov edx, dword [esi + 0x68]
add edx, dword [esi + 0x3c]
cmp byte [ecx], bl
je 0x45dfa2
cmp byte [ecx + 1], bl
je 0x45e180
mov eax, dword [ecx + 0xc]
push 0
push 0
add eax, edx
push eax
push dword [ecx + 4]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x45dfa5
mov dword [ecx + 0x1c], edx
push dword [esi + 0x60]
push 1
push edi
push dword [esi]
call fcn.0045d910
add esp, 0x10
cmp eax, 1
jne 0x45e180
add dword [esi + 0x3c], edi
mov ebx, edi
sub dword [esi + 0x58], edi
cmp byte [esi + 0x6c], 0
mov eax, dword [esi]
mov dword [ebp - 0xc], eax
mov dword [esi + 4], eax
mov dword [esi + 8], edi
je 0x45e054
xor ecx, ecx
mov dword [ebp - 0x10], ecx
test edi, edi
je 0x45e054
mov ebx, dword [ebp + 8]
mov edi, dword [esi + 0x78]
mov eax, edi
and eax, 0xfffd
or eax, 2
mov edx, eax
xor edx, 1
imul edx, eax
mov eax, dword [ebp - 0xc]
shr edx, 8
xor dl, byte [ecx + eax]
mov ecx, dword [esi + 0x70]
movsx eax, dl
xor eax, ecx
shr ecx, 8
movzx eax, al
mov eax, dword [eax*4 + 0x54e640]
xor eax, ecx
mov ecx, dword [ebp - 0x10]
mov dword [esi + 0x70], eax
movzx eax, al
add eax, dword [esi + 0x74]
imul eax, eax, 0x8088405
inc eax
mov dword [esi + 0x74], eax
shr eax, 0x18
xor eax, edi
shr edi, 8
movzx eax, al
xor edi, dword [eax*4 + 0x54e640]
mov eax, dword [ebp - 0xc]
mov dword [esi + 0x78], edi
mov byte [ecx + eax], dl
inc ecx
mov dword [ebp - 0x10], ecx
cmp ecx, ebx
jb 0x45dfe3
mov ebx, dword [esi + 8]
mov ecx, dword [esi + 0x7c]
cmp ecx, ebx
jbe 0x45e05d
mov ecx, ebx
test ecx, ecx
je 0x45e08a
mov eax, dword [esi + 4]
sub ebx, ecx
add eax, ecx
mov dl, byte [eax - 1]
sub dword [esi + 0x5c], ecx
sub dword [esi + 0x7c], ecx
mov byte [ebp + 0xb], dl
mov dword [esi + 8], ebx
mov dword [esi + 4], eax
jne 0x45e08a
mov al, dl
cmp al, byte [esi + 0x80]
jne 0x45e18a
cmp dword [esi + 0x64], 0
jne 0x45e11b
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x10], eax
cmp eax, ebx
jae 0x45e0a5
mov edi, eax
mov dword [ebp + 8], edi
jmp 0x45e0aa
mov edi, ebx
mov dword [ebp + 8], ebx
xor edx, edx
test edi, edi
je 0x45e0ca
mov eax, dword [esi + 4]
mov ecx, dword [esi + 0x10]
mov al, byte [edx + eax]
mov byte [edx + ecx], al
inc edx
cmp edx, edi
jb 0x45e0b0
mov eax, dword [esi + 0x14]
mov ebx, dword [esi + 8]
mov dword [ebp - 0x10], eax
push dword [ebp + 8]
mov edi, dword [esi + 0x10]
push edi
push dword [esi + 0x50]
call fcn.0045d980
mov ecx, dword [ebp + 8]
add esp, 0xc
sub dword [esi + 0x5c], ecx
sub ebx, ecx
add dword [esi + 4], ecx
add dword [esi + 0x18], ecx
mov dword [esi + 0x50], eax
mov eax, dword [ebp - 0x10]
sub eax, ecx
mov dword [esi + 8], ebx
mov ebx, dword [ebp - 8]
mov dword [esi + 0x14], eax
add ebx, ecx
cmp dword [esi + 0x5c], 0
lea eax, [edi + ecx]
mov edi, dword [ebp - 4]
mov dword [esi + 0x10], eax
mov dword [ebp - 8], ebx
jne 0x45e169
mov edx, dword [ebp + 0x14]
test edx, edx
je 0x45e169
mov byte [edx], 1
jmp 0x45e169
mov edi, dword [esi + 0x18]
lea eax, [esi + 4]
mov ebx, dword [esi + 0x10]
push 2
push eax
call fcn.0045bb20
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x18]
sub eax, edi
push eax
push ebx
push dword [esi + 0x50]
mov dword [ebp + 8], eax
call fcn.0045d980
mov ecx, dword [esi + 0x5c]
add esp, 0x14
mov ebx, dword [ebp - 8]
sub ecx, dword [ebp + 8]
add ebx, dword [ebp + 8]
mov edi, dword [ebp - 4]
mov dword [esi + 0x50], eax
mov dword [esi + 0x5c], ecx
mov dword [ebp - 8], ebx
cmp edi, 1
je 0x45e196
test ecx, ecx
je 0x45e196
test edi, edi
jne 0x45e177
cmp dword [esi + 0x14], 0
ja 0x45df50
test edi, edi
je 0x45e1a0
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
mov eax, 0xffffff96
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0x14]
test ecx, ecx
je 0x45e1a0
mov byte [ecx], 1
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret
pop esi
mov eax, 0xffffff9a
pop ebx
mov esp, ebp
pop ebp
ret