Function at 0x409060
Capabilities:
Access peb ldr_data
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42dba6
mov eax, dword fs:[0]
push eax
sub esp, 0x854
mov eax, dword [0x43b698]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov esi, ecx
mov ecx, dword [esi + 0xc]
mov dword [ebp - 0x854], eax
lea eax, [ebp - 0x814]
mov byte [ebp - 0x814], 0x43
mov edx, dword [ecx]
mov edx, dword [edx + 0x30]
push eax
push 1
call edx
mov eax, dword [ebp - 0x814]
push eax
xor edi, edi
push edi
mov ecx, esi
call fcn.004087e0
mov ecx, dword [esi + 0xc]
lea eax, [ebp - 0x814]
mov byte [ebp - 0x814], 0xbc
mov edx, dword [ecx]
mov edx, dword [edx + 0x30]
push eax
push 1
call edx
mov eax, dword [ebp - 0x814]
push eax
push edi
mov ecx, esi
call fcn.004087e0
push 0x400
lea ecx, [ebp - 0x413]
push edi
push ecx
mov byte [ebp - 0x414], 0
call fcn.0042ccee
mov ecx, dword [esi + 0xc]
mov edx, dword [ecx]
mov edx, dword [edx + 0x38]
add esp, 0xc
lea eax, [ebp - 0x414]
push eax
push 1
call edx
mov eax, dword [ebp - 0x414]
push eax
push 1
mov ecx, esi
call fcn.004087e0
mov al, byte [ebp - 0x414]
cmp al, 0x1f
je 0x409437
cmp al, 0x79
jne 0x409437
mov bl, byte [ebp + 8]
test bl, bl
jne 0x409217
push edi
push 0x43168c
lea ecx, [ebp - 0x84c]
mov dword [ebp - 0x838], 0xf
mov dword [ebp - 0x83c], edi
mov byte [ebp - 0x84c], bl
call fcn.00402700
push 0xffffffffffffffff
lea ecx, [ebp - 0x84c]
mov dword [ebp - 4], edi
call fcn.004026b0
mov ecx, dword [esi + 0xc]
mov edx, dword [ecx]
mov edx, dword [edx + 0x2c]
lea eax, [ebp - 0x84c]
push eax
call edx
push edi
lea ecx, [ebp - 0x84c]
call fcn.004026b0
mov ecx, dword [esi + 0xc]
mov eax, dword [ecx]
mov eax, dword [eax + 0x2c]
lea edx, [ebp - 0x84c]
push edx
call eax
push 0xff
push edi
mov ecx, esi
call fcn.004087e0
push edi
push edi
mov ecx, esi
call fcn.004087e0
mov ecx, dword [esi + 0xc]
lea eax, [ebp - 0x414]
mov byte [ebp - 0x414], 0xff
mov edx, dword [ecx]
mov edx, dword [edx + 0x38]
push eax
push 1
call edx
mov eax, dword [ebp - 0x414]
push eax
push 1
mov ecx, esi
call fcn.004087e0
cmp byte [ebp - 0x414], 0x79
lea ecx, [ebp - 0x84c]
jne 0x40920d
call fcn.00402590
xor al, al
jmp 0x409439
call fcn.00402590
jmp 0x409437
mov dword [ebp - 0x81c], 0xf
mov dword [ebp - 0x820], edi
mov byte [ebp - 0x830], 0
movzx eax, bl
dec al
lea ecx, [ebp - 0x830]
mov dword [ebp - 4], 1
mov byte [ebp - 0x85c], al
push eax
call fcn.004026b0
mov ecx, dword [esi + 0xc]
mov edx, dword [ecx]
mov edx, dword [edx + 0x2c]
lea eax, [ebp - 0x830]
push eax
call edx
movzx eax, bl
dec al
mov ecx, esi
mov byte [ebp - 0x858], al
push eax
push edi
call fcn.004087e0
movzx edi, bl
mov dword [ebp - 0x860], edi
test edi, edi
jle 0x409328
mov eax, dword [ebp - 0x854]
lea ebx, [eax + edi*2 - 2]
lea esp, [esp]
cmp dword [ebp - 0x81c], 1
mov cl, byte [ebx]
mov byte [ebp - 0x850], cl
jae 0x4092b5
mov edx, dword [ebp - 0x820]
push edx
push 1
lea ecx, [ebp - 0x830]
call fcn.00402420
mov eax, dword [ebp - 0x830]
mov ecx, 0x10
cmp dword [ebp - 0x81c], ecx
jae 0x4092ce
lea eax, [ebp - 0x830]
mov dl, byte [ebp - 0x850]
mov byte [eax], dl
mov eax, dword [ebp - 0x830]
mov dword [ebp - 0x820], 1
cmp dword [ebp - 0x81c], ecx
jae 0x4092f4
lea eax, [ebp - 0x830]
mov byte [eax + 1], 0
mov ecx, dword [esi + 0xc]
mov eax, dword [ecx]
mov eax, dword [eax + 0x2c]
lea edx, [ebp - 0x830]
push edx
call eax
movzx ecx, byte [ebx]
push ecx
push 0
mov ecx, esi
call fcn.004087e0
dec edi
sub ebx, 2
test edi, edi
jg 0x409290
mov edi, dword [ebp - 0x860]
mov edx, dword [ebp - 0x854]
mov bl, byte [edx]
mov eax, 1
cmp edi, eax
jle 0x40934a
lea esp, [esp]
mov ecx, edx
xor bl, byte [ecx + eax*2]
inc eax
cmp eax, edi
jl 0x409340
cmp dword [ebp - 0x81c], 1
jae 0x409367
mov edx, dword [ebp - 0x820]
push edx
push 1
lea ecx, [ebp - 0x830]
call fcn.00402420
mov al, byte [ebp - 0x85c]
mov ecx, dword [ebp - 0x830]
mov edi, 0x10
xor al, bl
cmp dword [ebp - 0x81c], edi
jae 0x409388
lea ecx, [ebp - 0x830]
mov byte [ecx], al
mov eax, dword [ebp - 0x830]
mov dword [ebp - 0x820], 1
cmp dword [ebp - 0x81c], edi
jae 0x4093a8
lea eax, [ebp - 0x830]
mov byte [eax + 1], 0
mov ecx, dword [esi + 0xc]
mov eax, dword [ecx]
mov eax, dword [eax + 0x2c]
lea edx, [ebp - 0x830]
push edx
call eax
mov al, byte [ebp - 0x858]
xor al, bl
movzx ecx, al
push ecx
push 0
mov ecx, esi
call fcn.004087e0
mov ecx, dword [esi + 0xc]
lea eax, [ebp - 0x414]
mov byte [ebp - 0x414], 0xff
mov edx, dword [ecx]
mov edx, dword [edx + 0x38]
push eax
push 1
call edx
mov eax, dword [ebp - 0x414]
push eax
push 1
mov ecx, esi
call fcn.004087e0
cmp byte [ebp - 0x414], 0x79
jne 0x409420
cmp dword [ebp - 0x81c], edi
jb 0x40941c
mov ecx, dword [ebp - 0x830]
push ecx
call fcn.0042cccc
add esp, 4
xor al, al
jmp 0x409439
cmp dword [ebp - 0x81c], edi
jb 0x409437
mov edx, dword [ebp - 0x830]
push edx
call fcn.0042cccc
add esp, 4
mov al, 0x14
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0042ccde
mov esp, ebp
pop ebp
ret 8