![]() "The Information Security Suppository" |
This site contains adult themes,
and may not be suitable for our younger viewers. Parental discretion is advised. |
Home | Add To Favorites | Print This Page | Close | |||||||
|
'<header> 'Copyright BaudBox ISG, 2001 'This code was made (originally) at Waffle House on 10+ cups of
coffee '</header> 'DO NOT MODIFY THIS HEADER IN ANY WAY, OR YOU WILL 'In non-legalese... Dim Dom, Usr, Ans, flag WScript.Echo "Enter the Lusers Domain: " Dom = WScript.StdIn.ReadLine() WScript.Echo "Enter LuserName: " Usr = WScript.StdIn.ReadLine() Set oUser = GetObject("WINNT://" & Dom & "/" & Usr & ",user") Dom = "" : Usr = "" WScript.Echo vbCrLf & "(R)estore or (D)isable this Luser: " Ans = WScript.StdIn.ReadLine() Select Case LCase(Ans) If CStr(LCase(oUser.AccountDisabled)) = "true" Then flag = oUser.Get("UserFlags") - 2 oUser.Put "UserFlags", flag oUser.SetInfo WScript.Echo oUser.Name " is Enabled." End If If CStr(LCase(oUser.IsAccountLocked)) = "true" Then flag = oUser.Get("UserFlags") - 16 oUser.Put "UserFlags", flag oUser.SetInfo WScript.Echo oUser.Name " is Unlocked." End If Case "d" If CStr(LCase(oUser.AccountDisabled)) = "false" Then flag = oUser.Get("UserFlags") + 2 oUser.Put "UserFlags", flag oUser.SetInfo WScript.Echo oUser.Name " is Disabled." End If If CStr(LCase(oUser.IsAccountLocked)) = "false" Then flag = oUser.Get("UserFlags") + 16 oUser.Put "UserFlags", flag oUser.SetInfo WScript.Echo oUser.Name " is Locked." End If End Select |