Function at 0x40cf80
Capabilities:
Check for peb beingdebugged flag
Encode data using xor

Disassembly:
push 0xffffffffffffffff
push 0x43eed1
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x220
push ebx
push ebp
push esi
push edi
mov edi, ecx
lea ecx, [esp + 0x28]
call sub.MFC42.DLL_CString::CString_3
xor esi, esi
lea ecx, [esp + 0x14]
mov dword [esp + 0x238], esi
call sub.MFC42.DLL_CString::CString_3
lea ecx, [esp + 0x2c]
mov byte [esp + 0x238], 1
call sub.MFC42.DLL_CString::CString_3
lea ebp, [edi + 0x3c]
mov byte [esp + 0x238], 2
mov ecx, ebp
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], ebp
call fcn.0040c910
mov eax, dword [esp + 0x240]
lea ecx, [esp + 0x14]
lea esi, [eax + 0xb]
push esi
push str._03d
push ecx
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x250]
add esp, 0xc
mov dl, byte [eax + 1]
mov bl, byte [eax]
mov al, byte [eax + 2]
mov byte [esp + 0x13], dl
push ecx
lea edx, [esp + 0x18]
push str._03d
push edx
mov byte [esp + 0x29], al
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x20]
add esp, 0xc
mov cl, byte [eax]
mov dl, byte [eax + 1]
mov al, byte [eax + 2]
mov byte [esp + 0x1f], cl
mov ecx, dword [esp + 0x248]
mov byte [esp + 0x1e], dl
push ecx
lea edx, [esp + 0x18]
push str._03d
push edx
mov byte [esp + 0x28], al
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x20]
add esp, 0xc
mov cl, byte [eax]
mov dl, byte [eax + 1]
mov al, byte [eax + 2]
mov byte [esp + 0x32], bl
mov bl, byte [esp + 0x13]
mov byte [esp + 0x3a], al
mov byte [esp + 0x33], bl
mov bl, byte [esp + 0x1d]
mov byte [esp + 0x34], bl
mov bl, byte [esp + 0x1f]
mov byte [esp + 0x35], bl
mov bl, byte [esp + 0x1e]
mov byte [esp + 0x36], bl
mov bl, byte [esp + 0x1c]
mov byte [esp + 0x30], 2
mov byte [esp + 0x31], 0xb2
mov byte [esp + 0x37], bl
mov byte [esp + 0x38], cl
mov byte [esp + 0x39], dl
mov eax, 1
mov ebx, dword [esp + 0x20]
xor ecx, ecx
mov cl, byte [esp + eax + 0x30]
xor ebx, ecx
inc eax
cmp eax, 0xb
mov dword [esp + 0x20], ebx
jl 0x40d0b7
mov eax, 0xb
cmp esi, eax
jle 0x40d104
mov ecx, dword [esp + 0x24c]
lea ebp, [esp + 0x3b]
sub ebp, ecx
add esi, 0xfffffff5
lea eax, [esi + 0xb]
mov dl, byte [ecx]
mov ebx, dword [esp + 0x20]
mov byte [ecx + ebp], dl
xor edx, edx
mov dl, byte [ecx]
xor ebx, edx
inc ecx
dec esi
mov dword [esp + 0x20], ebx
jne 0x40d0e9
mov ebp, dword [esp + 0x24]
mov cl, byte [esp + 0x20]
lea edx, [esp + 0x30]
mov byte [esp + eax + 0x30], cl
inc eax
mov ecx, edi
mov byte [esp + eax + 0x30], 3
inc eax
push eax
push edx
call fcn.0040ccb0
mov ebx, dword [sym.imp.MSVCRT.dll_clock]
xor edi, edi
mov byte [esp + 0x13], 0
call ebx
mov esi, eax
add esi, 0x3e8
call ebx
cmp esi, eax
jle 0x40d1d8
mov ebx, dword [esp + 0x250]
mov ecx, ebp
call fcn.0040c930
test eax, eax
mov dword [esp + 0x24], eax
je 0x40d1ca
xor esi, esi
test eax, eax
jle 0x40d1bc
lea eax, [esp + 0x1b]
mov ecx, ebp
push eax
call fcn.0040c9b0
mov cl, byte [esp + 0x1b]
cmp cl, 2
jne 0x40d181
mov al, byte [esp + 0x13]
test al, al
jne 0x40d181
mov byte [esp + 0x13], 1
jmp 0x40d1b3
test edi, edi
jne 0x40d197
cmp cl, 2
je 0x40d1b3
cmp cl, 0x6e
jne 0x40d197
mov byte [ebx], 0x6f
mov edi, 1
mov edx, dword [esp + 0x244]
lea eax, [edi + 1]
cmp eax, edx
mov byte [edi + ebx], cl
jl 0x40d1b1
cmp cl, 3
je 0x40d232
mov edi, eax
mov eax, dword [esp + 0x24]
inc esi
cmp esi, eax
jl 0x40d15d
call dword [sym.imp.MSVCRT.dll_clock]
mov esi, eax
add esi, 0x3e8
call dword [sym.imp.MSVCRT.dll_clock]
cmp esi, eax
jg 0x40d148
mov ecx, ebp
call fcn.0040c910
lea ecx, [esp + 0x2c]
mov byte [esp + 0x238], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x28]
mov dword [esp + 0x238], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor al, al
mov ecx, dword [esp + 0x230]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x22c
ret 0x14
lea ecx, [esp + 0x2c]
mov byte [esp + 0x238], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x238], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x28]
mov dword [esp + 0x238], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov al, 1
jmp 0x40d217