Function at 0x406ae0
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x490
mov eax, dword [0x4160a8]
xor eax, ebp
mov dword [ebp - 0x1c], eax
mov byte [ebp - 0x440], 0
push 0x3ff
push 0
lea eax, [ebp - 0x43f]
push eax
call fcn.004076d0
add esp, 0xc
mov dword [ebp - 0x30], 2
cmp dword [ebp + 0x14], 0
je 0x406b23
mov ecx, dword [ebp + 0x14]
mov byte [ecx], 0
cmp dword [ebp + 0x18], 0
je 0x406b32
mov edx, dword [ebp + 0x18]
mov dword [edx], 0
mov dword [ebp - 0x2c], 0xaac56b
mov eax, 0xcd44
mov word [ebp - 0x28], ax
mov ecx, 0x11d0
mov word [ebp - 0x26], cx
mov byte [ebp - 0x24], 0x8c
mov byte [ebp - 0x23], 0xc2
mov byte [ebp - 0x22], 0
mov byte [ebp - 0x21], 0xc0
mov byte [ebp - 0x20], 0x4f
mov byte [ebp - 0x1f], 0xc2
mov byte [ebp - 0x1e], 0x95
mov byte [ebp - 0x1d], 0xee
push 0x10
push 0
lea edx, [ebp - 0x14]
push edx
call fcn.004076d0
add esp, 0xc
push 0x30
push 0
lea eax, [ebp - 0x474]
push eax
call fcn.004076d0
add esp, 0xc
mov dword [ebp - 0x14], 0x10
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x474], 0x30
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x468], edx
mov dword [ebp - 0x464], 0
mov dword [ebp - 0x460], 1
lea eax, [ebp - 0x14]
mov dword [ebp - 0x45c], eax
xor ecx, ecx
cmp dword [ebp + 0x18], 0
setne cl
mov dword [ebp - 0x458], ecx
push str.wintrust.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0
jne 0x406bfc
xor eax, eax
jmp 0x406e8e
push str.WinVerifyTrust
mov edx, dword [ebp - 0x34]
push edx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x18], eax
push str.WTHelperProvDataFromStateData
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x444], eax
push str.WTHelperGetProvSignerFromChain
mov ecx, dword [ebp - 0x34]
push ecx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 4], eax
push str.WTHelperGetProvCertFromChain
mov edx, dword [ebp - 0x34]
push edx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x18], 0
je 0x406c62
cmp dword [ebp - 0x444], 0
je 0x406c62
cmp dword [ebp - 4], 0
je 0x406c62
cmp dword [ebp - 0x38], 0
jne 0x406c73
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor eax, eax
jmp 0x406e8e
cmp dword [ebp + 0x10], 2
jne 0x406c85
mov dword [ebp - 0x48c], 0xffffffff
jmp 0x406c8e
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x48c], ecx
lea edx, [ebp - 0x474]
push edx
lea eax, [ebp - 0x2c]
push eax
mov ecx, dword [ebp - 0x48c]
push ecx
call dword [ebp - 0x18]
mov dword [ebp - 0x3c], eax
mov edx, dword [ebp - 0x3c]
push edx
push str._WVT__WVT_returned_0x_X_n
call fcn.00406840
add esp, 8
cmp dword [ebp - 0x3c], 0x800b0001
jne 0x406ccc
mov dword [ebp - 0x490], 0
jmp 0x406cde
xor eax, eax
cmp dword [ebp - 0x3c], 0
setne al
add eax, 1
mov dword [ebp - 0x490], eax
mov ecx, dword [ebp - 0x490]
mov dword [ebp - 0x30], ecx
cmp dword [ebp - 0x30], 0
jne 0x406d23
mov dword [ebp - 0x468], 2
mov dword [ebp - 0x458], 2
lea edx, [ebp - 0x474]
push edx
lea eax, [ebp - 0x2c]
push eax
push 0xffffffffffffffff
call dword [ebp - 0x18]
mov ecx, dword [ebp - 0x34]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x30]
jmp 0x406e8e
cmp dword [ebp + 0x14], 0
je 0x406d38
cmp dword [ebp - 0x3c], 0x800b0100
setne dl
mov eax, dword [ebp + 0x14]
mov byte [eax], dl
cmp dword [ebp - 0x3c], 0x800b0100
jne 0x406d77
mov dword [ebp - 0x468], 2
mov dword [ebp - 0x458], 2
lea ecx, [ebp - 0x474]
push ecx
lea edx, [ebp - 0x2c]
push edx
push 0xffffffffffffffff
call dword [ebp - 0x18]
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x30]
jmp 0x406e8e
cmp dword [ebp + 0x18], 0
je 0x406e81
mov dword [ebp - 0x478], 0
mov dword [ebp - 0x480], 0
mov dword [ebp - 0x47c], 0
mov ecx, dword [ebp - 0x454]
push ecx
call dword [ebp - 0x444]
mov dword [ebp - 0x478], eax
cmp dword [ebp - 0x478], 0
je 0x406dec
push 0
push 0
push 0
mov edx, dword [ebp - 0x478]
push edx
call dword [ebp - 4]
mov dword [ebp - 0x480], eax
cmp dword [ebp - 0x480], 0
je 0x406dec
push 0
mov eax, dword [ebp - 0x480]
push eax
call dword [ebp - 0x38]
mov dword [ebp - 0x47c], eax
cmp dword [ebp - 0x47c], 0
jne 0x406e00
mov ecx, dword [ebp + 0x18]
mov dword [ecx], 0
jmp 0x406e5d
push 0x412f94
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0x484], eax
cmp dword [ebp - 0x484], 0
je 0x406e5d
push str.CertDuplicateCertificateContext
mov edx, dword [ebp - 0x484]
push edx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x488], eax
cmp dword [ebp - 0x488], 0
je 0x406e50
mov eax, dword [ebp - 0x47c]
mov ecx, dword [eax + 4]
push ecx
call dword [ebp - 0x488]
mov edx, dword [ebp + 0x18]
mov dword [edx], eax
mov eax, dword [ebp - 0x484]
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [ebp - 0x468], 2
mov dword [ebp - 0x458], 2
lea ecx, [ebp - 0x474]
push ecx
lea edx, [ebp - 0x2c]
push edx
push 0xffffffffffffffff
call dword [ebp - 0x18]
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.00407687
mov esp, ebp
pop ebp
ret