Function at 0x412060
Capabilities:
Set file attributes

Disassembly:
push 0xffffffffffffffff
push 0x46258c
mov eax, dword fs:[0]
push eax
mov eax, 0x1858
call fcn.0044f450
mov eax, dword [0x47f038]
xor eax, esp
mov dword [esp + 0x1854], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x47f038]
xor eax, esp
push eax
lea eax, [esp + 0x186c]
mov dword fs:[0], eax
mov eax, dword [esp + 0x1880]
mov edi, dword [esp + 0x187c]
push str.KMPRNAPI::_InstallDriverViaSvc_n
mov esi, ecx
mov dword [esp + 0x28], edi
mov dword [esp + 0x20], eax
call fcn.004412c0
xor ebx, ebx
xor eax, eax
add esp, 4
mov dword [esp + 0x20], eax
cmp edi, ebx
je 0x41281b
cmp word [edi], bx
je 0x41281b
push 0x34
call fcn.0044e29f
add esp, 4
mov dword [esp + 0x14], eax
mov dword [esp + 0x1874], ebx
cmp eax, ebx
je 0x412103
mov ecx, eax
call fcn.0044b430
mov dword [esp + 0x14], eax
jmp 0x412107
mov dword [esp + 0x14], ebx
push 0x104
lea ecx, [esp + 0x43c]
push ecx
push ebx
mov dword [esp + 0x1880], 0xffffffff
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea edx, [esp + 0x438]
push 0x5c
push edx
call fcn.0044e95c
add esp, 8
cmp word [eax], bx
je 0x412142
xor ecx, ecx
mov word [eax], cx
mov edi, dword [sym.imp.USER32.dll_wsprintfW]
lea edx, [esp + 0x438]
push edx
lea eax, [esp + 0x234]
push str._sKxTmpSvc.exe
push eax
call edi
lea eax, [esi + 0xc38]
push eax
lea ecx, [esp + 0x38]
push str._sKxTmpSvc.exe
push ecx
call edi
add esp, 0x18
xor eax, eax
jmp 0x412180
movzx ecx, word [esp + eax + 0x28]
mov word [esp + eax + 0xe60], cx
add eax, 2
cmp cx, bx
jne 0x412180
mov ecx, dword [esi + 4]
push ebx
push ebx
lea edx, [esp + 0x30]
push edx
lea eax, [esp + 0x23c]
push eax
call fcn.00447d30
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
push eax
push str.CopyFile____ld_n
call fcn.004412c0
lea ecx, [esp + 0x30]
push ecx
push str.CopyFile____s_n
call fcn.004412c0
lea edx, [esp + 0x448]
push edx
push str.CopyFile___wszSrcPath__s_n
call fcn.004412c0
mov ebp, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
add esp, 0x18
push 0x80
lea eax, [esp + 0x2c]
push eax
call ebp
lea ecx, [esp + 0x438]
push ecx
lea edx, [esp + 0x234]
push str._sKmInst32.exe
push edx
call edi
lea eax, [esi + 0xc38]
push eax
lea eax, [esp + 0x38]
push str._sKmInst32.exe
push eax
call edi
add esp, 0x18
push 0
push 0
lea ecx, [esp + 0x30]
push ecx
mov ecx, dword [esi + 4]
lea edx, [esp + 0x23c]
push edx
call fcn.00447d30
call ebx
push eax
push str.CopyFile____ld_n
call fcn.004412c0
lea eax, [esp + 0x30]
push eax
push str.CopyFile____s_n
call fcn.004412c0
lea ecx, [esp + 0x448]
push ecx
push str.CopyFile___wszSrcPath__s_n
call fcn.004412c0
add esp, 0x18
push 0x80
lea edx, [esp + 0x2c]
push edx
call ebp
lea eax, [esp + 0x438]
push eax
lea ecx, [esp + 0x234]
push str._sKmInst64.exe
push ecx
call edi
lea eax, [esi + 0xc38]
push eax
lea edx, [esp + 0x38]
push str._sKmInst64.exe
push edx
call edi
add esp, 0x18
push 0
push 0
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x23c]
push ecx
mov ecx, dword [esi + 4]
call fcn.00447d30
call ebx
push eax
push str.CopyFile____ld_n
call fcn.004412c0
lea edx, [esp + 0x30]
push edx
push str.CopyFile____s_n
call fcn.004412c0
lea eax, [esp + 0x448]
push eax
push str.CopyFile___wszSrcPath__s_n
call fcn.004412c0
add esp, 0x18
push 0x80
lea ecx, [esp + 0x2c]
push ecx
call ebp
mov ebp, dword [esp + 0x24]
mov ebx, dword [esp + 0x14]
lea edx, [esp + 0xe60]
push edx
push str.Kyocera_Mita_Remote_Installer_Temporary_Service
push str.KxTmpSvc
push ebp
mov ecx, ebx
call fcn.0044ad30
push 0
push 0
push str.KxTmpSvc
push ebp
mov ecx, ebx
call fcn.0044b030
lea eax, [esp + 0x18]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
push ebp
mov dword [esp + 0x24], 0
call dword [sym.imp.ADVAPI32.dll_RegConnectRegistryW]
mov ebx, eax
test ebx, ebx
je 0x4123bc
push ebx
push ebp
push str.RegConnectRegistry_failed_____s___ld__n
call fcn.004412c0
add esp, 0xc
mov dword [esp + 0x18], 0
cmp ebx, 0x35
jne 0x4123bc
push str.__Try_to_start_Remote_Registry_service_n
call fcn.004412c0
mov ebx, dword [esp + 0x18]
add esp, 4
push 0
push 0
push str.RemoteRegistry
push ebp
mov ecx, ebx
call fcn.0044b030
push 0x1388
call dword [sym.imp.KERNEL32.dll_Sleep]
lea ecx, [esp + 0x18]
push ecx
push reloc.OLEAUT32.dll_SysReAllocString
push ebp
call dword [sym.imp.ADVAPI32.dll_RegConnectRegistryW]
test eax, eax
je 0x4123c0
push eax
push ebp
push str.RegConnectRegistry_failed_____s___ld__n
call fcn.004412c0
add esp, 0xc
jmp 0x4123c0
mov ebx, dword [esp + 0x14]
push str.Set_Install_Driver_n
call fcn.004412c0
add esp, 4
cmp dword [esp + 0x18], 0
je 0x4127d3
mov ebx, dword [esp + 0x1c]
lea edx, [esp + 0xa50]
push edx
lea eax, [esp + 0x84c]
push eax
lea ecx, [ebx + 0x1aa8]
push ecx
mov ecx, dword [esi + 4]
call fcn.00446790
xor eax, eax
lea ecx, [ecx]
movzx ecx, word [esp + eax + 0x848]
mov word [esp + eax + 0x230], cx
add eax, 2
test cx, cx
jne 0x412400
call dword [sym.imp.KERNEL32.dll_GetTickCount]
xor edx, edx
push 0x206
mov dword [esp + 0x20], eax
push edx
lea eax, [esp + 0x64a]
push eax
mov word [esp + 0x64c], dx
call fcn.0044e1b0
mov ecx, dword [esp + 0x28]
push ecx
lea edx, [esp + 0x650]
push str.KXTMP_ld
push edx
call edi
lea eax, [esp + 0x658]
push eax
push str.tszTmpFolder___s__n
call fcn.004412c0
lea ecx, [esp + 0x660]
push ecx
lea eax, [esi + 0xc38]
push eax
lea edx, [esp + 0x50]
push 0x464ad0
push edx
call edi
mov ecx, dword [esi + 4]
add esp, 0x30
push 0
lea eax, [esp + 0x2c]
push eax
call fcn.00445680
push 0
push 1
push 0
lea ecx, [esp + 0x34]
push ecx
mov ecx, dword [esi + 4]
lea edx, [esp + 0x240]
push edx
call fcn.004480f0
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x234]
push ecx
push str.Copy_from__n_t__s___n_t__s__n
call fcn.004412c0
lea edx, [esp + 0xa5c]
push edx
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0xc6c]
push 0x464ad0
push ecx
call edi
mov edx, dword [esp + 0x18a0]
push edx
lea eax, [ebx + 0x208]
push eax
lea ecx, [esp + 0xc7c]
push ecx
push ebx
lea edx, [esp + 0x1094]
push str.ADDDRV__d___s___i___s___env___s___opt__d
push edx
call edi
mov ebx, dword [ebx + 0x1eb8]
add esp, 0x34
test ebx, ebx
jne 0x412548
lea eax, [esp + 0x1068]
add eax, 0xfffffffe
mov edi, edi
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x412520
mov ecx, dword [str.__v0]
mov edx, dword [0x469eec]
mov dword [eax], ecx
mov cx, word [0x469ef0]
mov dword [eax + 4], edx
mov word [eax + 8], cx
cmp ebx, 2
jne 0x412588
lea eax, [esp + 0x1068]
add eax, 0xfffffffe
jmp 0x412560
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x412560
mov edx, dword [str.__v2]
mov ecx, dword [0x469ee0]
mov dword [eax], edx
mov dx, word [0x469ee4]
mov dword [eax + 4], ecx
mov word [eax + 8], dx
cmp ebx, 3
jne 0x4125c8
lea eax, [esp + 0x1068]
add eax, 0xfffffffe
jmp 0x4125a0
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x4125a0
mov ecx, dword [str.__v3]
mov edx, dword [0x469ed4]
mov dword [eax], ecx
mov cx, word [0x469ed8]
mov dword [eax + 4], edx
mov word [eax + 8], cx
mov ecx, dword [esi + 4]
xor ebx, ebx
call fcn.00447510
test eax, eax
jne 0x4125f0
mov ecx, dword [esi + 4]
push ebp
call fcn.0044a530
cmp eax, 0x100
jle 0x4125f0
mov ebx, 0x20119
lea eax, [ebx - 0x13]
jmp 0x4125f2
mov eax, ebx
push eax
mov eax, dword [esp + 0x1c]
lea edx, [esp + 0x106c]
push edx
push 0x469ebc
push 0x464918
push eax
call fcn.0044d960
add esp, 0x14
test eax, eax
je 0x412766
mov ecx, dword [esp + 0x18]
push 0xf003f
push str.SetErr
push 0x464918
push ecx
call fcn.0044da60
mov ecx, dword [esp + 0x24]
add esp, 0x10
push 0x81
push str.KxTmpSvc
push ebp
call fcn.0044b100
mov eax, dword [esp + 0x18]
push ebx
lea edx, [esp + 0x106c]
push edx
push str.SetErr
push 0x464918
push eax
call fcn.0044d990
add esp, 0x14
test eax, eax
je 0x41275f
lea ecx, [esp + 0x1068]
push ecx
push str.RESULT____s__n
call fcn.004412c0
push 0x1c2d0
call fcn.0044e29f
add esp, 0xc
mov dword [esp + 0x1c], eax
mov dword [esp + 0x1874], 1
test eax, eax
je 0x4126af
mov ecx, eax
call fcn.004409e0
mov ebx, eax
jmp 0x4126b1
xor ebx, ebx
push 0x464914
lea edx, [esp + 0x106c]
push edx
mov ecx, ebx
mov dword [esp + 0x187c], 0xffffffff
call fcn.00440c30
test eax, eax
jle 0x41274c
push 0
mov ecx, ebx
call fcn.00401ae0
push eax
call fcn.0044e92b
add esp, 4
test eax, eax
je 0x41274c
push 1
mov ecx, ebx
call fcn.00401ae0
push eax
call fcn.0044e92b
add esp, 4
push 2
mov ecx, ebx
mov dword [esi + 0x24], eax
call fcn.00401ae0
lea edx, [esi + 0x28]
jmp 0x412710
movzx ecx, word [eax]
mov word [edx], cx
add eax, 2
add edx, 2
test cx, cx
jne 0x412710
mov eax, dword [esi + 0x24]
test eax, eax
jne 0x412730
mov dword [esp + 0x20], 1
push eax
push str.ADDDRV_m_nErrorCode_returns___d__n
call fcn.004412c0
lea eax, [esi + 0x28]
push eax
push str.ADDDRV_m_tszResult_returns___s__n
call fcn.004412c0
add esp, 0x10
test ebx, ebx
je 0x412773
mov ecx, ebx
call fcn.00440490
push ebx
call fcn.0044e22a
jmp 0x412770
push str.___Install_Driver___Failed_to_get_result_n
jmp 0x41276b
push str.___Install_Driver___Failed._Failed_to_set_Registry_command_n
call fcn.004412c0
add esp, 4
mov ecx, dword [esi + 4]
lea eax, [esp + 0x28]
push eax
call fcn.00448310
lea ebx, [esi + 0xc38]
push ebx
lea ecx, [esp + 0x2c]
push str._sKmInst32.exe
push ecx
call edi
mov ecx, dword [esi + 4]
add esp, 0xc
lea edx, [esp + 0x28]
push edx
call fcn.00445e70
push ebx
lea eax, [esp + 0x2c]
push str._sKmInst64.exe
push eax
call edi
add esp, 0xc
lea ecx, [esp + 0x28]
push ecx
mov ecx, dword [esi + 4]
call fcn.00445e70
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4127cf
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ebx, dword [esp + 0x14]
push str.KxTmpSvc
push ebp
mov ecx, ebx
call fcn.0044af10
test ebx, ebx
je 0x4127f4
mov ecx, ebx
call fcn.0044b680
push ebx
call fcn.0044e22a
add esp, 4
lea eax, [esi + 0xc38]
push eax
lea edx, [esp + 0x2c]
push str._sKxTmpSvc.exe
push edx
call edi
mov ecx, dword [esi + 4]
add esp, 0xc
lea eax, [esp + 0x28]
push eax
call fcn.00445e70
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x186c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1854]
xor ecx, esp
call fcn.0044e1a0
add esp, 0x1864
ret 0xc