?
Solved

Local admin account - needs password never expires set via Script, GPO, or other

Posted on 2011-03-09
9
Medium Priority
?
1,591 Views
Last Modified: 2012-05-11
On our Windows 7 computer images, we create a local admin account for IT purposes when we need to login locally when that is our only option.

The problem is, that on the image, I forgot to check the "password never expires".  So now when we use the account months later, it prompts the tech to change the password.

I need to push this change out, where the "password never expires" gets checked, but not sure how.  Again, it's a local admin account on Windows 7 machines and I only need to apply this change only.

Also I may need to push out a change to reset the password back to your current standard, but the most important item is setting the local acocunt password to never expire to start with.
0
Comment
Question by:tdwhelp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
  • +2
9 Comments
 
LVL 3

Expert Comment

by:dsexton18
ID: 35087557
0
 
LVL 4

Assisted Solution

by:vnicolae
vnicolae earned 664 total points
ID: 35087724
You can create a Group Policy startup script that looks something like that:

Const ADS_UF_DONT_EXPIRE_PASSWD = &h10000
 
Set objUser = "your_username"
intUAC = objUser.Get("userAccountControl")
 
If ADS_UF_DONT_EXPIRE_PASSWD AND intUAC Then
    Wscript.Echo "Already enabled"
Else
    objUser.Put "userAccountControl", intUAC XOR _
        ADS_UF_DONT_EXPIRE_PASSWD
    objUser.SetInfo
    WScript.Echo "Password never expires is now enabled"
End If
0
 
LVL 3

Assisted Solution

by:dsexton18
dsexton18 earned 664 total points
ID: 35087751
Also take a look at the net user commands
http://support.microsoft.com/kb/251394
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 11

Accepted Solution

by:
TheGorby earned 672 total points
ID: 35087777
If for some reason that doesn't work, you could create this simple 1-line batch script and run it as a startup script on all machines. I would of course test this on one computer first.

Note that this will change the setting for all local users on the PC, but not domain users.

http://technet.microsoft.com/en-us/library/bb490698.aspx
NET ACCOUNTS /MAXPWAGE:UNLIMITED

Open in new window

0
 
LVL 4

Expert Comment

by:vnicolae
ID: 35087796
For the "net.exe" commands to work, they have to be executed with local admin privileges.
0
 
LVL 11

Expert Comment

by:TheGorby
ID: 35087860
Since startup scripts run as local system, admin privilages shouldn't be a problem.
0
 

Author Comment

by:tdwhelp
ID: 35139904
Thanks.  I will use the NET ACCOUNTS /MAXPWAGE:UNLIMTED method
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 35953955
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

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.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: I have always been a big fan of Windows but my liking towards it is slowly being eroded by the variety of other Applications that I encounter, when I browse the Web. Most of the software available is free and maybe Open Source too. …
Ever notice how you can't use a new drive in Windows without having Windows assigning a Disk Signature?  Ever have a signature collision problem (especially with Virtual Machines?)  This article is intended to help you understand what's going on and…
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question