Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 03 Nov 1999 23:51:12 -0800
From:      William Richard <wdr@tdl.com>
To:        "Person, Roderick" <personrp@ccbh.com>
Cc:        questions@FreeBSD.ORG
Subject:   Re: XDM question.
Message-ID:  <38213AF0.5A5C554@tdl.com>
References:  <576A688A7DA7D011899B00805FEA1AFF9AD9A7@sych02.isdip.upmc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
It is possible to set up path information from an X resource in
xdm-config in /usr/X11R6/lib/X11/xdm, specifically setting
DisplayManager._0.userPath equal to the desired path (comma-delimited
list, like sh(1)).  This will apply to the execution of
/usr/X11R6/lib/X11/xdm/Xsession and the scripts it calls (like
~/.xsession).

However, if you have relative components in your path (specifically,
'.', the current working directory), it's not a good idea if you're
going to be using xdm to log in as root (big security hole).  Also, if
you declare search path information relative to the user's home
directory ($HOME/ or $HOME/bin), it won't work with setting the resource
in xdm-config (because the xdm-config method doesn't handle the
environment variable substitution).  Also, note that you can't set other
environment variables (like $MANPATH) with Xresources--just $PATH.

Instead, I declare environment variables at the top of the Xsession
script with PATH=...;export PATH and MANPATH=...;export MANPATH
statements.  I leave off any relative components, and include these in
the user's ~/.xsession file (excluding, of course, root).  You could
also include any system-standardised environment variables, if you
wanna.

In terms of changing a user's default shell, try vipw(1); each user's
line specifies that user's default shell.  Fiddle with this to change
shells.

Cheers,
William Richard
wdr@tdl.com


"Person, Roderick" wrote:
> 
> Sorry for this possible simplish question, I have search for days now. It
> took me 3 weeks to get xdm to start on boot ( really I wanted wdm to boot,
> but it never would), but now that it does I notice that it does not read the
> same login script as a console login does. I have check every possible file
> I can think of .login .cshrc .profile and such but I can't seems to find
> where xdm is get it's settings for PATH and SHELL and other environmentals.
> Where is it defaulted to read. I have check Xsession, Xresources, Xstartup_0
> etc but unless I'm missiung something or just not seeing it I can't find
> anything like the path setting and such. I read the man and what it
> suggested is what seems to be on my sys. TIA.
> 
> Roderick P. Person
> Programmer I
> CCBH (412)454-2616
> 
> " I just want to get functions to return values, for the love of god, don't
> make me do pointers, no, no, make the monsters go away...'
>                 -- pmfh (from WPLUG)
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of the message


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?38213AF0.5A5C554>