When the system has booted and starts the loginwindow
program, the system displays the user login screen, as shown in Figure 5-3. You won’t see the login screen, however, if you’ve enabled the auto-login preference in the Accounts preference panel. With auto-login turned on, the selected user is automatically logged into her user account as the system starts up.
When you log in, the following things happen:
Your environment, including preferences, environment variables, and Keychains, are loaded.
The SystemUIServer
is launched and handles the menu bar and menu extras (those little applets up in the upper-right area of the screen).
The pasteboard server (pbs
) is launched.
The mouse, keyboard, sound, and display are configured according to your preferences.
Any user-defined login items are processed.
The Dock and Finder are started.
Once the Finder is started and your login items
have completed, login is finished and you can use your Mac. After a user has logged in, the loginwindow
process has the following responsibilities:
If the Finder or Dock processes die for some reason, they are automatically restarted by the loginwindow
process. And if, for some reason, the loginwindow
process itself dies, launchd
restarts it so the login window is displayed and the system isn’t left in an unusable state.
While the loginwindow
process manages the login window and the process of logging a user into the machine, it doesn’t actually perform the authentication of the user’s credentials (usually a password). Instead, it passes off authentication to Directory Services. Only if a user’s authentication credentials are accepted by Directory Services will the login process continue. Otherwise, the login window shakes—resembling somebody shaking her head and saying no—and won’t log the user into the system until the user’s password is entered correctly. Directory Services are covered in depth in Chapter 7.
After they log in, users can specify applications to launch automatically by using the Accounts preference panel. A list of these applications can be found and configured through the Startup Items tab of the Accounts preference panel, as shown in Figure 5-4. For example, in the figure, you can see that both Address Book and Mail are set to start up automatically on login. You can put pretty much any application you want into this list.
If you want an application to run but not show up in your Dock, click the Hide button next to the item. Many support applications, such as the Palm Desktop HotSync manager, will run hidden using the functionality provided by this panel.
You can customize the login window through the Login Options tab of the Accounts System Preference panel, shown in Figure 5-5. The Login Options pane lets administrators define how the list of users are displayed in the login window, among other
options such as whether or not the Restart, Sleep, and Shut Down buttons are displayed, and whether or not password hints will be displayed if a user fails to correctly enter his password three times in a row.
Tiger brings two important enhancements to the login window for international and handicapped users. International users can enable the Input menu on the login window, allowing easy language selection during login. For users with visual impairment, Mac OS X offers the VoiceOver feature for use at login. When enabled, VoiceOver describes aloud the elements of the login window, including the username and password fields.
This panel also lets you enable Fast User Switching , a feature that lets you have multiple users logged in at the same time. When you activate this, the Accounts menu shows up in the upper-right corner of the screen, to the left of the Spotlight icon. Depending on what you set on the Login Options screen preference panel, this menu bar item appears as either an icon, or with users’ short or full names. You can click to the item to reveal a menu that allows you to log in as another user, to present the login panel, or to access Account Preferences, as shown in Figure 5-6.
When another user logs in, either through the login window or Fast User Switching, the same login process described in this section occurs.