LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 06-15-2011, 11:08 AM   #1
mgumbau
LQ Newbie
 
Registered: Jul 2009
Posts: 17

Rep: Reputation: 0
Needed to be $HOME/.bashrc disabled when user shell is 'rbash' (restricted shell)


MACHINE: HP Proliant DL260G5
OS: SLES 11 SP1
kernel: Linux xserver 2.6.32.12-0.7-default #1 SMP 2010-05-20 11:14:20 +0200 x86_64 x86_64 x86_64 GNU/Linux

It is used as remote xserver in a LAN.

I have configured /usr/lib/restricted/bin/.rbashrc with some environment variables but when the users logon in the system finally is executed $HOME/.bashrc and some environment vars are overwritten.

Are there any possibility to disable de $HOME/.bashrc in /etc/profile or /etc/bash.bashrc or ...

Thnxs.
 
Old 06-15-2011, 12:25 PM   #2
MTK358
LQ 5k Club
 
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723
How about the "--norc" option?
 
Old 06-16-2011, 06:17 AM   #3
mgumbau
LQ Newbie
 
Registered: Jul 2009
Posts: 17

Original Poster
Rep: Reputation: 0
Thanks MTK358, but I don't know how to put parameters in /etc/passwd shell assigment.
And if the user user .bash_profile can execute .bahrc from there and if I put --noprofile, no general environment vars are loaded.
I have preferred to create a special home for users without some privileges, isn't the best solution in my scenario but works for me.

Bye.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
create a directory at user home using shell script nagendrar Solaris / OpenSolaris 10 04-30-2010 05:30 AM
LXer: Rush Hour: Newest GNU Restricted User Shell LXer Syndicated Linux News 0 01-20-2009 10:10 PM
restricted shell sulekha Linux - Security 2 07-09-2008 03:00 PM
Help needed on Mass user creation using shell script EsAsher Linux - General 3 06-29-2007 11:26 PM
need more restricted shell then rbash redss Linux - General 3 01-26-2006 09:55 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration