shell User and Jailkit

Discussion in 'Installation/Configuration' started by Greenhorn2013, Sep 4, 2018.

Tags:
  1. Greenhorn2013

    Greenhorn2013 New Member

    Today i want to add a new shell user with jailkit. If i try to connect, connection will be closed after password. If i disable jailkit connection will be established. whats wrong?
    Entry in auth log:
    Code:
    Sep  4 17:08:13 vcawws01 systemd-logind[2762]: New session 190771 of user web2.
    Sep  4 17:08:13 vcawws01 systemd: pam_unix(systemd-user:session): session opened for user web2 by (uid=0)
    Sep  4 17:08:13 vcawws01 jk_chrootsh[10197]: path /var/www/clients/client1/web2/web/ is not owned by user 0
    Sep  4 17:08:13 vcawws01 jk_chrootsh[10197]: path /var/www/clients/client1/web2/web/ is not owned by group 0
    Sep  4 17:08:13 vcawws01 jk_chrootsh[10197]: abort, /var/www/clients/client1/web2/web/ is not a safe jail, check ownership and permissions.
    
    Permissions are set: web2:client1 for full path
     
    Last edited: Sep 4, 2018
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I wonder why it says /var/www/clients/client1/web2/web/ as jail root, because the jail root is always /var/www/clients/client1/web2/. The web subfolder cannot be the jail path as it is owned by a wrong user. Did you change the jail path in your setup?
     
  3. Greenhorn2013

    Greenhorn2013 New Member

    i have shortened the path its a subfolder of web.
    Something like /var/www/clients/client1/web2/web/path/to/the/correct/folder
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    This can not work due to the reason I explained above. The folder in the jail path must be owned by root, change the path back to it's original value-
     
  5. Greenhorn2013

    Greenhorn2013 New Member

    the webapplication needs access to that folder so i took this path
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Do not change the jail path. The application can still access that folder as it's in the jail anyway.
     

Share This Page