Function at 0x418230
Capabilities:
Check for peb beingdebugged flag

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x54f978
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x40
call fcn.00525ec0
mov eax, dword [ecx + 0x20]
mov eax, dword [eax]
push ebx
push ebp
xor edx, edx
push esi
push edi
mov dword [esp + 0x1c], ecx
cmp eax, edx
je 0x41829f
mov eax, dword [ecx + 0x20]
mov esi, dword [ecx + 0x30]
mov eax, dword [eax]
mov esi, dword [esi]
lea esi, [eax + esi*2]
cmp eax, esi
jae 0x41829f
mov eax, dword [ecx + 0x30]
dec dword [eax]
mov eax, dword [ecx + 0x20]
mov ecx, dword [eax]
lea edx, [ecx + 2]
mov dword [eax], edx
mov ax, word [ecx]
mov ecx, dword [esp + 0x54]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ecx + 0x4c]
cmp eax, edx
je 0x41854b
cmp dword [ecx + 0x3c], edx
jne 0x4182e1
push eax
call fcn.0050ee5d
movzx eax, ax
mov ecx, 0xffff
add esp, 4
cmp ax, cx
movzx eax, ax
jne 0x418550
mov eax, ecx
mov ecx, dword [esp + 0x54]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [esp + 0x4c], 0xf
mov dword [esp + 0x48], edx
mov byte [esp + 0x38], dl
mov dword [esp + 0x5c], edx
mov edx, dword [ecx + 0x4c]
push edx
call fcn.0050ebae
add esp, 4
cmp eax, 0xffffffff
je 0x41853a
push eax
push 1
lea ecx, [esp + 0x3c]
call fcn.00419e10
mov edi, dword [esp + 0x4c]
mov eax, dword [esp + 0x38]
cmp edi, 0x10
jb 0x41848a
mov ebx, eax
test eax, eax
je 0x418351
mov ecx, eax
cmp edi, 0x10
jae 0x418338
lea ecx, [esp + 0x38]
cmp ecx, ebx
ja 0x418351
mov ecx, eax
cmp edi, 0x10
jae 0x418347
lea ecx, [esp + 0x38]
mov edx, dword [esp + 0x48]
add ecx, edx
cmp ebx, ecx
jbe 0x418362
call fcn.0050dd58
mov edi, dword [esp + 0x4c]
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x34]
cmp ecx, 0xfffffffc
je 0x41838d
mov ecx, eax
cmp edi, 0x10
jae 0x418376
lea ecx, [esp + 0x38]
add ecx, edx
cmp ebx, ecx
jb 0x41838d
call fcn.0050dd58
mov edi, dword [esp + 0x4c]
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x38]
mov ebp, edx
cmp edi, 0x10
jb 0x418493
mov esi, eax
test eax, eax
je 0x4183be
mov ecx, eax
cmp edi, 0x10
jae 0x4183a9
lea ecx, [esp + 0x38]
cmp ecx, esi
ja 0x4183be
mov ecx, eax
cmp edi, 0x10
jae 0x4183b8
lea ecx, [esp + 0x38]
add ecx, edx
cmp esi, ecx
jbe 0x4183cf
call fcn.0050dd58
mov edi, dword [esp + 0x4c]
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x34]
cmp ecx, 0xfffffffc
je 0x4183ec
cmp edi, 0x10
jae 0x4183e1
lea eax, [esp + 0x38]
add eax, edx
cmp esi, eax
jb 0x4183ec
call fcn.0050dd58
mov edi, dword [esp + 0x1c]
mov ecx, dword [edi + 0x3c]
mov edx, dword [ecx]
mov edx, dword [edx + 0x10]
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x1a]
push eax
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x24]
push eax
add ebx, ebp
push ebx
push esi
lea eax, [edi + 0x44]
push eax
call edx
test eax, eax
jl 0x41853a
cmp eax, 1
jle 0x41849c
cmp eax, 3
jne 0x41853a
cmp dword [esp + 0x48], 2
jb 0x418525
push 2
lea edx, [esp + 0x28]
push edx
lea ecx, [esp + 0x3c]
call fcn.00419d70
mov ecx, eax
call fcn.00419cd0
push eax
lea eax, [esp + 0x1c]
push 2
push eax
call fcn.0050d7e9
movzx esi, word [esp + 0x24]
add esp, 0x10
mov dword [esp + 0x5c], 0xffffffff
lea ecx, [esp + 0x34]
call fcn.0041ac40
mov ax, si
mov ecx, dword [esp + 0x54]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
lea ebx, [esp + 0x38]
jmp 0x41832d
lea esi, [esp + 0x38]
jmp 0x41839e
lea eax, [esp + 0x14]
cmp dword [esp + 0x20], eax
jne 0x41856c
mov edx, dword [esp + 0x4c]
mov eax, dword [esp + 0x38]
cmp edx, 0x10
jb 0x418563
mov esi, eax
test eax, eax
je 0x4184e5
mov ecx, eax
cmp edx, 0x10
jae 0x4184cc
lea ecx, [esp + 0x38]
cmp ecx, esi
ja 0x4184e5
mov ecx, eax
cmp edx, 0x10
jae 0x4184db
lea ecx, [esp + 0x38]
mov ebx, dword [esp + 0x48]
add ecx, ebx
cmp esi, ecx
jbe 0x4184f2
call fcn.0050dd58
mov edx, dword [esp + 0x4c]
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x34]
cmp ecx, 0xfffffffc
je 0x418513
cmp edx, 0x10
jae 0x418504
lea eax, [esp + 0x38]
mov edx, dword [esp + 0x48]
add eax, edx
cmp esi, eax
jb 0x418513
call fcn.0050dd58
mov eax, dword [esp + 0x18]
sub eax, esi
push eax
push 0
lea ecx, [esp + 0x3c]
call fcn.0041a660
mov ecx, dword [edi + 0x4c]
push ecx
call fcn.0050ebae
add esp, 4
cmp eax, 0xffffffff
jne 0x41830a
mov dword [esp + 0x5c], 0xffffffff
lea ecx, [esp + 0x34]
call fcn.0041ac40
mov eax, 0xffff
mov ecx, dword [esp + 0x54]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
lea esi, [esp + 0x38]
jmp 0x4184c1
mov edi, dword [esp + 0x48]
lea ecx, [esp + 0x2c]
push ecx
lea ecx, [esp + 0x38]
call fcn.00419d70
mov ecx, eax
call fcn.00419cd0
sub edi, dword [esp + 0x18]
mov esi, eax
add esi, edi
test esi, esi
jle 0x4185b0
mov edx, dword [esp + 0x1c]
mov eax, dword [edx + 0x4c]
mov ecx, dword [esp + 0x18]
movsx edx, byte [esi + ecx - 1]
dec esi
push eax
push edx
call fcn.0050eb3c
add esp, 8
test esi, esi
jg 0x418591
movzx esi, word [esp + 0x14]
mov dword [esp + 0x5c], 0xffffffff
lea ecx, [esp + 0x34]
call fcn.0041ac40
mov ecx, dword [esp + 0x54]
pop edi
mov ax, si
mov dword fs:[0], ecx
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret