jailkit-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Jailkit-users] jailed user can view directories/files outside home


From: Brian Platt
Subject: [Jailkit-users] jailed user can view directories/files outside home
Date: Fri, 10 May 2019 10:14:28 +0100

So I have 2 test users. A user can view the /opt/jail/home folders but cannot enter another users directory as expected

address@hidden:/home$ ls -la
total 16
drwxr-xr-x  4 root  root 4096 May 10 10:54 .
drwxr-xr-x 11 root  root 4096 Aug 24  2016 ..
drwx------  3 test    33 4096 May  7 13:28 test
drwx------  3 test2   33 4096 Apr 10 09:57 test2

address@hidden:/home$ cd test2/
bash: cd: test2/: Permission denied

great that works BUT as the test user i'm able to browse folders below home 

address@hidden:/home$ cd ..
address@hidden:/$ ls -la
total 44
drwxr-xr-x 11 root root 4096 Aug 24  2016 .
drwxr-xr-x 11 root root 4096 Aug 24  2016 ..
drwxr-xr-x  2 root root 4096 May  8 16:23 bin
drwxr-xr-x  2 root root 4096 Apr  3 17:41 dev
drwxr-xr-x  6 root root 4096 May  8 16:24 etc
drwxr-xr-x  4 root root 4096 May 10 10:54 home
drwxr-xr-x  4 root root 4096 Aug 24  2016 lib
drwxr-xr-x  2 root root 4096 Aug 24  2016 lib64
drwxrwxrwx  2 root root 4096 Aug 30  2016 tmp
drwxr-xr-x  6 root root 4096 Aug 24  2016 usr
drwxr-xr-x  3 root root 4096 Aug 24  2016 var

and view file contents (but not edit)

address@hidden:/$ cd /etc/
address@hidden:/etc$ cat passwd
root:x:0:0:root:/root:/bin/bash
test:x:1001:1001:First Last,RoomNumber,WorkPhone,HomePhone:/home/test:/bin/bash
test2:x:1002:1002:,,,:/home/test2:/bin/bash

Shouldn't the user at least be jailed to the home directory?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]