Re: programmatically log on / logg off user



1 & 2 will work with the console session too.

You may be able to get away with not writing a GINA if you license a special
dll that was meant for biometrics on XP. It's mentioned in the following
article about fast user switching.
http://msdn2.microsoft.com/en-us/library/ms997634.aspx
You can e-mail fusqa _at_ microsoft.com for more information.

On Vista, a credential provider is the only option.

--
This posting is provided "AS IS" with no warranties, and confers no rights.
Eric Perlin [MSFT]


"Stephan Steiner" wrote:

Eric

Thanks for the information.

How would 1) and 2) translate to a user logged in via the local system
console?

As far as my number 3 goes, while security isn't a concern (those are
virtual machines and only admins can connect to the local console via
management software), autologon would be problematic if I find if the user
is already logged in via TS (so when you get to the console all you have to
do is enter your password and you're in again) and in that case I wouldn't
like to log in again. And since login via TS requires a password, I'll
always get to the login screen when connecting to the console again. Is
there any useful way of just sending the password to the login screen? I
figure writing my own GINA provider would not only be time consuming, but
also very complex as I'd like to retain the standard logon functionality
(via console and terminal services) but just like to have a way to
programmatically log on a user on the console.

Regards
Stephan

"Eric Perlin [MSFT]" <EricPerlinMSFT@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in
message news:5DAA1588-78D0-4326-9246-56D4BC156F38@xxxxxxxxxxxxxxxx
1/ Use WTSEnumerateSessions to get the list of existing TS sessions.
You can query more info about the user logged on in that session
afterwards
using WTSQuerySessionInformation
2/ Use WTSLogoffSession to target a specific session.
Never ever use ExitWindows(Ex) from a service.
3/ That part could be trickier. If security is not a concern, you could
setup autologon before step 2. Otherwise, I'm afraid you'll have to
develop a
small credential provider (if the target OS is Vista), or some form of
GINA
for previous OSes.

I hope it will be obvious for the user that was logged off that another
user
is now logged on...
--
This posting is provided "AS IS" with no warranties, and confers no
rights.
Eric Perlin [MSFT]



.



Relevant Pages

  • Re: WTSQuerySessionInformation
    ... Session zero has stopped being `the console session` starting from Vista. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: WTSQuerySessionInformation
    ... Yes we agree that if the console is in the middle of changing ownership then it's not clear what I should do. ... the Terminal Services console session. ... then either I'm running on the physical console and a normal user or other ... This page doesn't single out Windows Vista. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: 2.4.10-r1 MTRR bug
    ... > console is frozen from further output (but it doesn't prevent the full ... > Linux/X session, but not able to regain any virtual console session.) ... 0000:00:02.7 Multimedia audio controller: Silicon Integrated Systems ...
    (Linux-Kernel)
  • Re: Remote Desktop to XP Pro Problems
    ... "console" shouldn't matter much one way or another (Vista and Longhorn ... reserve the console session, session 0, for services; ... behavior of RDP sessions set in the Terminal Services portion of GP? ... There are numerous other ways to shutdown ...
    (microsoft.public.windows.terminal_services)
  • Re: OSA-ICC console question
    ... session should do. ... Subject: OSA-ICC console question ... For IBM-MAIN subscribe / signoff / archive access instructions, ... send email to listserv@xxxxxxxxxxx with the message: GET IBM-MAIN INFO ...
    (bit.listserv.ibm-main)

Quantcast