diff options
-rw-r--r-- | auth.c | 172 | ||||
-rw-r--r-- | config/xdm-config.cpp | 3 | ||||
-rw-r--r-- | daemon.c | 143 | ||||
-rw-r--r-- | dm.c | 18 | ||||
-rw-r--r-- | genauth.c | 28 | ||||
-rw-r--r-- | greeter/verify.c | 17 | ||||
-rw-r--r-- | policy.c | 25 | ||||
-rw-r--r-- | session.c | 4 | ||||
-rw-r--r-- | xdm.man.cpp | 47 | ||||
-rw-r--r-- | xdmcp.c | 4 |
10 files changed, 250 insertions, 211 deletions
@@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/auth.c,v 3.31 2003/12/02 22:55:05 herrb Exp $ */ +/* $XFree86: xc/programs/xdm/auth.c,v 3.33 2004/01/16 00:03:54 herrb Exp $ */ /* * xdm - display manager daemon @@ -281,7 +281,7 @@ static char authdir1[] = "authdir"; static char authdir2[] = "authfiles"; static int -MakeServerAuthFile (struct display *d) +MakeServerAuthFile (struct display *d, FILE ** file) { int len; #if defined(SYSV) && !defined(SVR4) @@ -291,52 +291,74 @@ MakeServerAuthFile (struct display *d) #endif char cleanname[NAMELEN]; int r; +#ifdef HAS_MKSTEMP + int fd; +#endif struct stat statb; - if (d->clientAuthFile && *d->clientAuthFile) - len = strlen (d->clientAuthFile) + 1; - else - { - CleanUpFileName (d->name, cleanname, NAMELEN - 8); - len = strlen (authDir) + strlen (authdir1) + strlen (authdir2) - + strlen (cleanname) + 14; - } - if (d->authFile) - free (d->authFile); - d->authFile = malloc ((unsigned) len); - if (!d->authFile) - return FALSE; - if (d->clientAuthFile && *d->clientAuthFile) - strcpy (d->authFile, d->clientAuthFile); - else - { - sprintf (d->authFile, "%s/%s", authDir, authdir1); - r = stat(d->authFile, &statb); - if (r == 0) { - if (statb.st_uid != 0) - (void) chown(d->authFile, 0, statb.st_gid); - if ((statb.st_mode & 0077) != 0) - (void) chmod(d->authFile, statb.st_mode & 0700); - } else { - if (errno == ENOENT) - r = mkdir(d->authFile, 0700); - if (r < 0) { + *file = NULL; + + if (!d->authFile) { + if (d->clientAuthFile && *d->clientAuthFile) + len = strlen (d->clientAuthFile) + 1; + else + { + CleanUpFileName (d->name, cleanname, NAMELEN - 8); + len = strlen (authDir) + strlen (authdir1) + strlen (authdir2) + + strlen (cleanname) + 14; + } + d->authFile = malloc (len); + if (!d->authFile) + return FALSE; + if (d->clientAuthFile && *d->clientAuthFile) + strcpy (d->authFile, d->clientAuthFile); + else + { + sprintf (d->authFile, "%s/%s", authDir, authdir1); + r = stat(d->authFile, &statb); + if (r == 0) { + if (statb.st_uid != 0) + (void) chown(d->authFile, 0, statb.st_gid); + if ((statb.st_mode & 0077) != 0) + (void) chmod(d->authFile, statb.st_mode & 0700); + } else { + if (errno == ENOENT) + r = mkdir(d->authFile, 0700); + if (r < 0) { + free (d->authFile); + d->authFile = NULL; + return FALSE; + } + } + sprintf (d->authFile, "%s/%s/%s", authDir, authdir1, authdir2); + r = mkdir(d->authFile, 0700); + if (r < 0 && errno != EEXIST) { free (d->authFile); d->authFile = NULL; return FALSE; } + sprintf (d->authFile, "%s/%s/%s/A%s-XXXXXX", + authDir, authdir1, authdir2, cleanname); +#ifdef HAS_MKSTEMP + fd = mkstemp (d->authFile); + if (fd < 0) { + free (d->authFile); + d->authFile = NULL; + return FALSE; + } + + *file = fdopen(fd, "w"); + if (!*file) + (void) close (fd); + return TRUE; +#else + (void) mktemp (d->authFile); +#endif } - sprintf (d->authFile, "%s/%s/%s", authDir, authdir1, authdir2); - r = mkdir(d->authFile, 0700); - if (r < 0 && errno != EEXIST) { - free (d->authFile); - d->authFile = NULL; - return FALSE; - } - sprintf (d->authFile, "%s/%s/%s/A%s-XXXXXX", - authDir, authdir1, authdir2, cleanname); - (void) mktemp (d->authFile); } + + (void) unlink (d->authFile); + *file = fopen (d->authFile, "w"); return TRUE; } @@ -352,11 +374,10 @@ SaveServerAuthorizations ( int i; mask = umask (0077); - if (!d->authFile && !MakeServerAuthFile (d)) - return FALSE; - (void) unlink (d->authFile); - auth_file = fopen (d->authFile, "w"); + ret = MakeServerAuthFile(d, &auth_file); umask (mask); + if (!ret) + return FALSE; if (!auth_file) { Debug ("Can't creat auth file %s\n", d->authFile); LogError ("Cannot open server authorization file %s\n", d->authFile); @@ -483,7 +504,8 @@ openFiles (char *name, char *new_name, FILE **oldp, FILE **newp) Debug ("can't open new file %s\n", new_name); return 0; } - *oldp = fopen (name, "r"); + if (!*oldp) + *oldp = fopen (name, "r"); Debug ("opens succeeded %s %s\n", name, new_name); return 1; } @@ -1205,7 +1227,7 @@ writeRemoteAuth (FILE *file, Xauth *auth, XdmcpNetaddr peer, int peerlen, char * void SetUserAuthorization (struct display *d, struct verify_info *verify) { - FILE *old, *new; + FILE *old = NULL, *new; char home_name[1024], backup_name[1024], new_name[1024]; char *name = 0; char *home; @@ -1217,6 +1239,9 @@ SetUserAuthorization (struct display *d, struct verify_info *verify) int i; int magicCookie; int data_len; +#ifdef HAS_MKSTEMP + int fd; +#endif Debug ("SetUserAuthorization\n"); auths = d->authorizations; @@ -1229,29 +1254,61 @@ SetUserAuthorization (struct display *d, struct verify_info *verify) lockStatus = XauLockAuth (home_name, 1, 2, 10); Debug ("Lock is %d\n", lockStatus); if (lockStatus == LOCK_SUCCESS) { - if (openFiles (home_name, new_name, &old, &new)) { + if (openFiles (home_name, new_name, &old, &new) + && (old != NULL) && (new != NULL)) { name = home_name; setenv = 0; } else { Debug ("openFiles failed\n"); XauUnlockAuth (home_name); lockStatus = LOCK_ERROR; + if (old != NULL) { + (void) fclose (old); + old = NULL; + } + if (new != NULL) + (void) fclose (new); } } } if (lockStatus != LOCK_SUCCESS) { - snprintf (backup_name, sizeof(backup_name), "%s/.XauthXXXXXX", d->userAuthDir); + snprintf (backup_name, sizeof(backup_name), + "%s/.XauthXXXXXX", d->userAuthDir); +#ifdef HAS_MKSTEMP + fd = mkstemp (backup_name); + if (fd >= 0) { + old = fdopen (fd, "r"); + if (old == NULL) + (void) close(fd); + } + + if (old != NULL) +#else (void) mktemp (backup_name); - lockStatus = XauLockAuth (backup_name, 1, 2, 10); - Debug ("backup lock is %d\n", lockStatus); - if (lockStatus == LOCK_SUCCESS) { - if (openFiles (backup_name, new_name, &old, &new)) { - name = backup_name; - setenv = 1; +#endif + { + lockStatus = XauLockAuth (backup_name, 1, 2, 10); + Debug ("backup lock is %d\n", lockStatus); + if (lockStatus == LOCK_SUCCESS) { + if (openFiles (backup_name, new_name, &old, &new) + && (old != NULL) && (new != NULL)) { + name = backup_name; + setenv = 1; + } else { + XauUnlockAuth (backup_name); + lockStatus = LOCK_ERROR; + if (old != NULL) { + (void) fclose (old); + old = NULL; + } + if (new != NULL) + (void) fclose (new); + } +#ifdef HAS_MKSTEMP } else { - XauUnlockAuth (backup_name); - lockStatus = LOCK_ERROR; - } + (void) fclose (old); +#endif + } } } if (lockStatus != LOCK_SUCCESS) { @@ -1370,6 +1427,7 @@ RemoveUserAuthorization (struct display *d, struct verify_info *verify) Debug ("Lock is %d\n", lockStatus); if (lockStatus != LOCK_SUCCESS) return; + old = NULL; if (openFiles (name, new_name, &old, &new)) { initAddrs (); diff --git a/config/xdm-config.cpp b/config/xdm-config.cpp index b83ccb7..7ba9a5b 100644 --- a/config/xdm-config.cpp +++ b/config/xdm-config.cpp @@ -3,7 +3,7 @@ ! ! ! -! $XFree86: xc/programs/xdm/config/xdm-conf.cpp,v 1.10 2002/11/30 19:11:32 herrb Exp $ +! $XFree86: xc/programs/xdm/config/xdm-conf.cpp,v 1.11 2004/01/09 00:25:25 dawes Exp $ ! DisplayManager.errorLogFile: XDMLOGDIR/xdm.log DisplayManager.pidFile: XDMPIDDIR/xdm.pid @@ -20,6 +20,7 @@ DisplayManager._0.setup: XDMDIR/Xsetup_0 DisplayManager._0.startup: XDMDIR/GiveConsole DisplayManager._0.reset: XDMDIR/TakeConsole ! +DisplayManager*chooser: CHOOSERPATH DisplayManager*resources: XDMDIR/Xresources DisplayManager*session: XDMDIR/Xsession DisplayManager*authComplain: true @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/daemon.c,v 3.20 2002/12/04 16:53:39 tsi Exp $ */ +/* $XFree86: xc/programs/xdm/daemon.c,v 3.22 2004/01/11 00:19:30 dawes Exp $ */ /* * xdm - display manager daemon @@ -39,16 +39,8 @@ from The Open Group. #include <stdlib.h> #include <string.h> -#ifndef __GLIBC__ -# if defined(__osf__) || \ - defined(__GNU__) || \ - defined(__CYGWIN__) || \ - defined(linux) -# define setpgrp setpgid -# endif -#endif -#if defined(SVR4) || defined(USG) || defined(__GLIBC__) +#if defined(USG) # include <termios.h> #else # include <sys/ioctl.h> @@ -66,101 +58,88 @@ from The Open Group. #include "dm.h" #include "dm_error.h" -void -BecomeOrphan (void) -{ - Pid_t child_id; +#if defined(__GLIBC__) || defined(CSRG_BASED) +#define HAS_DAEMON +#endif - /* - * fork so that the process goes into the background automatically. Also - * has a nice side effect of having the child process get inherited by - * init (pid 1). - * Separate the child into its own process group before the parent - * exits. This eliminates the possibility that the child might get - * killed when the init script that's running xdm exits. - */ +#ifndef X_NOT_POSIX +#define HAS_SETSID +#endif - child_id = fork (); - switch (child_id) { - case 0: - /* child */ - break; - case -1: - /* error */ - LogError ("daemon fork failed, errno = %d\n", errno); - break; - - default: { - /* parent */ - -#if defined(CSRG_BASED) || defined(SYSV) || defined(SVR4) || defined(__QNXNTO__) || defined(__GLIBC__) -#if defined(SVR4) || defined(__QNXNTO__) - /* This gets error EPERM. Why? */ - int stat = setpgid(child_id, child_id); -#elif defined(SYSV) - /* don't know how to set child's process group */ - int stat = 0; -#elif defined(__GLIBC__) - int stat = setpgrp (); -#else - int stat = setpgrp (child_id, child_id); +#ifndef HAS_SETSID +#define setsid() MySetsid() + +static Pid_t +MySetsid(void) +{ +#if defined(TIOCNOTTY) || defined(TCCLRCTTY) || defined(TIOCTTY) + int fd; +#endif + int stat; + + fd = open("/dev/tty", O_RDWR); + if (fd >= 0) { +#if defined(USG) && defined(TCCLRCTTY) + int zero = 0; + (void) ioctl (fd, TCCLRCTTY, &zero); +#elif (defined(SYSV) || defined(SVR4)) && defined(TIOCTTY) + int zero = 0; + (void) ioctl (i, TIOCTTY, &zero); +#elif defined(TIOCNOTTY) + (void) ioctl (i, TIOCNOTTY, (char *) 0); /* detach, BSD style */ #endif - if (stat != 0) - LogError ("setting process group for daemon failed: %s\n", - strerror(errno)); -#endif /* ! (CSRG_BASED || SYSV || SVR4 || __QNXNTO__ || __GLIBC__) */ - } - exit (0); + close(fd); } + +#if defined(SYSV) || defined(__QNXNTO__) + return setpgrp(); +#else + return setpgid(0, getpid()); +#endif } +#endif /* !HAS_SETSID */ +/* detach */ void BecomeDaemon (void) { - /* - * Close standard file descriptors and get rid of controlling tty - */ /* If our C library has the daemon() function, just use it. */ -#if defined(__GLIBC__) || defined(CSRG_BASED) +#ifdef HAS_DAEMON daemon (0, 0); #else - int i; + switch (fork()) { + case -1: + /* error */ + LogError("daemon fork failed, %s\n", strerror(errno)); + exit(1); + break; + case 0: + /* child */ + break; + default: + /* parent */ + exit(0); + } + + if (setsid() == -1) { + LogError("setting session id for daemon failed: %s\n", + strerror(errno)); + exit(1); + } -# if defined(SYSV) || defined(SVR4) || defined(__QNXNTO__) - setpgrp (); -# else - setpgrp (0, getpid ()); -# endif + chdir("/"); close (0); close (1); close (2); -# if !defined(__UNIXOS2__) && !defined(__CYGWIN__) -# if !((defined(SYSV) || defined(SVR4)) && defined(i386)) - if ((i = open ("/dev/tty", O_RDWR)) >= 0) { /* did open succeed? */ -# if defined(USG) && defined(TCCLRCTTY) - int zero = 0; - (void) ioctl (i, TCCLRCTTY, &zero); -# else -# if (defined(SYSV) || defined(SVR4)) && defined(TIOCTTY) - int zero = 0; - (void) ioctl (i, TIOCTTY, &zero); -# else - (void) ioctl (i, TIOCNOTTY, (char *) 0); /* detach, BSD style */ -# endif -# endif - (void) close (i); - } -# endif /* !((SYSV || SVR4) && i386) */ -# endif /* !__UNIXOS2__ && !__CYGWIN__*/ /* * Set up the standard file descriptors. */ - (void) open ("/", O_RDONLY); /* root inode already in core */ + (void) open ("/dev/null", O_RDWR); (void) dup2 (0, 1); (void) dup2 (0, 2); -#endif +#endif /* HAS_DAEMON */ } @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/dm.c,v 3.23 2003/09/17 05:48:32 herrb Exp $ */ +/* $XFree86: xc/programs/xdm/dm.c,v 3.24 2004/01/10 21:26:29 herrb Exp $ */ /* * xdm - display manager daemon @@ -133,11 +133,9 @@ main (int argc, char **argv) exit (1); } if (debugLevel == 0 && daemonMode) - BecomeOrphan (); + BecomeDaemon (); if (debugLevel >= 10) nofork_session = 1; - if (debugLevel == 0 && daemonMode) - BecomeDaemon (); /* SUPPRESS 560 */ if ((oldpid = StorePid ())) { @@ -478,12 +476,6 @@ WaitForChild (void) else RestartDisplay (d, FALSE); break; - default: - Debug ("Display exited with unknown status %d\n", waitVal(status)); - LogError ("Unknown session exit code %d from process %d\n", - waitVal (status), pid); - StopDisplay (d); - break; case OPENFAILED_DISPLAY: Debug ("Display exited with OPENFAILED_DISPLAY, try %d of %d\n", d->startTries, d->startAttempts); @@ -556,6 +548,12 @@ WaitForChild (void) else RestartDisplay (d, FALSE); break; + default: + Debug ("Display exited with unknown status %d\n", waitVal(status)); + LogError ("Unknown session exit code %d from process %d\n", + waitVal (status), pid); + StopDisplay (d); + break; } } /* SUPPRESS 560 */ @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/genauth.c,v 3.22 2003/12/18 16:38:39 dawes Exp $ */ +/* $XFree86: xc/programs/xdm/genauth.c,v 3.24 2003/12/21 15:07:06 herrb Exp $ */ /* * xdm - display manager daemon @@ -126,15 +126,15 @@ pollRandomDevice (int fd) * DAMAGE. */ -static unsigned int epool[32], erotate, eadd_ptr; +static CARD32 epool[32], erotate, eadd_ptr; static void -add_entropy (unsigned const int *in, int nwords) +add_entropy (const CARD32 *in, int nwords) { - static unsigned const int twist_table[8] = { + static const CARD32 twist_table[8] = { 0, 0x3b6e20c8, 0x76dc4190, 0x4db26158, 0xedb88320, 0xd6d6a3e8, 0x9b64c2b0, 0xa00ae278 }; - unsigned i, w; + CARD32 i, w; int new_rotate; while (nwords--) { @@ -179,9 +179,9 @@ add_entropy (unsigned const int *in, int nwords) * reflect the addition of 16 longwords of new data. */ static void -pmd5_hash (unsigned int *out, unsigned const int in[16]) +pmd5_hash (CARD32 *out, const CARD32 in[16]) { - unsigned int a, b, c, d; + CARD32 a, b, c, d; a = out[0]; b = out[1]; @@ -286,7 +286,7 @@ sumFile (const char *name, int len, int whence, off_t offset) return -1; } readlen += cnt; - add_entropy((unsigned*)buf, (cnt + 3) / 4); + add_entropy((CARD32 *)buf, (cnt + 3) / 4); } close (fd); Debug("read %d bytes from entropy source \"%s\"\n", readlen, name); @@ -298,7 +298,7 @@ AddTimerEntropy (void) { struct timeval now; X_GETTIMEOFDAY (&now); - add_entropy((unsigned*)&now, sizeof(now)/sizeof(unsigned)); + add_entropy((CARD32 *)&now, sizeof(now)/sizeof(CARD32)); } #define BSIZ 0x10000 @@ -318,8 +318,8 @@ AddOtherEntropy (void) void AddPreGetEntropy (void) { - static long offset; - long readlen; + static off_t offset; + off_t readlen; AddTimerEntropy(); if ((readlen = sumFile (randomFile, BSIZ, SEEK_SET, offset)) == BSIZ) { @@ -346,7 +346,7 @@ AddPreGetEntropy (void) static void InitXdmcpWrapper (void) { - uint32_t sum[4]; + CARD32 sum[4]; #ifdef ARC4_RANDOM sum[0] = arc4random(); @@ -440,14 +440,14 @@ GenerateAuthData (char *auth, int len) return 1; #else /* !XDMAUTH */ #ifdef ARC4_RANDOM - unsigned int *rnd = (unsigned*)auth; + CARD32 *rnd = (CARD32 *)auth; int i; for (i = 0; i < len; i += 4) rnd[i / 4] = arc4random(); return 1; #else /* !ARC4_RANDOM */ - unsigned tmp[4] = { 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476 }; + CARD32 tmp[4] = { 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476 }; #ifdef DEV_RANDOM int fd; diff --git a/greeter/verify.c b/greeter/verify.c index 0fcb320..d12806c 100644 --- a/greeter/verify.c +++ b/greeter/verify.c @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/greeter/verify.c,v 3.26 2003/11/19 04:44:00 dawes Exp $ */ +/* $XFree86: xc/programs/xdm/greeter/verify.c,v 3.27 2004/01/25 01:12:25 dawes Exp $ */ /* * xdm - display manager daemon @@ -41,14 +41,17 @@ from The Open Group. #include "dm_error.h" #include <pwd.h> -#ifdef USE_PAM + +#if defined(USE_PAM) # include <security/pam_appl.h> # include <stdlib.h> -#else -# ifdef USESHADOW -# include <shadow.h> -# include <errno.h> -# endif +#elif defined(USESHADOW) +# include <shadow.h> +# include <errno.h> +#elif defined(USE_BSDAUTH) +# include <login_cap.h> +# include <varargs.h> +# include <bsd_auth.h> #endif # include "greet.h" @@ -33,7 +33,7 @@ from The Open Group. * * policy.c. Implement site-dependent policy for XDMCP connections */ -/* $XFree86: xc/programs/xdm/policy.c,v 3.8 2002/12/07 20:31:04 herrb Exp $ */ +/* $XFree86: xc/programs/xdm/policy.c,v 3.9 2004/01/01 17:12:34 herrb Exp $ */ # include "dm.h" # include "dm_auth.h" @@ -179,7 +179,28 @@ SelectConnectionTypeIndex ( ARRAY16Ptr connectionTypes, ARRAYofARRAY8Ptr connectionAddresses) { - return 0; + int i; + + /* + * Select one supported connection type + */ + + for (i = 0; i < connectionTypes->length; i++) { + switch (connectionTypes->data[i]) { + case FamilyLocal: +#if defined(TCPCONN) + case FamilyInternet: +#if defined(IPv6) && defined(AF_INET6) + case FamilyInternet6: +#endif /* IPv6 */ +#endif /* TCPCONN */ +#if defined(DNETCONN) + case FamilyDECnet: +#endif /* DNETCONN */ + return i; + } + } /* for */ + return -1; } #endif /* XDMCP */ @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/session.c,v 3.36 2003/09/29 21:00:08 herrb Exp $ */ +/* $XFree86: xc/programs/xdm/session.c,v 3.37 2004/01/07 04:28:06 dawes Exp $ */ /* * xdm - display manager daemon @@ -87,7 +87,7 @@ extern struct spwd *getspnam(GETSPNAM_ARGS); extern void endspent(void); # endif #endif -#if defined(CSRG_BASED) || defined(__GLIBC__) +#if defined(CSRG_BASED) || defined(__GLIBC__) || defined(USL) # include <pwd.h> # include <unistd.h> #else diff --git a/xdm.man.cpp b/xdm.man.cpp index 9b0de19..7e1bd4b 100644 --- a/xdm.man.cpp +++ b/xdm.man.cpp @@ -23,7 +23,7 @@ .\" other dealings in this Software without prior written authorization .\" from The Open Group. .\" -.\" $XFree86: xc/programs/xdm/xdm.man,v 3.27 2003/11/22 04:51:02 dawes Exp $ +.\" $XFree86: xc/programs/xdm/xdm.man,v 3.29 2004/01/12 21:43:19 herrb Exp $ .\" .TH XDM 1 __xorgversion__ .SH NAME @@ -92,13 +92,6 @@ by .I chooser or X terminals themselves. .PP -.I Xdm -can be configured to ignore BroadcastQuery messages from selected hosts. -This is useful when you don't want the host to appear in menus produced -by -.I chooser -or X terminals themselves. -.PP Because .I xdm provides the first interface that users will see, it is designed to be @@ -417,7 +410,7 @@ is the conventional name. .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.chooser\fP" Specifies the program run to offer a host menu for Indirect queries redirected to the special host name CHOOSER. -\fI __projectroot__/lib/X11/xdm/chooser\fP is the default. +\fI CHOOSERPATH \fP is the default. See the sections \fBXDMCP Access Control\fP and \fBChooser\fP. .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.xrdb\fP" Specifies the program used to load the resources. By default, @@ -660,11 +653,6 @@ it can be followed by the optional ``NOBROADCAST'' keyword. This can be used to prevent an xdm server from appearing on menus based on Broadcast queries. .PP -To only respond to Direct queries for a host or pattern, -it can be followed by the optional ``NOBROADCAST'' keyword. -This can be used to prevent an xdm server from appearing on -menus based on Broadcast queries. -.PP An Indirect entry also contains a host name or pattern, but follows it with a list of host names or macros to which indirect queries should be sent. @@ -921,15 +909,6 @@ the following environment variables are passed: SHELL the value of \fBDisplayManager.\fP\fIDISPLAY\fP\fB.systemShell\fP XAUTHORITY may be set to an authority file .fi -.IP "\fBxlogin.Login.allowRootLogin\fP" -If set to ``false'', don't allow root (and any other user with uid = 0) to -log in directly. -The default is ``true''. -.IP "\fBxlogin.Login.allowNullPasswd\fP" -If set to ``true'', allow an otherwise failing password match to succeed -if the account does not require a password at all. -The default is ``false'', so only users that have passwords assigned can -log in. .PP Note that since \fIxdm\fP grabs the keyboard, any other windows will not be able to receive keyboard input. They will be able to interact with @@ -998,6 +977,15 @@ The color used to display the failure message. .IP "\fBxlogin.Login.failTimeout\fP" The number of seconds that the failure message is displayed. The default is 30. +.IP "\fBxlogin.Login.allowRootLogin\fP" +If set to ``false'', don't allow root (and any other user with uid = 0) to +log in directly. +The default is ``true''. +.IP "\fBxlogin.Login.allowNullPasswd\fP" +If set to ``true'', allow an otherwise failing password match to succeed +if the account does not require a password at all. +The default is ``false'', so only users that have passwords assigned can +log in. .IP "\fBxlogin.Login.translations\fP" This specifies the translations used for the login widget. Refer to the X Toolkit documentation for a complete discussion on translations. The default @@ -1022,15 +1010,6 @@ translation table is: <Key>: insert-char() \\ .fi -.IP "\fBxlogin.Login.allowRootLogin\fP" -If set to ``false'', don't allow root (and any other user with uid = 0) to -log in directly. -The default is ``true''. -.IP "\fBxlogin.Login.allowNullPasswd\fP" -If set to ``true'', allow an otherwise failing password match to succeed -if the account does not require a password at all. -The default is ``false'', so only users that have passwords assigned can -log in. .PP The actions which are supported by the widget are: .IP "delete-previous-character" @@ -1351,7 +1330,7 @@ This directs to manage sessions on all three of these terminals. See the section \fBControlling Xdm\fP for a description of using signals to enable and disable these terminals in a manner reminiscent of -.IR init (8). +.IR init (__adminmansuffix__). .SH LIMITATIONS One thing that .I xdm @@ -1367,7 +1346,7 @@ the default configuration file .I $HOME/.Xauthority user authorization file where \fIxdm\fP stores keys for clients to read .TP 20 -.I __projectroot__/lib/X11/xdm/chooser +.I CHOOSERPATH the default chooser .TP 20 .I __projectroot__/bin/xrdb @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xdm/xdmcp.c,v 3.25 2003/11/23 22:36:03 herrb Exp $ */ +/* $XFree86: xc/programs/xdm/xdmcp.c,v 3.26 2004/01/07 04:28:06 dawes Exp $ */ /* * xdm - display manager daemon @@ -416,7 +416,7 @@ WaitForSomething (void) { #ifdef STREAMSCONN if (xdmcpFd >= 0 && FD_ISSET (xdmcpFd, &reads)) - ProcessRequestSocket (); + ProcessRequestSocket (xdmcpFd); #endif if (chooserFd >= 0 && FD_ISSET (chooserFd, &reads)) { |