• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 458
  • Last Modified:

Command Line way to Lock the Users out of changing the system time

We have an issue in our labs and classrooms where we need to disable the ability to change the time on the workstations.  I know I can do this from the GPO under:
Computer Configuration\Windows Settings\Security Settings\Local Policies\User Rights Assignment

"Change the system time" Setting
but this only works if you are physically logged into the computer.

Is there a way to do this via command line through our desktop management system (Altiris) since these workstations are not part of the domain.
1 Solution
you have two option...

1. regular users do not have the rights to change system time so you could change the users permissions back to standard user...

2. Start>run>type gpedit.msc

The setting is located under Computer Configuration, Windows Settings, Local Policies, User Rights Assignment, "Change the system time".
3. Using cacls from a CMD line to deny access to the applet.....

cacls c:\windows\system32\timedate.cpl /d USERNAME
rmusickAuthor Commented:
Needs to be applied all users on the workstations Except the administrator..
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

The command line tool "ntrights.exe" from the 2k/2k3 resource kit will let you set user-rights. If your software allows you to run a command remotely, you could use it to revoke the right to change the clock from a specific group of users across all your computers.

Something like this should do the trick:  ntrights.exe -r SeSystemTimePrivilege -u "Users"

Hope this helps.
rmusickAuthor Commented:
Worked Great!  It did exactly what I wanted. Thanks
Glad I could help.

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now