Function at 0x407e20
Capabilities:
Get session user name
Schedule task via itaskservice

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50d1df
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0xd0
mov eax, dword [0x557768]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ecx, dword [ebx + 0x10]
mov edx, dword [ebx + 8]
mov eax, dword [ebx + 0xc]
mov dword [ebp - 0x68], ecx
mov ecx, dword [ebx + 0x14]
mov dword [ebp - 0x90], edx
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x70], ecx
test edx, edx
je 0x408796
test eax, eax
je 0x408796
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
mov dword [ebp - 0x28], 0
lea eax, [ebp - 0x28]
mov dword [ebp - 4], 0
push eax
push 0x518360
push 0x17
push 0
push 0x52ecf0
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
jns 0x407ed3
push eax
push str.Cant_CoCreateInstance_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x40877e
lea eax, [ebp - 0x60]
xorps xmm0, xmm0
push eax
movups xmmword [ebp - 0x60], xmm0
call dword [sym.imp.OLEAUT32.dll_VariantClear]
mov eax, dword [ebp - 0x28]
sub esp, 0x10
movups xmm0, xmmword [ebp - 0x60]
mov byte [ebp - 4], 2
mov ecx, dword [eax]
mov edx, dword [ecx + 0x28]
mov ecx, esp
sub esp, 0x10
movups xmmword [ecx], xmm0
mov ecx, esp
sub esp, 0x10
movups xmmword [ecx], xmm0
mov ecx, esp
sub esp, 0x10
movups xmmword [ecx], xmm0
mov ecx, esp
push eax
movups xmmword [ecx], xmm0
call edx
test eax, eax
jns 0x407f30
push eax
push str.Cant_Connect_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408774
mov dword [ebp - 0x38], 0
mov esi, dword [ebp - 0x28]
lea ecx, [ebp - 0x64]
push 0x5179e0
mov byte [ebp - 4], 4
mov eax, dword [esi]
mov edi, dword [eax + 0x1c]
call fcn.00406d30
mov eax, dword [eax]
mov byte [ebp - 4], 5
test eax, eax
je 0x407f5e
mov eax, dword [eax]
jmp 0x407f60
xor eax, eax
lea ecx, [ebp - 0x38]
push ecx
push eax
push esi
call edi
mov esi, dword [ebp - 0x64]
mov edi, dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [ebp - 0x18], eax
test esi, esi
je 0x407fbb
or ecx, 0xffffffff
lock xadd dword [esi + 8], ecx
dec ecx
jne 0x407fbb
test esi, esi
je 0x407fbb
mov eax, dword [esi]
test eax, eax
je 0x407f96
push eax
call edi
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x407fad
push eax
call fcn.004a2884
add esp, 4
mov dword [esi + 4], 0
push 0xc
push esi
call fcn.004a256a
mov eax, dword [ebp - 0x18]
add esp, 8
test eax, eax
jns 0x407fd4
push eax
push str.Cant_GetFolder_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408763
mov dword [ebp - 0x34], 0
mov esi, dword [ebp - 0x38]
lea ecx, [ebp - 0x64]
push 0x5179e0
mov byte [ebp - 4], 8
mov eax, dword [esi]
mov eax, dword [eax + 0x24]
mov dword [ebp - 0x18], eax
call fcn.00406d30
mov eax, dword [eax]
mov byte [ebp - 4], 9
test eax, eax
je 0x408005
mov eax, dword [eax]
jmp 0x408007
xor eax, eax
lea ecx, [ebp - 0x34]
push ecx
push eax
push esi
call dword [ebp - 0x18]
mov esi, dword [ebp - 0x64]
mov ecx, eax
mov dword [ebp - 0x18], ecx
mov byte [ebp - 4], 8
test esi, esi
je 0x408063
or eax, 0xffffffff
lock xadd dword [esi + 8], eax
dec eax
jne 0x408063
test esi, esi
je 0x408063
mov eax, dword [esi]
test eax, eax
je 0x40803e
push eax
call edi
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x408055
push eax
call fcn.004a2884
add esp, 4
mov dword [esi + 4], 0
push 0xc
push esi
call fcn.004a256a
mov ecx, dword [ebp - 0x18]
add esp, 8
test ecx, ecx
jns 0x4080b3
push ecx
push 0x5179e0
push str.Cant_GetFolder_:_s___x
call fcn.004097a0
mov eax, dword [ebp - 0x38]
add esp, 0xc
movups xmm0, xmmword [ebp - 0x60]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x2c]
lea ecx, [ebp - 0x34]
push ecx
sub esp, 0x10
mov ecx, esp
push 0x5179e0
push eax
movups xmmword [ecx], xmm0
call edx
test eax, eax
jns 0x4080b3
push eax
push str.Cant_CreateFolder_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408752
mov dword [ebp - 0x20], 0
mov eax, dword [ebp - 0x28]
lea edx, [ebp - 0x20]
push edx
push 0
push eax
mov ecx, dword [eax]
mov byte [ebp - 4], 0xd
call dword [ecx + 0x24]
test eax, eax
jns 0x4080e6
push eax
push str.Cant_NewTask_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408741
mov dword [ebp - 0x30], 0
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x30]
push edx
push eax
mov byte [ebp - 4], 0x12
mov ecx, dword [eax]
call dword [ecx + 0x2c]
test eax, eax
jns 0x408117
push eax
push str.Cant_get_Settings:__x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408730
mov esi, dword [ebp - 0x30]
mov eax, dword [esi]
mov edi, dword [eax + 0x48]
mov eax, 0xb
mov word [ebp - 0x88], ax
xor eax, eax
mov word [ebp - 0x80], ax
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 0x18
call fcn.00407900
movzx eax, ax
push eax
push esi
call edi
mov esi, eax
lea eax, [ebp - 0x88]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
test esi, esi
jns 0x40816f
push esi
push str.Cant_put_DisallowStartIfOnBatteries:__x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408730
mov esi, dword [ebp - 0x30]
mov eax, dword [esi]
mov edi, dword [eax + 0x40]
mov eax, 0xb
mov word [ebp - 0x88], ax
xor eax, eax
mov word [ebp - 0x80], ax
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 0x1e
call fcn.00407900
movzx eax, ax
push eax
push esi
call edi
mov esi, eax
lea eax, [ebp - 0x88]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
test esi, esi
jns 0x4081c7
push esi
push str.Cant_put_StopIfGoingOnBatteries:__x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x408730
mov dword [ebp - 0x48], 0
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x48]
push edx
push eax
mov byte [ebp - 4], 0x24
mov ecx, dword [eax]
call dword [ecx + 0x24]
test eax, eax
jns 0x4081f8
push eax
push str.Cant_get_Triggers_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x40871f
mov dword [ebp - 0x44], 0
mov eax, dword [ebp - 0x48]
lea edx, [ebp - 0x44]
push edx
push 9
push eax
mov ecx, dword [eax]
mov byte [ebp - 4], 0x2b
call dword [ecx + 0x28]
mov esi, eax
test esi, esi
jns 0x40822d
push esi
push str.Cant_CreateTask_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x40870e
mov eax, dword [ebp - 0x44]
xor ecx, ecx
mov byte [ebp - 4], 0x33
mov dword [ebp - 0x1c], ecx
test eax, eax
je 0x408258
mov ecx, dword [eax]
lea edx, [ebp - 0x1c]
push edx
push 0x517c48
push eax
call dword [ecx]
mov ecx, dword [ebp - 0x1c]
xor edx, edx
test eax, eax
cmovs ecx, edx
mov dword [ebp - 0x1c], ecx
mov byte [ebp - 4], 0x34
test ecx, ecx
jne 0x408275
push esi
push str.Cant_logon_trigger_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086fd
mov eax, dword [ecx]
push 0xffffffffffffffff
push ecx
call dword [eax + 0x4c]
mov edi, dword [ebp - 0x1c]
push str.Trigger1
mov eax, dword [edi]
mov eax, dword [eax + 0x24]
mov dword [ebp - 0x18], eax
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov esi, eax
mov dword [ebp - 0x6c], esi
test esi, esi
je 0x4087c5
push esi
push edi
mov byte [ebp - 4], 0x3d
call dword [ebp - 0x18]
mov edi, dword [sym.imp.OLEAUT32.dll_SysStringLen]
push esi
mov byte [ebp - 4], 0x34
call edi
cmp word [0x55d248], 0
mov esi, dword [ebp - 0x1c]
mov eax, dword [esi]
mov eax, dword [eax + 0x5c]
mov dword [ebp - 0x8c], eax
jne 0x4082e5
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0x100
push eax
push 0x55d248
push 2
call sub.Secur32.dll_GetUserNameExW
call fcn.004051e0
mov ecx, eax
test ecx, ecx
je 0x4087cf
mov eax, dword [ecx]
mov eax, dword [eax + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x64], eax
push 0x55d248
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 0x3e
call fcn.00404db0
test al, al
jne 0x408323
push 0x55d248
lea ecx, [ebp - 0x64]
call fcn.004048e0
push dword [ebp - 0x64]
lea ecx, [ebp - 0x6c]
mov byte [ebp - 4], 0x3f
call fcn.00406890
push dword [eax]
mov byte [ebp - 4], 0x40
push esi
call dword [ebp - 0x8c]
push dword [ebp - 0x6c]
call edi
lea ecx, [ebp - 0x64]
call fcn.004048c0
lea ecx, [ebp - 0x64]
mov dword [ebp - 0x64], 0
call fcn.00406460
lea eax, [ebp - 0x64]
mov byte [ebp - 4], 0x41
push str.PT3S
push eax
call fcn.004050f0
mov esi, dword [ebp - 0x1c]
lea ecx, [ebp - 0x6c]
add esp, 8
mov eax, dword [esi]
push dword [ebp - 0x64]
mov edi, dword [eax + 0x54]
call fcn.00406890
push dword [eax]
mov byte [ebp - 4], 0x42
push esi
call edi
push dword [ebp - 0x6c]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [ebp - 0x40], 0
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x40]
push edx
push eax
mov byte [ebp - 4], 0x43
mov ecx, dword [eax]
call dword [ecx + 0x44]
test eax, eax
jns 0x4083c6
push eax
push str.Cant_get_Actions_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086e4
mov dword [ebp - 0x3c], 0
mov eax, dword [ebp - 0x40]
lea edx, [ebp - 0x3c]
push edx
push 0
push eax
mov ecx, dword [eax]
mov byte [ebp - 4], 0x4d
call dword [ecx + 0x30]
test eax, eax
jns 0x4083f9
push eax
push str.Cant_Create_action_:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086d3
push dword [ebp - 0x3c]
lea ecx, [ebp - 0x24]
mov dword [ebp - 0x24], 0
call fcn.004063f0
mov esi, dword [ebp - 0x24]
lea ecx, [ebp - 0x74]
push dword [ebp - 0x74]
mov byte [ebp - 4], 0x58
mov eax, dword [esi]
mov edi, dword [eax + 0x2c]
call fcn.00406890
push dword [eax]
mov byte [ebp - 4], 0x59
push esi
call edi
push dword [ebp - 0x74]
mov esi, eax
mov byte [ebp - 4], 0x58
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
test esi, esi
jns 0x408453
push esi
push str.Cant_put_Path:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086c2
mov ecx, dword [ebp - 0x70]
test ecx, ecx
je 0x40849c
mov esi, dword [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x70]
mov eax, dword [esi]
mov edi, dword [eax + 0x34]
call fcn.00406890
push dword [eax]
mov byte [ebp - 4], 0x65
push esi
call edi
push dword [ebp - 0x70]
mov esi, eax
mov byte [ebp - 4], 0x58
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
test esi, esi
jns 0x40849c
push esi
push str.Cant_put_Arguments:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086c2
mov ecx, dword [ebp - 0x68]
test ecx, ecx
je 0x4084e1
mov esi, dword [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x68]
mov eax, dword [esi]
mov edi, dword [eax + 0x3c]
call fcn.00406890
push dword [eax]
mov byte [ebp - 4], 0x71
push esi
call edi
push dword [ebp - 0x68]
mov esi, eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
test esi, esi
jns 0x4084e1
push esi
push str.Cant_put_WorkingDirectory:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086c2
mov dword [ebp - 0x2c], 0
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x2c]
push edx
push eax
mov byte [ebp - 4], 0x7d
mov ecx, dword [eax]
call dword [ecx + 0x3c]
test eax, eax
jns 0x408512
push eax
push str.Cant_get_Principal:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086b1
mov edi, dword [ebp - 0x2c]
push str.Users
mov eax, dword [edi]
mov eax, dword [eax + 0x40]
mov dword [ebp - 0x68], eax
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov esi, eax
mov dword [ebp - 0x70], esi
test esi, esi
je 0x4087d9
push esi
push edi
mov byte [ebp - 4], 0x8a
call dword [ebp - 0x68]
push esi
mov edi, eax
mov byte [ebp - 4], 0x7d
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
test edi, edi
jns 0x408564
push edi
push str.Cant_put_GroupId:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086b1
mov eax, dword [ebp - 0x2c]
push 1
push eax
mov ecx, dword [eax]
call dword [ecx + 0x48]
test eax, eax
jns 0x408588
push eax
push str.Cant_put_RunLevel:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086b1
mov dword [ebp - 0x4c], 0
mov esi, dword [ebp - 0x34]
xorps xmm0, xmm0
mov edi, dword [sym.imp.OLEAUT32.dll_VariantClear]
mov eax, dword [esi]
movups xmmword [ebp - 0xb0], xmm0
mov eax, dword [eax + 0x44]
mov dword [ebp - 0x68], eax
lea eax, [ebp - 0xb0]
push eax
call edi
movups xmm0, xmmword [ebp - 0xb0]
lea eax, [ebp - 0xa0]
push eax
movups xmmword [ebp - 0xc0], xmm0
xorps xmm0, xmm0
movups xmmword [ebp - 0xa0], xmm0
call edi
movups xmm0, xmmword [ebp - 0xa0]
lea eax, [ebp - 0x88]
push eax
movups xmmword [ebp - 0xd0], xmm0
xorps xmm0, xmm0
movups xmmword [ebp - 0x88], xmm0
call edi
movups xmm0, xmmword [ebp - 0x88]
mov edi, dword [ebp - 0x20]
lea ecx, [ebp - 0x70]
push dword [ebp - 0x90]
mov byte [ebp - 4], 0xa6
movups xmmword [ebp - 0xe0], xmm0
call fcn.00406890
mov ecx, dword [eax]
lea eax, [ebp - 0x4c]
movups xmm0, xmmword [ebp - 0xc0]
push eax
sub esp, 0x10
mov byte [ebp - 4], 0xa7
mov eax, esp
push 3
sub esp, 0x10
movups xmmword [eax], xmm0
mov eax, esp
sub esp, 0x10
movups xmm0, xmmword [ebp - 0xd0]
movups xmmword [eax], xmm0
mov eax, esp
movups xmm0, xmmword [ebp - 0xe0]
push 6
push edi
push ecx
push esi
movups xmmword [eax], xmm0
call dword [ebp - 0x68]
push dword [ebp - 0x70]
mov esi, eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov edi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea eax, [ebp - 0x88]
push eax
call edi
lea eax, [ebp - 0xa0]
push eax
call edi
lea eax, [ebp - 0xb0]
push eax
call edi
test esi, esi
jns 0x40869b
push esi
push str.Cant_RegisterTaskDefinition:_x
call fcn.004097a0
add esp, 8
xor esi, esi
jmp 0x4086a0
mov esi, 1
mov eax, dword [ebp - 0x4c]
mov byte [ebp - 4], 0xb5
test eax, eax
je 0x4086b1
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x2c]
mov byte [ebp - 4], 0xb6
test eax, eax
je 0x4086c2
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x24]
mov byte [ebp - 4], 0xb7
test eax, eax
je 0x4086d3
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x3c]
mov byte [ebp - 4], 0xb8
test eax, eax
je 0x4086e4
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x40]
mov byte [ebp - 4], 0xb9
test eax, eax
je 0x4086f5
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
lea ecx, [ebp - 0x64]
call fcn.004048c0
mov eax, dword [ebp - 0x1c]
mov byte [ebp - 4], 0xba
test eax, eax
je 0x40870e
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x44]
mov byte [ebp - 4], 0xbb
test eax, eax
je 0x40871f
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x48]
mov byte [ebp - 4], 0xbc
test eax, eax
je 0x408730
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x30]
mov byte [ebp - 4], 0xbd
test eax, eax
je 0x408741
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x20]
mov byte [ebp - 4], 0xbe
test eax, eax
je 0x408752
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x34]
mov byte [ebp - 4], 0xbf
test eax, eax
je 0x408763
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x38]
mov byte [ebp - 4], 0xc0
test eax, eax
je 0x408774
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
lea eax, [ebp - 0x60]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 4], 0xc1
test ecx, ecx
je 0x408792
mov edx, dword [ecx]
push ecx
call dword [edx + 8]
mov eax, esi
jmp 0x4087a5
push str.Name_or_Path_IsNULL
call fcn.004097a0
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004a2820
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 0x10
push 0x8007000e
call fcn.00404d90
push 0x80004005
call fcn.00404d90
push 0x8007000e
call fcn.00404d90
int3