Wednesday, December 31, 2008

47. Control User Logins by Hacking the Registry


To control logon options, run the Registry Editor [Hack #83] and go to theHKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersionWinlogon subkey, which contains a variety of logon settings (as well as some settingsnot having to do directly with logons).

Following are the most important values youcan edit to customize logons
DontDisplayLastUserName
This setting lets you control how the system logon dialog box is used. If this Stringvalue is present and set to 1, all users will have to enter both their username andpassword to log on.

If the value is 0, the name of the last user to log on will bedisplayed in the system logon dialog box.
DefaultUserNameThis String value contains the name of the last user who logged on. It will bedisplayed only if the DontDisplayLastUserName value is not present or is set to 0.LegalNoticeCaption and LegalNoticeText// Already discussed
PasswordExpiryWarningThis DWORD value lets you display a warning message to users a certain number ofdays before their passwords are set to expire. It lets you determine how many daysahead of time the warning should be issued. To edit the value, click the decimalbutton and enter the number of days.
ShutdownWithoutLogonThis String value enables or disables a button on the XP logon dialog box that lets thesystem shut down. A value of 1 enables the button (so that it is shown); a value of 0disables the button (so that it is not shown).


ShellIt determines the shellthe user interfacethat will be used by XP. The default isExplorer.exe, but it can be another shell as wellfor example, the Program Managerfrom older Windows versions. Type in the name of the program; for example,Progman.exe for the Program Manager, or Taskman.exe for the Task Manager.
AutoRestartShellThis DWORD value doesn't have to do with logons either, but it's another good one toknow. It sets whether to automatically restart the Windows shell if the shell crashes. A value of 1 automatically restarts the shell.

A value of 0 tells XP not to restart the shell,forcing you to log off and then back on again to restart it.

1 Comment:

Anonymous said...

This is cool.
thank you for sharing your great tips.
See you around.