Bring laptop in for maintenance (Build for windows 7 32/64)
Please Explain…
OK, So at work I was asked to devise a way to make users return their laptops to us in IT for maintenance reviews. Now if anyone else has tried to get users to return hardware of maintenance on their own, it’s impossible…
So I have created a script that disables user logins after a X number of days. They also receive warnings after a different X number of days. In my environment the PC’s are not connected to the domain. they run Windows7 32-bit.
I would like to know if I could get this to work on a domain system, but I’m going to say no for now.. No user to lockout, but you could amend to corrupt some type of file.
Basicly, I have created a services that runs a script to check the current date is not grater than or equal to the date of lockout. The script then locks specific user accounts if the date is grater than or equal to today’s date. If it’s not grater than or equal to today’s date then it checks if the notify period is grater than or equal to today’s date. Again, if this is grater than or equal to today’s date it will start to display messages to the user. The background login wallpaper will also change to a warning. Once the lockout date as been reached or passed, the lockout action is committed and the users cannot login. The wallpaper on the login screen changes to access denied. Now the only user who can use the computer is the local administrator account.
So now they bring the PC back to you because it’s now useless to them in it’s current state. When you login it runs the notify.bat as it does when any user logs in, but instead or it’s normal action of displaying a pop-up message, it will reset the restriction an set the schedule back to X days in the future. This is because you logged in as administrator, not because you are an administrator of the PC.
This service will lock administrator accounts as well, it just works on username. So even if the user is a local admin, this will still work. Although they could go into the Win7Checker folder and edit the dates so to stop lockout. So a normal user account for users is best. The service runs as an administrator so can make changes that the current your can’t make.
There is also a grace of one extra login after expiry. this is to allow access if the PC have been off for months. It also allows updates of the wallpaper to take place.
Install Instructions…. — DOWNLOAD SOFTWARE
1. Download 2. Extract files to a temp folder 3. Run install.bat as an administrator user with elevated privileges.
NOTE: When installing on x64 OS take the (x86) off the Program files on install of the RKTools.exe
5. Navigate to the folder "c:\windows\system32\Win7Checker\" 6. Right Click run.bat and click properties 7. Under the General Tab, Click Unlock 8. Repeat steps 6 & 7 for notify.bat & doff.exe in the same folder. 9. Reboot And COMPLETE 10. Use the .psd (Adobe Photoshop 3 document) to create your own JPG messages..
NOTE: the JPG files have to be less than 256kb in size otherwise windows will not use it.
Files Explained…
Below is a basic idea of what each files does.
BackgroundDefault.jpg - Normal background wallpaper. BackgroundDefault2.jpg - Warning Wallpaper. BackgroundDefault3.jpg - Access Denied Wallpaper. doff.exe - Required for processing the dates. notify.bat - Display messages. Admin user login does a reset. run.bat - service run script. Main processing script date.txt - This holds the date of expiry notify.txt - This holds the date of starting to notify user. today.txt - This holds the current date for processing. bginfo.txt - This holds a readable date of expiry, I use BGInfo to put this on the desktop wallpaper.