delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2003/08/13/18:15:57

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <3F3AB889.8080701@keyww.com>
Date: Wed, 13 Aug 2003 15:15:37 -0700
From: jwaterbrook <jwaterbrook AT keyww DOT com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624
X-Accept-Language: en
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: michael's openssh for windows
References: <Pine DOT GSO DOT 4 DOT 44 DOT 0308131624010 DOT 3784-100000 AT slinky DOT cs DOT nyu DOT edu>
In-Reply-To: <Pine.GSO.4.44.0308131624010.3784-100000@slinky.cs.nyu.edu>
X-OriginalArrivalTime: 13 Aug 2003 22:15:38.0412 (UTC) FILETIME=[6CEA7EC0:01C361E8]

"I have to say that this list does not provide support for truncated 
versions of Cygwin downloaded from other sites"
Let's just say that I was using the normal installation ;)
Yes, I came in to this discussion because I knew the procedure would be 
very similar if not the same.  Someday I may want to get the full cygwin 
distribution, but for now, I only need the necessities.

I hope this will help for future users who want to use ssh solely as an 
sftp server.

I also want people to know of the HUGE advantage of using a sftp over a 
normal ftp server: even though it is slower, it only uses ONE port.  
This means those of you behind a linksys router or whatever can forward 
a single port and it will work! (no "higher" pasv mode ports.)
For example: a situation where this may come in handy is if you are at 
work and all outgoing ports are blocked except, say, 80 and you need to 
transfer files from/to home.

Happy cygwining.

Cheers,
Johnny


Igor Pechtchanski wrote:

> Now that I finally realized which "Michael" you were talking about in the
> subject, I have to say that this list does not provide support for
> truncated versions of Cygwin downloaded from other sites, such as Michael
> Erdely's openssh installation.  However, the instructions would be the
> same for the official Cygwin version of openssh, so it's good that this
> discussion is in the archives.
>         Igor
> P.S. FYI, to avoid the "Could not chdir to home directory /home/SSHUSER:
> No such file or directory" message, edit your /etc/passwd and change
> "/home/SSHUSER" to "/cygdrive/d/ssh_shared" (again, works on Cygwin, too)
>
> On Wed, 13 Aug 2003, jwaterbrook wrote:
>
> > I played with this a bit last night and chatted with a few friends 
> and I
> > think I found my solution.
> >
> > I created a directory on the my "D Drive" and called it SSH_SHARED (ie
> > d:\ssh_shared)
> > I copied these files to it:
> > c:\program files\openssh\bin\cygcrypto-0.9.7.dll to
> > d:\ssh_shared\bin\cygcrypto-0.9.7.dll
> > c:\program files\openssh\bin\cygwin1.dll to 
> d:\ssh_shared\bin\cygwin1.dll
> > c:\program files\openssh\bin\sh.exe to d:\ssh_shared\bin\sh.exe
> > c:\program files\openssh\etc\moduli to d:\ssh_shared\etc\moduli
> > c:\program files\openssh\usr\sbin\sftp-server.exe to
> > d:\ssh_shared\usr\sbin\sftp-server.exe
> > and created a directory called d:\ssh_shared\pub\ (where I'll put 
> the files)
> >
> > at the end of my sftponly script I added the line:
> > chroot /cygdrive/d/ssh_shared /bin/sh -i "$@"
> > (in place of the exec /bin/sh)
> >
> > I downloaded chroot.exe from a cygwin mirror in release/sh-utils/
> > (keep in mind I am using michaels openssh distribution so it's not 
> included)
> > and put it into c:\program files\openssh\bin
> >
> > then I restarted the service.
> >
> > when I ssh into the machine here is my output:
> > Last login: Wed Aug 13 11:53:32 2003 from wwww.xxxx.com
> > Could not chdir to home directory /home/SSHUSER: No such file or 
> directory
> > Sorry, sftp only!
> > Connection to yyyy.zzzz.net closed.
> > USER AT localhost:~$
> >
> > when I sftp into the machine, it is sucessful.
> > When I try a cd /cygdrive/c/windows I get:
> > sftp> cd /cygdrive/d/windows
> > Couldn't canonicalise: No such file or directory
> > sftp>
> >
> > When I try a cd .. I get the same thing.
> >
> > I'm not very impressed with the transfer rates that I'm getting, but it
> > may be the encryption overhead.  It would also be nice to package this
> > someday as an alternative to the many windows' ftp servers out there.
> >
> > Thanks to everyone who helped me out on this.
> > Johnny
> >
> > Igor Pechtchanski wrote:
> >
> > > Glad I could help.  chroot is tricky to set up, you might want to
> > > search the net for some working examples.  DENY ACLs are a feature of
> > > WinNT-based systems (Win2k, WinXP, etc) -- they are not a feature of
> > > Cygwin proper.
> > >         Igor
> > [snip]
>
> -- 
>                                 http://cs.nyu.edu/~pechtcha/ 
> <http://cs.nyu.edu/%7Epechtcha/>
>       |\      _,,,---,,_                pechtcha AT cs DOT nyu DOT edu
> ZZZzz /,`.-'`'    -.  ;-;;,_            igor AT watson DOT ibm DOT com
>      |,4-  ) )-,_. ,\ (  `'-'           Igor Pechtchanski, Ph.D.
>     '---''(_/--'  `-'\_) fL     a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!
>
> "I have since come to realize that being between your mentor and his 
> route
> to the bathroom is a major career booster."  -- Patrick Naughton
>


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019