How to unlock windows programmatically

I would like to make use of my old mirror (by violet) which allow to trigger events when you put and take a rfid tag on/off a rfid tag reader. Using LibMirror I can program events in c# which is quite convienent.

My idea is to lock and unlock my station when I take and put the rfid tag on the mirror.

It is quite easy to lock the station thanks to 2, unlocking however seems more difficult.

Several posts 3,4 on SO show that's difficult but I would like to have an definitive answer.

I must precise that I am not interested in any consideration of security, this much more for the sake of doing it.

EDIT : mirware from violet used to allow this, that's why I am convinced this is possible.

Any clue would be appreciated.


ANSWERS:


No, this is not possible. Is that definitive enough for you?

Whether you're concerned with security or not, the Windows team is and absolutely must be. Consequently, there is no API provided to unlock a secured desktop.

It wouldn't make sense anyway—you have to enter a password in order to unlock the workstation, and how is a function call going to enter a password?

UI automation or whatever some ingenious hacker might cook up isn't going to work because the secure attention sequence (Ctrl+Alt+Del) is required to prevent people from doing precisely this.

The only solution would be to completely replace the Windows security system. On Windows XP, you'd do that by writing a new GINA DLL to replace the standard msgina.dll. Things got slightly more complicated in Windows Vista, where GINA was replaced with the new Credential Providers. You might find this article useful if you're interested in pursuing such a route.



 MORE:


 ? How many partitions should we use in Redis? As the data become larger, how can i rearrange the partition?
 ? Gitlab, Permission denied (publickey), version 6-4 stable
 ? Gitlab returning remote: You do not have permissions to do this. while performing scripted git push
 ? Mirroring from Gitlab to Github
 ? Permission denied (publickey) on capifony deployment from windows with remote host gitlab
 ? Unable to connect to Gitlab Container on Custom Port via SSH
 ? Centos 6.8 - Updates repo issues
 ? Centos 6.8 - Updates repo issues
 ? Centos 6.8 - Updates repo issues
 ? installing multiple gcc on centOS 7