strongm
I assume you are talking about LogonUser api? As a general question I ask, is it correct that we (as a forum) should show ways in which NT security (such as it is) can be compromised?
Having watched your "sneaky" tricks in code , with much interest and admiration (crawl crawl

) I am sure that you could (and probably have!) write a password cracking engine. Again I am sure that both
Syerston and
CraigSander have honest intentions, but can you guarantee that
every other user or visitor to this forum is as honest?
If you do feel it appropriate to show how
Syerston and
CraigSander question can be answered then please do so. I personally feel that
johnwm (I think) posted, "persistent attempts to bypass security should be red flagged"
I am sure that you will respond with a valid argument as to why an answer should be posted: I look forward to reading it
Syerston and
CraigSander
I have thought of another solution that may solve your requirements, for NT and w2k at least. I admit it is a bit brutal but here goes
Code:
'API declaration
Private Declare Function LockWorkStation Lib "user32.dll" () As Long
'put the following in form load or whatever
' don't forget that the lock doesn't "halt" program execution
Private Sub Command1_Click()
Dim lRes As Long
lRes = LockWorkStation() ' Brings up standard Locked screen
'user will only be able to bypass wit their password
'and admin rights of course
If lRes = 0 Then
MsgBox "unable to lock", , "Error"
End If
Hope that helps
Matt