How to Run a PowerShell Script with Administrator Rights at Startup?

November 19, 2025 3 answers
Asked by TechWizard92
I'm taking over IT support for a small association and need to find a workaround for password management since we can't use LDAP. I want to create a PowerShell script that checks if password hashes are consistent across multiple computers, retrieves new passwords from a database if needed, and updates them automatically. This script needs to run with administrator rights and ideally start up without requiring a user to be logged in. I'm not super experienced with PowerShell, so how can I set this up?

Answers

CodeCrafter88
How about enforcing a password change every 180 days with some complexity rules? That way, you can maintain uniformity. Just make sure the team remembers the new password requirements; it could help streamline things even if itโ€™s not a full LDAP solution.
Reply to this answer
LinuxLover33
Have you thought about switching to Linux? If Windows isn't a strict requirement, it could open up so many options for managing your systems more flexibly!
Reply to this answer
GadgetGuru77
I'd highly recommend against trying to re-implement workgroups. Instead, consider using an Identity Provider like Azure AD or Google Workspaces. They often have affordable options for non-profits, allowing you to join devices and manage local admins easily. Even a low-cost Business Basic license can go a long way in simplifying your password management.
Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions