MSFN Forum: Can i set "Password never expires" from nLite somewhere? - MSFN Forum

Jump to content



If you are having issues with Windows after removing components and have come to ask for help, please attach (not paste) your Last Session.ini file to your post to facilitate quicker assistance.
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Can i set "Password never expires" from nLite somewhere? I'm getting that annoying prompt doing bootup... Rate Topic: -----

#1 User is offline   Martin H 

  • Friend of MSFN
  • PipPipPipPipPip
  • Group: Members
  • Posts: 802
  • Joined: 24-November 06
  • OS:none specified

Posted 08 May 2007 - 02:00 PM

Is there a setting in nLite which will make it so that the password never expires ? I have an admin acount without password, an user account with admin rights also without password and then a guest account. Then after some time, then i get a prompt about the password for my user acount(with admin rights) is expirering soon. I know that i can change it after the install from Windows, or find the needed reg key(s) that controls this setting and then add the reg key(s) to my other reg tweaks which i run from RunOnceEx(those tweaks that nLite dosen't support i.e. disable all Windows sounds/disable delete confirmation dialog etc.), but i would first just check if it was possible to controll from nLite ?

Thank's in advance.

Martin.


#2 User is offline   DonDamm 

  • Member
  • PipPip
  • Group: Members
  • Posts: 284
  • Joined: 24-May 05

Posted 08 May 2007 - 06:17 PM

Are you doing an unattended install? No matter, you could still run a cmd file at minute 13 to set up a user. You'd need to create a file, I call mine useraccounts.cmd and place it in the $oem$ folder which is in your root. Here is an example of one I've used before:

useraccounts.cmd
net user Mickey mouse /add
net localgroup Administrators Mickey /add
net accounts /maxpwage:unlimited
REGEDIT /S autologon.reg
EXIT


Note that it creates the user (Mickey) and the password (mouse), puts him in group (here the Administrators Group), and then sets the maximum password age to unlimited which is the same as never expiring. The last item is part of the batch file instructing the merging of a reg file into the registry. That file is merely a command to automatically log the user on X number of times to keep an unattended installation going through reboots. If you want it, the file sits in the same folder and the code looks like:

autologon.reg
Windows Registry Editor Version 5.00 

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
"DefaultUserName"="Mickey"
"DefaultPassword"="mouse"
"AutoAdminLogon"="2"


Now I know that this isn't in nLite, but it doesn't have to be.

You mentioned you'd set it up with no password. I know that is "easier" on the face of it, but you need a password to connect a network for one thing, and secondly, you can always use TweakUI to autologon (or set that in the registry yourself), so at the very least you should password the Administrator account. I don't know why MS allow you to have it not passworded, but that's their problem. You shouldn't make it yours. However, you could still set no password above and set maxpwage:unlimited.

Enjoy! :^)

This post has been edited by DonDamm: 08 May 2007 - 06:19 PM


#3 User is offline   Martin H 

  • Friend of MSFN
  • PipPipPipPipPip
  • Group: Members
  • Posts: 802
  • Joined: 24-November 06
  • OS:none specified

Posted 09 May 2007 - 05:18 AM

Hi DonDamm :)

Thank you very much for your kind help, i really appreciate it :) Sorry about not providing enough information about my process, i completely forgot about that :)

I'm using nLite to integrate Xables XUDPack and make the disc unattended/tweaked and since nLite also supports user creation, then i'm also doing that from inside nLite, instead of from batch files. I hear what you're saying about using passwords, but personally i would rather avoid it, as i have no use of it in my situation. I have just looked again through nLite's user creation dialog and i'm now certain that there isn't an option for defining the password to not expire, but thank's to you then that dosen't matter since i can then just add 'net accounts /maxpwage:unlimited' to my 'cleanup.cmd' file which i run from 'RunOnceEx.cmd' after all my apps have been installed and configured. I am however thinking about something though... When i run 'net accounts /maxpwage:unlimited' from the command line, then i can see that it's working correctly by running 'net accounts' and checking that the passwords maximum age is defined to 'unlimited' now, but when i then go into 'Computer Management' and check the properties of my account, then the checkbox in front of 'Password never expires' isn't checked ? I also rebooted and checked again and still it wasen't checked ? Could you(or anyone else which knows it :)) please tell me if this is normal behaviour and that i shouldn't worry about it ?

Thank's in advance.

CU, Martin.

#4 User is offline   rehbar 

  • End_user2000
  • PipPip
  • Group: Members
  • Posts: 264
  • Joined: 01-March 06
  • OS:none specified
  • Country: Country Flag

Posted 09 May 2007 - 10:51 AM

simply use netuset tool and add command in nlite.cm_

#5 User is offline   DonDamm 

  • Member
  • PipPip
  • Group: Members
  • Posts: 284
  • Joined: 24-May 05

Posted 09 May 2007 - 11:19 AM

Well, I checked and you are right. However, I would tend to trust the command line when it says the command completed successfully. Why it doesn't show in the GUI I don't know. One way to test it is to try one of the other commands like limit it to 2 days and then put your clock forward, or try /minpwage: and set it to maybe 5 days and then try to change the password after. Either should give us a clue as to if it's working.

Also, note that just because the box isn't checked, does not mean it isn't in force! That's an MS thing. :^)

I'm sorry, but I'm not familiar with the netuset tool. What is that? Where do you find it? How is it implemented?

#6 User is offline   Martin H 

  • Friend of MSFN
  • PipPipPipPipPip
  • Group: Members
  • Posts: 802
  • Joined: 24-November 06
  • OS:none specified

Posted 09 May 2007 - 02:21 PM

Many thank's for all your help, DonDamm - i really appreciate it :)

CU, Martin.

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy