Hacking Windows XP
by Preston GrallaControl User Logins by Hacking the Registry
![]()
![]()
Make better use of the XP login screen.
If your system contains more than one user account, or if you've set up XP to require logins, you'll have to log in to XP before you can begin to use it. But you needn't stay with the default XP login rules; you can use a single Registry key to customize how you log in. For example, you can display custom text before login, and you can remind anyone with an account on the PC to change their password a certain number of days prior to the password's expiration.
|
Related Reading
Windows XP Hacks |
To control logon options, run the Registry Editor [Hack #83] and go to the
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows
NT\CurrentVersion Winlogon subkey, which contains a variety
of logon settings (as well as some settings not having to do directly
with logons). Following are the most important values you can 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 to1, all users will have to enter both their username and password to log on. If the value is0, the name of the last user to log on will be displayed in the system logon dialog box. DefaultUserName-
This
Stringvalue contains the name of the last user who logged on. It will be displayed only if theDontDisplayLastUserNamevalue is not present or is set to0. LegalNoticeCaption-
This
Stringvalue, used in concert with theLegalNoticeTextvalue, displays a dialog box prior to logon that contains any text you want to display. (The text doesn't have to be a legal notice, but this value is often used for that purpose.) The box has a title and text. TheLegalNoticeCaptionvalue will be the dialog box's title. LegalNoticeText-
This
Stringvalue, used in concert withLegalNoticeCaption, contains the text that you want to be displayed inside a dialog box displayed prior to logon. PasswordExpiryWarning-
This
DWORDvalue lets you display a warning message to users a certain number of days before their passwords are set to expire. It lets you determine how many days ahead of time the warning should be issued. To edit the value, click the decimal button and enter the number of days. ShutdownWithoutLogon-
This
Stringvalue enables or disables a button on the XP logon dialog box that lets the system shut down. A value of1enables the button (so that it is shown); a value of0disables the button (so that it is not shown). Shell-
This
Stringvalue really doesn't have to do with logons, but it's one you should know about. It determines the shell—the user interface—that will be used by XP. The default isExplorer.exe, but it can be another shell as well—for example, the Program Manager from older Windows versions. Type in the name of the program; for example,Progman.exefor the Program Manager, orTaskman.exefor the Task Manager. AutoRestartShell-
This
DWORDvalue doesn't have to do with logons either, but it's another good one to know. It sets whether to automatically restart the Windows shell if the shell crashes. A value of1automatically restarts the shell. A value of0tells XP not to restart the shell, forcing you to log off and then back on again to restart it.
Now that your system's startup and shutdown are under control, let's move on to the user interface.

