[CentOS] su path hard coded?

Sun Jul 29 21:15:57 UTC 2012
Kahlil Hodgson <kahlil.hodgson at dealmax.com.au>

On 25/07/12 20:10, Stephen Harris wrote:
> On Tue, Jul 24, 2012 at 11:27:09PM -0400, Karl Vogel wrote:
>>>> On 07/24/12 4:33 PM, Stephen Harris wrote:
>> S> I want the ability to "set the default path".  That's all.
>>
>>     It sounds like your best bet would be to change the source for su, and
>>     just be prepared to reinstall it if/when yum (or whatever) replaces it.
>>
>>     Being able to specify the default PATH without having to mess with shell
>>     setup files is a nice feature; Solaris allows you to do this by providing
>>     an /etc/default/su file to set the PATH plus other things like whether you
>>     want to use syslog for access logging, etc.
>
> Yeah, that's the functionality I was hoping to be able to replicate.
> Seems like an odd RedHat restriction, especially since other Linux
> variants can do this via login.defs.  Ah well.

I see you are running Centos 5. Perhaps have a look at

/etc/security/pam_env.conf

Does setting the default PATH there have any effect?

Kal
-- 
Kahlil (Kal) Hodgson                       GPG: C9A02289
Head of Technology                         (m) +61 (0) 4 2573 0382
DealMax Pty Ltd                            (w) +61 (0) 3 9008 5281

Suite 1415
401 Docklands Drive
Docklands VIC 3008 Australia

"All parts should go together without forcing.  You must remember that
the parts you are reassembling were disassembled by you.  Therefore,
if you can't get them together again, there must be a reason.  By all
means, do not use a hammer."  -- IBM maintenance manual, 1925