ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Solved Setup SFTP User with access to a specific directory on Ubuntu

    IT Discussion
    sftp ubuntu 14.04
    3
    10
    2.1k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • IRJI
      IRJ
      last edited by

      I would like to setup a SFTP User with specific access to a directory on Ubuntu Server. I would also like the user to be automatically directed to this directory once they authenticate if that is possible.

      1 Reply Last reply Reply Quote 1
      • DashrenderD
        Dashrender
        last edited by

        No clue how to do it, but I think it might have something to do with setting the home directory of the user?

        scottalanmillerS 1 Reply Last reply Reply Quote 0
        • scottalanmillerS
          scottalanmiller @Dashrender
          last edited by

          @Dashrender said:

          No clue how to do it, but I think it might have something to do with setting the home directory of the user?

          that handles where they go by default. My guess is that he wants this for security, too. So a chrooted jail.

          1 Reply Last reply Reply Quote 0
          • scottalanmillerS
            scottalanmiller
            last edited by

            If all you need is the default directory, then you just change the home directory in the /etc/passwd file as @Dashrender suggests.

            IRJI 1 Reply Last reply Reply Quote 0
            • IRJI
              IRJ @scottalanmiller
              last edited by

              @scottalanmiller said:

              If all you need is the default directory, then you just change the home directory in the /etc/passwd file as @Dashrender suggests.

              I want to give full rights to that directory, but nothing else.

              scottalanmillerS 1 Reply Last reply Reply Quote 0
              • scottalanmillerS
                scottalanmiller @IRJ
                last edited by

                @IRJ said:

                @scottalanmiller said:

                If all you need is the default directory, then you just change the home directory in the /etc/passwd file as @Dashrender suggests.

                I want to give full rights to that directory, but nothing else.

                Okay, so default is not enough. Chrooting is necessary.

                1 Reply Last reply Reply Quote 0
                • scottalanmillerS
                  scottalanmiller
                  last edited by

                  https://www.howtoforge.com/restricting-users-to-sftp-plus-setting-up-chrooted-ssh-sftp-debian-squeeze

                  IRJI 1 Reply Last reply Reply Quote 1
                  • IRJI
                    IRJ @scottalanmiller
                    last edited by

                    @scottalanmiller said:

                    https://www.howtoforge.com/restricting-users-to-sftp-plus-setting-up-chrooted-ssh-sftp-debian-squeeze

                    Working on that now..

                    1 Reply Last reply Reply Quote 0
                    • IRJI
                      IRJ
                      last edited by

                      That worked. Thanks

                      1 Reply Last reply Reply Quote 0
                      • scottalanmillerS
                        scottalanmiller
                        last edited by

                        Woot!

                        1 Reply Last reply Reply Quote 0
                        • 1 / 1
                        • First post
                          Last post