THE OTHER IMPORTANT PLAYERS

We've covered most of the underlying basics with X connections and keeping those connections relatively secure. Now let's briefly review some of the other important players in the workings of the X Window System.

Xdm

Xdm is the X Display Manager. It can manage a number of different X displays on the localhost or other remote X servers. Unix systems that automatically boot up into X are usually running xdm to handle starting X servers and sessions. It asks you for a username and password, and in turn , it provides you with a sessionjust as a terminal login might do. It handles much of the previously mentioned X authentication details of generating Xauthority entries transparently as you log in.

Xdm uses X Display Manager Control Protocol (XDMCP), which runs on UDP port 177. It listens for queries from X servers that are looking for a display manager. This can allow remote X servers ( specifically X terminals that have X server software and nothing more) to query for hosts running xdm that can manage X sessions for them. This basically means that a box running xdm is telling other X servers, "Hey, you can start an X login session on me and use all of my X clients and software and display them back to yourself." It's kind of like using telnet to log into a box, except with graphics.

Running XDMCP on your network is inherently insecure and isn't suggested unless you're on a trusted LAN. If you like the ability of having an X login to your local server, it's still okay to use xdm. Just make sure you're not listening for XDMCP queries and offering up your xdm services for other X servers unless you intend to do so. See the xdm man pages for more details on configuring xdm securely.

Note 

Since XDMCP uses UDP, XDMCP traffic cannot be tunneled through SSH.

Xinit and Startx

Xinit initializes the X Window System and starts the initial clients. The behavior of this program is extremely configurable and is usually run from a front-end script called startx. By default, xinit brings up the windowing system (with the basic functionality mentioned at the beginning of this chapter) and runs the programs listed in the user 's ~/.xinitrc file. Failing that, it simply runs xterm .

Xinit can be configured so that it runs your favorite window manager (KDE, Gnome, and so on) by default. Xinit also lets you configure things like window geometry, screen colors, and more.

Startx is a front end to xinit that hides some of the more gruesome details in starting up and shutting down an X Window session. It handles searching through all the different server and client configuration files (xinitrc and xserverrc) in all the usual locations and constructs the xinit command line for you.

Whereas xdm is an automatic way to start up and manage X sessions at system boot, xinit and startx are manual ways of starting up X sessions on demand.

Xserver

Xserver is the actual program started by xdm when someone logs in or by xinit when someone issues the startx command. Xserver receives its configuration options as arguments from the program that starts it. Other than managing the actual X communication, the Xserver itself handles the network connections, authentication, screen management, font management, XDMCP queries, and many other things. See the Xserver man pages for more details.

Using X on Windows and Mac OS X

Microsoft Windows systems do not support the X Window System without third-party software. The easiest way to obtain X compatibility is to use Cygwin, which is covered in Chapter 3.

Mac OS X supports the X Window System (OS X refers to its version, 10, not an X server). You will need the X11.app from the installation CD or from Apple's web site. Running an X server on OS X is much like any other Unix-based system. Applications won't be as tightly integrated with the core OS X interface so command-key shortcuts likely won't work. X11 forwarding over SSH is possible and many of the graphical tools described in this book, like Ethereal in Chapter 16, run without problem under Mac OS X's system.

You have all of the normal X commands like xhost and xauth under Mac OS X; however, the system terminal will not have the correct path to these commands in its default PATH environment variable. By default, the X11.app launches an xterm with the correct path settings so all you need to do is type xhost or xauth to access these commands. Otherwise, add /usr/X11R6/bin to your path:

 [Paris:~] mike% set path=($path /usr/X11R6/bin) 


Anti-Hacker Tool Kit
Anti-Hacker Tool Kit, Third Edition
ISBN: 0072262877
EAN: 2147483647
Year: 2006
Pages: 175

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net