LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices

Reply
 
LinkBack Search this Thread
Old 05-05-2005, 02:15 AM   #1
jayanth
LQ Newbie
 
Registered: Jul 2003
Distribution: Kubuntu 7.10 Gutsy Gibbon
Posts: 10

Rep: Reputation: 0
Unhappy Setting up a chroot jail


Hi,

I was trying to set up a chroot jail when I hit this wall. Here is what I want to do, and what I did:

I want to create a user on my computer who is restricted to this jail. The user will be accessing my machine locally, and not through any network.

The directory structure that I created is as given below (jail is in /home/jail):

/bin /home /sbin /var
/home/prisoner1 /home/prisoner2

In /bin, I copied bash, ls, cat, cd, mkdir, and login.
In /sbin, I have shutdown and related files in /var.

In the .bashrc file of prisoner1, I have chrooted the user into the jail. The problem is, when the user types 'exit' at the shell, and types a *wrong* password, he gets out of the jail, on to the normal prompt. Also, login doesn't work. Is it because there is no password file given in the jail? Also, is .bashrc the file to be used to chroot the user?

I would also like to know what I'll have to do for the user to access X Windows.

Please help.

Jayanth
 
Old 05-06-2005, 12:31 AM   #2
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 57
my friend nitin wrote this small howto for me once

maybe this will help u

http://nitinb.blogspot.com/2004/10/s...t-user-in.html

regards
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chroot jail Gimpy Linux - Software 10 05-07-2010 01:30 PM
Chroot jail pachanga Linux - General 12 09-26-2008 05:15 AM
Jail and chroot rogk Linux - Security 2 10-16-2005 02:20 AM
chroot jail etc. f1uke Linux - Security 5 08-24-2005 03:12 AM
chroot jail simon Linux - Security 3 08-05-2001 08:21 PM


All times are GMT -5. The time now is 01:45 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration