bugJailkit - Bugs: bug #59732, Centos 8 Support

 
 

bug #59732: Centos 8 Support

Submitter:  Pigro95 <pigro95>
Submitted:  Sat 19 Dec 2020 10:00:59 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Open
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Sun 20 Dec 2020 01:51:42 PM UTC, comment #10: 

jk_cp -j /var/jail /usr/bin/id


Olivier Sessink <oli4>
Group administrator
Sun 20 Dec 2020 11:57:34 AM UTC, comment #9: 

comment #7:

> ahh, the issue is "sudo"
>
> sudo does not start the login shell, so you cannot test a jail with sudo. ssh test@localhost is a better test.


That looks better.

[root@server ~]# ssh test@localhost
bash: /usr/bin/id: No such file or directory
bash: /usr/bin/id: No such file or directory
[test@server ~]$ ls /
bin  dev  etc  home  lib64  usr

I didn't know that sudo don't use the login shell from the user.

Now I just need to find out why /usr/bin/id where not found.


comment #8:

>
> comment #6:
> > I've already made a symlink libnsl.so.2 -> libnsl.so.1
>
> not sure if they are compatible. You probably want to jk_cp libnsl.so.2 into the jail.


Now I added libnsl.so.2 path in /etc/jailkit/jk_init.ini and removed the symlink.

I don't know if libnsl.so.2 is compatible to libnsl.so.1. I hope so. But I also didn't know for what this library is. ;)

If you wan't to add these to the project the paths are  /lib/libnsl.so.2,  /lib64/libnsl.so.2


Thanks for help.

Pigro95 <pigro95>
Sun 20 Dec 2020 09:07:46 AM UTC, comment #8: 


comment #6:

> I've already made a symlink libnsl.so.2 -> libnsl.so.1


not sure if they are compatible. You probably want to jk_cp libnsl.so.2 into the jail.

Olivier Sessink <oli4>
Group administrator
Sun 20 Dec 2020 09:01:56 AM UTC, comment #7: 

ahh, the issue is "sudo"

sudo does not start the login shell, so you cannot test a jail with sudo. ssh test@localhost is a better test.

Olivier Sessink <oli4>
Group administrator
Sat 19 Dec 2020 11:28:12 PM UTC, comment #6: 

I've already made a symlink libnsl.so.2 -> libnsl.so.1

Pigro95 <pigro95>
Sat 19 Dec 2020 11:26:39 PM UTC, comment #5: 

I attached a file with the commands i used an the outputs. Also the line from the user in /etc/passwd.

(file #50527)

Pigro95 <pigro95>
Sat 19 Dec 2020 11:08:48 PM UTC, comment #4: 


comment #2:

> There was no compile error I think.
>
> The default config for jk_init seems not working.
>
> I can create a jail but there are some messages that files
> doesn't exists. I think some of these messages are normal?


yes the config file has files for various linux distributions, so it tries the same files on different locations.


>
> When I login as a jailed user, there is no chroot.
> I can't see the normal root from the system.


this is very strange, this should never happen. this user does have jk_chrootsh as shell? What errors are in the logs?


> libnsl.so.1 doesn't exists on Centos 8. There is the
> version libnsl.so.2.


ahh that should be updated in jk_init.ini then.

Olivier Sessink <oli4>
Group administrator
Sat 19 Dec 2020 11:06:08 PM UTC, comment #3: 

comment #2:

>
> When I login as a jailed user, there is no chroot. I can see the normal root from the system.
>





Pigro95 <pigro95>
Sat 19 Dec 2020 10:54:27 PM UTC, comment #2: 

There was no compile error I think.

The default config for jk_init seems not working.

I can create a jail but there are some messages that files doesn't exists. I think some of these messages are normal?

When I login as a jailed user, there is no chroot. I can't see the normal root from the system.

libnsl.so.1 doesn't exists on Centos 8. There is the version libnsl.so.2.

Maybe there are other libs changed/no longer exists.


Pigro95 <pigro95>
Sat 19 Dec 2020 10:17:11 PM UTC, comment #1: 


original submission:

> There are Libraries in newer versions and on another location.
>
> Jailkit doesn't work on Centos 8.


can you give some more detailed errors?

is it compile errors, or is the default config for jk_init not working on centos or what is the problem?

Olivier Sessink <oli4>
Group administrator
Sat 19 Dec 2020 10:00:59 PM UTC, original submission:  

There are Libraries in newer versions and on another location.

Jailkit doesn't work on Centos 8.

Pigro95 <pigro95>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #50527:  jailkit.txt added by pigro95 (13KiB - text/plain - commands and messages)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by oli4 (Posted a comment)
  • -email is unavailable- added by pigro95 (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-09-09 oli4 StatusNone Fixed
    2020-12-19 pigro95 Attached File- Added jailkit.txt, #50527

    Back to the top

    Powered by Savane 3.14-8eb0.
    Corresponding source code