How do I start a GUI application without a login session?

My goal is to log out of the current session and then delete the current local user profile. And I have a service to delete the profile already.

My problem is that the user has no idea about the background service and who can shutdown the machine again or log in too early.

The idea is that the service will show some kind of popup and it will not display "Welcome to Windows" until the background job has finished.

I have read a few tricks for running a GUI application without logging in, but I cannot find how to do it.

How do I do this in Windows XP and Vista?

Another idea from my boss is that "Shutdown and install windows update", but run our applications, not the patch installer. How do I set my application hooks at this point?

+1


source to share


3 answers


I think if you are running on a system other than Vista you will want to replace the DLL GINA. This will give you the right hooks in the login process to get your job done.

In Vista you simply won't be able to do this because GINA has been replaced with credential providers that are not prompted when the user logs off.



Also, I don't see in your question on what to do if someone logs in through Terminal Services or through another call to LogonUser. Deleting a profile when a user is logged out is a bad idea because they can be registered more than once, so you need to take that into account.

+1


source


Could you add users to the Guests group? I believe this stops the profile from traversing outside of their session, although it might be something in poledit.



0


source


I've never tried anything like this, but I think you should be able to place your popup app in your logo script that you define in your group policy (use gpedit.msc).

I would be interested to hear if this works for you for my own edification, so let us know.

0


source







All Articles