Function at 0x407640
Capabilities:
Access peb ldr_data
Get process heap flags
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
push esi
push edi
mov esi, eax
mov ebx, dword [esi + 0x48]
push 0x4468
lea edi, [esi + 0x4a0]
push 0
push edi
call fcn.004127e0
mov eax, dword [esi + 0xc]
mov edx, dword [esi + 0x14]
mov ecx, dword [esi + 0x10]
mov dword [edi], eax
mov eax, dword fs:[0x18]
add esp, 0xc
mov dword [esi + 0x4a8], edx
mov dword [esi + 0x4a4], ecx
mov dword [esi + 0x4ac], 2
mov dword [esi + 0x4b0], 0
mov ecx, dword [eax + 0x30]
lea edx, [ebp - 0x18]
push edx
mov edi, ebx
sub edi, dword [ecx + 8]
push 0x4468
lea eax, [esi + 0x4a0]
push eax
mov eax, dword [esi]
add edi, 0x4a7350
push edi
push eax
call dword [0x4a31c8]
test eax, eax
jns 0x4076d3
push eax
push edi
push str.NtWriteVirtualMemory___p___failed_writing_child_process_parameters:__x_n
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
push 0
lea ecx, [ebp - 0xc]
push ecx
push 0x468bd8
call fcn.00411620
add esp, 0xc
test eax, eax
jns 0x4076fb
push eax
push str.supHardNtLdrCacheOpen_failed_on_NTDLL:__Rrc_n
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
mov edx, dword [esi + 0x14]
mov ecx, dword [ebp - 0xc]
push 0
push 0
push 0
push 0
push edx
lea eax, [ebp - 0x10]
push eax
push ecx
call fcn.004112b0
add esp, 0x1c
test eax, eax
jns 0x40772c
push eax
push str.supHardNtLdrCacheEntryGetBits_failed_on_NTDLL:__Rrc_n
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
mov eax, dword [esi + 0x14]
mov ecx, dword [ebp - 0x10]
lea edx, [ebp - 0x20]
push edx
mov edx, dword [ebp - 0xc]
push str.LdrInitializeThunk
push 0xffffffffffffffff
push 0
push eax
mov eax, dword [edx + 4]
push ecx
push eax
call fcn.00416ce0
add esp, 0x1c
test eax, eax
jns 0x407765
push eax
push str.Error_locating_LdrInitializeThunk_in_NTDLL:__Rrc
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
mov edi, dword [ebp - 0x20]
push edi
push str.supR3HardenedWinSetupChildInit:_uLdrInitThunk_p_n
call fcn.004014e0
mov ecx, dword fs:[0x18]
mov eax, dword [ebp - 0x20]
sub eax, dword [esi + 0x14]
mov edx, dword [ecx + 0x30]
add eax, dword [ebp - 0x10]
sub ebx, dword [edx + 8]
push 0x10
push eax
lea ecx, [ebp - 0x30]
push ecx
add ebx, 0x402700
call fcn.004034e0
sub ebx, dword [ebp - 0x20]
add esp, 0x14
lea edx, [ebp - 0x14]
push edx
mov edx, dword [esi]
push 0x40
lea eax, [ebp - 4]
push eax
lea ecx, [ebp - 8]
sub ebx, 5
push ecx
mov dword [ebp - 0x2f], ebx
mov ebx, dword [0x4a30a8]
push edx
mov byte [ebp - 0x30], 0xe9
mov dword [ebp - 8], edi
mov dword [ebp - 4], 0x10
call ebx
test eax, eax
jns 0x4077e3
push eax
push str.NtProtectVirtualMemory_LdrInitializeThunk_failed:__x
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
mov edx, dword [esi]
lea eax, [ebp - 0x18]
push eax
push 0x10
lea ecx, [ebp - 0x30]
push ecx
push edi
push edx
call dword [0x4a31c8]
test eax, eax
jns 0x40780c
push eax
push str.NtWriteVirtualMemory_LdrInitializeThunk_failed:__x
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x14]
push eax
push ecx
mov ecx, dword [esi]
lea edx, [ebp - 4]
push edx
lea eax, [ebp - 8]
push eax
push ecx
mov dword [ebp - 8], edi
mov dword [ebp - 4], 0x10
call ebx
test eax, eax
jns 0x407840
push eax
push str.NtProtectVirtualMemory_LdrInitializeThunk_restore__failed:__x
push eax
push str.supR3HardenedWinSetupChildInit
call fcn.00406c70
push str.supR3HardenedWinSetupChildInit:_Start_child._n
call fcn.004014e0
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret