Function at 0x4c9fc0
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push 0xffffffffffffffff
push 0x4f9188
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1c
push ebx
push esi
push edi
mov esi, ecx
mov dword [esp + 0x14], 0
mov word [esp + 0x18], 0
mov eax, dword [0x50d0e0]
mov dword [esp + 0x30], 0
mov dword [esp + 0xc], eax
mov eax, dword [esi + 4]
lea edx, [esp + 0x14]
push edx
push 0x400
lea edx, [esp + 0x18]
push 1
mov dword [esp + 0x1c], str.tagName
mov ecx, dword [eax]
push edx
push 0x4fc6bc
push eax
mov byte [esp + 0x48], 1
call dword [ecx + 0x14]
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
test eax, eax
jl 0x4ca154
mov ecx, dword [esp + 0x14]
mov edx, dword [esi + 4]
lea eax, [esp + 0x18]
push eax
push ecx
push edx
call fcn.004ca1e0
add esp, 0xc
test eax, eax
jl 0x4ca154
cmp word [esp + 0x18], 8
jne 0x4ca154
mov eax, dword [esp + 0x20]
test eax, eax
je 0x4ca154
mov ecx, dword [0x50d0e0]
mov edx, eax
shr edx, 0x10
mov esi, eax
mov dword [esp + 0x10], ecx
jne 0x4ca091
and eax, 0xffff
lea ecx, [esp + 0x10]
push eax
call fcn.00407b60
jmp 0x4ca0c9
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
test edi, edi
je 0x4ca0c9
push edi
lea ecx, [esp + 0x14]
call fcn.00402190
test eax, eax
je 0x4ca0c9
lea ecx, [edi + edi]
lea eax, [edi + edi + 2]
cmp eax, ecx
jb 0x4ca0c9
mov edi, dword [esp + 0x10]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x10]
cmp eax, ecx
mov byte [esp + 0x30], 2
je 0x4ca124
mov edx, dword [eax - 0xc]
test edx, edx
jge 0x4ca0ee
mov edx, dword [0x50d0e4]
add eax, 0xfffffff4
cmp eax, edx
jne 0x4ca0f5
mov eax, dword [ecx - 0xc]
test eax, eax
jge 0x4ca105
mov eax, dword [ecx - 8]
push ecx
push eax
lea ecx, [esp + 0x14]
call fcn.004021f0
jmp 0x4ca11c
lea ecx, [esp + 0xc]
call fcn.00402350
mov eax, dword [esp + 0x10]
mov dword [esp + 0xc], eax
add eax, 0xfffffff4
push eax
call ebx
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x10]
mov esi, dword [0x50d0e4]
lea edx, [ecx - 0xc]
cmp edx, esi
mov byte [esp + 0x30], 1
je 0x4ca158
add ecx, 0xfffffff4
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x4ca154
mov eax, dword [esp + 0x10]
add eax, 0xfffffff4
push eax
call fcn.004de3a6
add esp, 4
mov eax, dword [esp + 0xc]
mov edx, dword [eax - 0xc]
mov esi, dword [esp + 0x38]
lea ecx, [eax - 0xc]
test edx, edx
jl 0x4ca16d
push ecx
mov dword [esi], eax
call ebx
jmp 0x4ca18b
mov ecx, dword [0x50d0e0]
mov edi, eax
test eax, eax
mov dword [esi], ecx
je 0x4ca182
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push edi
push eax
mov ecx, esi
call fcn.004021f0
mov eax, dword [esp + 0xc]
mov ecx, dword [0x50d0e4]
lea edx, [eax - 0xc]
cmp edx, ecx
je 0x4ca1ba
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x4ca1ba
mov eax, dword [esp + 0xc]
add eax, 0xfffffff4
push eax
call fcn.004de3a6
add esp, 4
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov ecx, dword [esp + 0x28]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x28
ret 4