Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources
Viewing all articles
Browse latest Browse all 8583

Interactive logon: Prompt user to change password before expiration

$
0
0

Hello,

I want to configure interactive logon settings for stand-alone computer by PS v2 on Windows7.

I set local settings a below:

"DontDisplayLockedUserId", # Display user information when the session is locked: Do not display user information --> 3

"DontDisplayLastUserName", # Do not display last user name: Enabled --> 1

"DisableCAD", # Do not require CTRL+ALT+DEL: Disabled --> 0

"LegalNoticeText", # Message text for users attempting to log on: XXX --> XXX

"LegalNoticeCaption", # Message title for users attempting to log on: XXX --> XXX

"cachedlogonscount", # Number of previous logons to cache (in case domain controller is not available): 0 logons --> 0

"passwordexpirywarning", # Prompt user to change password before expiration: 14 days --> e

"ForceUnlockLogon", # Require Domain Controller authentication to unlock: Disabled --> 0

"scforceoption", # Require smart card: Disabled  --> 0

"scremoveoption" # Smart card removal behavior: Lock Workstation --> 1

But "HKLM:\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\passwordexpirywarning" doesn't work. It doesn't set "Prompt user to change password before expiration" as 14 days.
Do you have other suggestions?

Viewing all articles
Browse latest Browse all 8583