Launch my application before the Windows logon screen - windows

In a personal project, I want to display my application before (or above) the Windows Logon, ie just before entering the Windows password.
The application must "hide" the password entry screen. I used to launch an application at Windows startup but this after viewing the Windows desktop.
Is it possible to do this please? Should I create a Windows service that will launch my application?
Thanks for your help

If this is just a personal project on your own machine you could set Windows to autologon and then just run your application like a normal startup shortcut.
A NT service is the only documented way to run code before a user logs on. However, spawning a new process in another session and interacting with the Winlogon desktop and putting yourself on top of LogonUI.exe is going to be a hack.

Related

opened dialog window in windows service

I am running some Windows application as a service. This application used Office applications(Word, Excel). The service runs under specific user account.
Here is the problem:
When service is trying to use Excel, Excel is showing some dialog window which blocks the application from running. Since it's a service running in noninteractive mode you are not able to see the dialog window.
I was wondering if there is a way to get the title of a dialog window to understand the root cause of it.
I tried using EnumDesktopWindows but it didnt help.
Platform: Windows 10.
Thanks

Freeze keyboard and mouse on Windows

I want to create a program for a computer lab. The computers in lab are running Windows 7 and are connected via LAN. The program should freeze keyboard and mouse when PC gets disconnected from LAN and also show a fullscreen message.
Currently I have created the first version of this program that works almost fine. It runs with startup. But the problem is that the users can kill it from Task Manager. I've tried running it as a windows service and it runs but cannot interact with desktop, so it cannot freeze the keyboard and mouse.
Any suggestions is appreciated. Thanks in advance.
So I finally solved it.
The reason my program could not interact with desktop is that it runs in Session 0.
This is because the Windows services run in session 0 and cannot directly interact with desktop. Here by interaction I mean receiving keyboard, mouse events and creating or accessing windows in user's desktop.
So I created a service that runs with SYSTEM account. It will create the "freezer process" in user's session. Also this process will run with SYSTEM account, so the normal user will not have privileges to kill.

Open a window on windows server in a user desktop from the SYSTEM level cmd

I came across an issue that I'm not entirely sure it is even possible.
I want to start a process (chrome browser for ex.) on a user desktop using a system level command prompt or powershell.
I tried many imitations such as runAs and -Credentials but they only open the process in the background "as" the user, not on the user's desktop. I want to actually RDP to the user's profile and see the browser open.
I'm aware there are risks of using system. This question is mostly on how to start a process on a specific user desktop rather than just appearing on task manager.
Edit to clarify the issue:
I'm using windows server which has several of users, all of them are users that i have their name and password.
On that server, i have a process running under SYSTEM which i need it to open a process with a UI (a browser for ex.) in one of the other users's desktop.
The user's session is open and runnign and i can RDP/VNC/SSH/whatever to it and open whatever i want but that is not what i need. I want to RDP to that user after the browser was opened and see that it is already opened.

Running Internet Explorer on LocalSystem Account on Windows 2012

I'm setting up Selenium Grid. We have a separate machine for each version of the browser.
Each node is started as System Service running on LocalSystem account with interactions with user desktop enabled.
This is required because Selenium Grid node starting Internet Explorer have problems making screenshots and transferring them when there was no interaction with user desktop.
As far as I was able to check, it looks like that interactions with user desktop for service are only allowed for LocalSystem account. Event changing manually flags in registry does not seem to works (as it was in windows 2008)
Everything is working fine except the test where I need to perform upload of the file. When there is an action to open dialog for file browsing, following popup appears
Is there any way to prevent this (creation of folder Desktop does not seem to work) ?
From the other hand, if there is a way to run service under different account with interactions with user desktop enabled, that would also be a case.
I would appreciate any help because I'm stuck with the problem
I have checked some additional solutions, like running selenium grid nodes via PowerShell Invoke-Command and this did not worked too.
I have managed to run selenium grid nodes as Windows Service with desktop interactions using 3rd party tool FireDaemon Pro Service Manager.
I didn't try this but PsExec -s should work
https://technet.microsoft.com/en-us/sysinternals/bb897553

Why application that require administrative privileges cannot run automatically on Windows startup(windows 7)?

I have a application(which runs on windows7 and requires run as administrative) that need to run automatically when windows starts up, so i added a registry key under "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" as usual, but my application won't startup automatically even the UAC dialog doesn't promtp, after search from google. I know i can use task scheduler to workaround this, but is there anyboday can tell me why the "run" registry way doesn't work? why the UAC dialog doesn't promtp? it is better if you can help to find a article from microsoft to explain this issue, many thanks in advance!
It is for making the machine usable as quick as possible after booting.
Microsoft Whitepaper: Developing Applications that Run at Logon on Windows Vista
When Windows starts, there is no user to show the UAC prompt to, so your process would have to be held up until an administrative user logs in.
The Task Scheduler is the right way to do what you want.

Resources