Function at 0x40a840
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44e39b
mov eax, dword fs:[0]
push eax
sub esp, 0xa18
mov eax, dword [0x4703d0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
test esi, esi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x9f0], esi
je 0x40abe1
test edi, edi
je 0x40abe1
push str.mfendisk.sys
push esi
call fcn.0043c9b2
add esp, 8
test eax, eax
je 0x40a8b8
push str.mfenlfk.sys
push esi
call fcn.0043c9b2
add esp, 8
test eax, eax
je 0x40a8b8
push str.ERROR:_Required_INF_element_not_found__n
jmp 0x40abe6
push esi
push str.InstallCustomDriver__S_n
call fcn.0040ef30
add esp, 8
push 0x64
lea eax, [ebp - 0xd8]
push eax
push esi
call fcn.00408d10
lea ecx, [ebp - 0x9e8]
push 0x104
push ecx
call fcn.0042b260
push edi
lea edx, [ebp - 0x9e8]
push edx
push 0x451f20
lea eax, [ebp - 0x588]
push 0x12c
push eax
call fcn.0042a4b0
lea eax, [ebp - 0x588]
add esp, 0x1c
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40a910
sub eax, edx
push 0
lea ecx, [ebp - 0xd8]
sar eax, 1
push ecx
mov ebx, eax
call fcn.0041b220
cmp dword [0x471c20], 0
je 0x40aacb
push 0
push 0
call fcn.0042d730
add esp, 8
cmp eax, 0x1770
jge 0x40aacb
lea edi, [ebx + ebx + 0x3a]
push edi
mov dword [ebp - 0x9f4], 0
call fcn.0043c073
mov esi, eax
add esp, 4
test esi, esi
je 0x40aaa8
push edi
push 0
push esi
call fcn.0043c140
add esp, 0xc
mov dword [esi], 3
mov dword [esi + 4], edi
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push ebx
lea edx, [ebp - 0x588]
push edx
lea edi, [esi + 0x38]
mov dword [esi + 8], eax
mov dword [esi + 0xc], 0
mov dword [esi + 0x10], 2
mov dword [esi + 0x14], 1
push edi
mov dword [esi + 0x28], ebx
call fcn.0043bfd5
push 0x2e
push edi
call fcn.0043cc1c
add esp, 0x14
test eax, eax
je 0x40a9da
push 4
push str..cat
push eax
call fcn.0043bfd5
add esp, 0xc
push edi
push str.InstallCustomDriver:_Verifying_signature_on_NDIS_cat__S_n
call fcn.0040ef30
add esp, 8
push 0
lea eax, [ebp - 0x9f4]
push eax
lea ecx, [ebp - 0x9fc]
push ecx
lea edx, [ebp - 0x9f8]
push edx
push esi
call fcn.00437b10
test eax, eax
jne 0x40aa9b
push str.InstallCustomDriver:_NDIS_Cat_failed_validation__deleting_catalog_database_to_force_re_build_n
call fcn.0040ef30
add esp, 4
push 0x12c
lea eax, [ebp - 0x7e0]
push eax
push str.catroo2edb.log
push 0
call fcn.00408db0
push 0x12c
lea ecx, [ebp - 0x330]
push ecx
push str.catroo2edb.tst
push 0
call fcn.00408db0
call fcn.00402f50
mov edi, eax
push edi
call fcn.00403050
push 1
lea edx, [ebp - 0x330]
push edx
lea eax, [ebp - 0x7e0]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
je 0x40aa93
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x330]
push ecx
lea edx, [ebp - 0x7e0]
push edx
push str.ERROR:_InstallCustomDriver:_MoveFile_from__S_to__S_failed__x_n
call fcn.0040ef30
add esp, 0x10
push edi
call fcn.00403030
jmp 0x40aaa8
push str.InstallCustomDriver:_cat_validated_succesfully_n
call fcn.0040ef30
add esp, 4
mov eax, dword [ebp - 0x9f4]
test eax, eax
je 0x40aab8
push eax
call fcn.004381f0
test esi, esi
je 0x40aac5
push esi
call fcn.0043c1ba
add esp, 4
mov esi, dword [ebp - 0x9f0]
call fcn.00402f50
mov ebx, eax
push ebx
call fcn.00403050
push 0
call fcn.00409db0
push 0xbb8
mov dword [ebp - 0x9f0], eax
call dword [sym.imp.KERNEL32.dll_Sleep]
xor eax, eax
mov ecx, 0x96
lea edi, [ebp - 0x330]
rep stosd dword es:[edi], eax
push 0x12c
lea eax, [ebp - 0x330]
push eax
push esi
call fcn.00408d50
lea ecx, [ebp - 0x9e9]
push ecx
lea edx, [ebp - 0x330]
push edx
push esi
call fcn.004041e0
mov eax, dword [0x47159c]
push eax
lea ecx, [ebp - 0x588]
push ecx
lea ecx, [ebp - 0xa24]
call fcn.0041b5b0
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x10]
push 0x471598
push edx
push eax
push 1
lea ecx, [ebp - 0xd8]
push ecx
push esi
lea ecx, [ebp - 0xa24]
mov dword [ebp - 4], 0
call fcn.0041c580
test eax, eax
jge 0x40ab78
cmp eax, 0x4a020
mov byte [ebp - 0x9e9], 0
jne 0x40ab7f
mov byte [ebp - 0x9e9], 1
mov edx, dword [ebp - 0x9f0]
push edx
call fcn.00409db0
test ebx, ebx
je 0x40ab9b
cmp ebx, 0xffffffff
je 0x40ab9b
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 1
lea eax, [ebp - 0xd8]
push eax
call fcn.0041b220
mov bl, byte [ebp - 0x9e9]
test bl, bl
mov eax, str.successful_n
jne 0x40abbd
mov eax, str.failed_n
push eax
push str.InstallCustomDriver__s
call fcn.0040ef30
add esp, 8
lea ecx, [ebp - 0xa24]
mov dword [ebp - 4], 0xffffffff
call fcn.0041be00
mov al, bl
jmp 0x40abf0
push str.ERROR:_InstallCustomDriver:_NULL_ptr_n
call fcn.0040ef30
add esp, 4
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0043c015
mov esp, ebp
pop ebp
ret 0x14