<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: sftp with chroot environment issue - need help in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320169#M340581</link>
    <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;There had to be an error during setup.&lt;BR /&gt;&lt;BR /&gt;The tests you show indicate chroot configuration did not happen for this user at all.&lt;BR /&gt;&lt;BR /&gt;I'd run thought the setup again and record the error. If you post that it might be the key to a solution.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
    <pubDate>Tue, 09 Dec 2008 14:12:34 GMT</pubDate>
    <dc:creator>Steven E. Protter</dc:creator>
    <dc:date>2008-12-09T14:12:34Z</dc:date>
    <item>
      <title>sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320168#M340580</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I have an account with only sftp access. Also I need to configure chroot environment for this account. I ran the script /opt/ssh/utils/ssh_chroot_setup.sh &lt;BR /&gt;&lt;BR /&gt;It seems the script ran fine. see below&lt;BR /&gt;         ---------------------------------&lt;BR /&gt;         Select chroot secure shell option&lt;BR /&gt;         ----------------------------------&lt;BR /&gt;         1 sftp&lt;BR /&gt;         2 ssh &amp;amp; sftp &amp;amp; scp&lt;BR /&gt;         press return key to skip this step&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;         Option : 1&lt;BR /&gt;&lt;BR /&gt;         chroot setup for sftp operations&lt;BR /&gt;&lt;BR /&gt;         IMPORTANT NOTE:&lt;BR /&gt;         This setup will make sure that sftp works in your chroot environment&lt;BR /&gt;         It should not be interpreted as a restrictive sftp-only Shell.&lt;BR /&gt;         This setup simply copies the files required for sftp to the appropriate directories under the newroot.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;         Now configuring the chroot environment for sftp ...finished&lt;BR /&gt;&lt;BR /&gt;         Summary&lt;BR /&gt;         --------&lt;BR /&gt;&lt;BR /&gt;         Chroot-ed user : ganesh&lt;BR /&gt;&lt;BR /&gt;         Chroot-ed user's new root directory : /newroot&lt;BR /&gt;&lt;BR /&gt;         Secure Shell configuration : SFTP&lt;BR /&gt;&lt;BR /&gt;         press Return key&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;But still the user is able to browse root dir and other directories.&lt;BR /&gt;&lt;BR /&gt;sftp&amp;gt; pwd&lt;BR /&gt;Remote working directory: /newroot/home/ganesh&lt;BR /&gt;sftp&amp;gt; cd /&lt;BR /&gt;sftp&amp;gt; ls&lt;BR /&gt;bin                 cdrom&lt;BR /&gt;dev                 etc                 &lt;BR /&gt;home&lt;BR /&gt;lib                 lost+found          newroot             opt                 sbin                stand               tcb                 ter                 test                tmp                 tmp_mnt             usr                &lt;BR /&gt;var&lt;BR /&gt;&lt;BR /&gt;sftp&amp;gt; cd /var&lt;BR /&gt;sftp&amp;gt; ls&lt;BR /&gt;It is listing contents of var&lt;BR /&gt;&lt;BR /&gt;entry in /etc/passwd is &lt;BR /&gt;ganesh:*:148:20:chrooted user:/newroot/./home/ganesh:/opt/ssh/etc/sftponly&lt;BR /&gt;&lt;BR /&gt;I noted that I don't see any files under /newroot/home/ganesh.&lt;BR /&gt;&lt;BR /&gt;What could be the issue? how to resolve it?</description>
      <pubDate>Tue, 09 Dec 2008 12:42:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320168#M340580</guid>
      <dc:creator>Ganesan R</dc:creator>
      <dc:date>2008-12-09T12:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320169#M340581</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;There had to be an error during setup.&lt;BR /&gt;&lt;BR /&gt;The tests you show indicate chroot configuration did not happen for this user at all.&lt;BR /&gt;&lt;BR /&gt;I'd run thought the setup again and record the error. If you post that it might be the key to a solution.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Tue, 09 Dec 2008 14:12:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320169#M340581</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2008-12-09T14:12:34Z</dc:date>
    </item>
    <item>
      <title>Re: sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320170#M340582</link>
      <description>Hi SEP,&lt;BR /&gt;&lt;BR /&gt;I tried reconfiguring also. result is same.&lt;BR /&gt;But I am not seeing any error and the script shows it is finished&lt;BR /&gt;&lt;BR /&gt;My requirement is here.&lt;BR /&gt;======================= &lt;BR /&gt;Create a user called "test" with only sftp access(no ssh). This user should be restricted within his home dir(/home/test). He should not browse or view beyond his home directory.&lt;BR /&gt;&lt;BR /&gt;Could someone give steps/commands to do the above. Either with help of ssh_chroot_setup.sh  script or without this script(means by commands)&lt;BR /&gt;&lt;BR /&gt;Thanks in advance.</description>
      <pubDate>Tue, 09 Dec 2008 14:40:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320170#M340582</guid>
      <dc:creator>Ganesan R</dc:creator>
      <dc:date>2008-12-09T14:40:35Z</dc:date>
    </item>
    <item>
      <title>Re: sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320171#M340583</link>
      <description>You don't need to run this script anymore. And I suggest you don't run it, building jails for scp and sftp is complex and messy.&lt;BR /&gt;&lt;BR /&gt;Since March 2008, OpenSSH has a internal chroot feature for the sftp server and it has been included in HP-UX Secure Shell 5.xx and up, I have 5.10. This makes chrooting SFTP dead easy.&lt;BR /&gt;&lt;BR /&gt;You simply have to add this to sshd_config:&lt;BR /&gt;  Subsystem sftp internal-sftp&lt;BR /&gt;  ChrootDirectory /opt/anonftp        &lt;BR /&gt;&lt;BR /&gt;And you're done. No need to copy any libraries. &lt;BR /&gt;&lt;BR /&gt;Damien posted how to do this here:&lt;BR /&gt;&lt;A href="http://undeadly.org/cgi?action=article&amp;amp;sid=20080220110039" target="_blank"&gt;http://undeadly.org/cgi?action=article&amp;amp;sid=20080220110039&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;There's also an article about the feature here:&lt;BR /&gt;&lt;A href="http://www.debian-administration.org/articles/590" target="_blank"&gt;http://www.debian-administration.org/articles/590&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I've been using this for a few months now, and it works well. &lt;BR /&gt;&lt;BR /&gt;To have full logging, you can put:&lt;BR /&gt;  Subsystem sftp internal-sftp -l VERBOSE &lt;BR /&gt;&lt;BR /&gt;The only drawback with this is that you need to redirect the jailed /dev/log, I have a fix here:&lt;BR /&gt;&lt;A href="http://omasse.blogspot.com/2008/09/redirecting-chroot-jailed-devlog-to.html" target="_blank"&gt;http://omasse.blogspot.com/2008/09/redirecting-chroot-jailed-devlog-to.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Don't do a ForceComand sftp yet, as the loggin will not work. There's a bugzilla entry for this, and it has been fixed. We need to wait for HP-UX Secure Shell to sync with openSSH.&lt;BR /&gt;&lt;BR /&gt;Good luck&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;         &lt;BR /&gt;</description>
      <pubDate>Tue, 09 Dec 2008 15:56:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320171#M340583</guid>
      <dc:creator>Olivier Masse</dc:creator>
      <dc:date>2008-12-09T15:56:27Z</dc:date>
    </item>
    <item>
      <title>Re: sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320172#M340584</link>
      <description>Hi Oliver,&lt;BR /&gt;&lt;BR /&gt;Will try your suggesstion and update you on the status.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 09 Dec 2008 16:03:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320172#M340584</guid>
      <dc:creator>Ganesan R</dc:creator>
      <dc:date>2008-12-09T16:03:58Z</dc:date>
    </item>
    <item>
      <title>Re: sftp with chroot environment issue - need help</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320173#M340585</link>
      <description>One more thing:&lt;BR /&gt;&lt;BR /&gt;To create a limited sftp user, here's a suggested passwd entry:&lt;BR /&gt;&lt;BR /&gt;sftpuser:x:604:307:SFTP Users:/opt/anonftp/./sftpuser:/usr/local/bin/noshell&lt;BR /&gt;&lt;BR /&gt;The home directory has an embedded /./ in case the user decides to use FTP instead (we support both here) but I don't think you need this.&lt;BR /&gt;&lt;BR /&gt;I set noshell to prevent any interactive login for this user, but noshell is not included with HP-UX, you can use /bin/false to get the same result.&lt;BR /&gt;&lt;BR /&gt;I also run the sftp server on a different port and prevent these users from accessing the ssh service on port 22 using DenyGroups, but that's not required. Using /bin/false is good enough for most cases.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 09 Dec 2008 16:05:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sftp-with-chroot-environment-issue-need-help/m-p/4320173#M340585</guid>
      <dc:creator>Olivier Masse</dc:creator>
      <dc:date>2008-12-09T16:05:37Z</dc:date>
    </item>
  </channel>
</rss>

