Mailing List Archive

Porting openssh to Win32
Hello,

I am interested in a port of OpenSSH to the Win32 plattform,
using Cygwin for a start.

Is anyone already working on it?

Regards,
Marc
Re: Porting openssh to Win32 [ In reply to ]
I did look into it a short while ago. I don't have the time to work on
it now, and I didn't get that far (I was busy with other stuff) so I'm
afraid I don't have any source to give to you.

First port of call was a cygwin port of openssl (I was using cygwin 1.0,
not b20.1) as the existing win32 stuff is for the M$ compiler. I got it
compiled with gcc (using the gcc target, and changing an 'ln -s'
command to a copy, as the symlink was looping on NT) but for some reason
a file was getting truncated and the tests failed. I stopped there as
there was other stuff to do on the Unix ports.

Then, as Damien pointed out to me, a good random source is required,
which will probably require some native win32 code to access the
system's entropy sources. The performance monitor interface looked a
good bet for this. There was some talk recently of porting the Yarrow
PRNG from VC++, that would help but it's still some way off I think.

Then there's the pseudo-terminal implementation, which I didn't get to
I'm afraid.

Ta,
-Andre

"Marc van Woerkom (ORGAPLAN Software GmbH)" wrote:
>
> Hello,
>
> I am interested in a port of OpenSSH to the Win32 plattform,
> using Cygwin for a start.
>
> Is anyone already working on it?
>
> Regards,
> Marc
Re: Porting openssh to Win32 [ In reply to ]
> First port of call was a cygwin port of openssl (I was using cygwin 1.0,
> not b20.1) as the existing win32 stuff is for the M$ compiler. I got it
> compiled with gcc (using the gcc target, and changing an 'ln -s'
> command to a copy, as the symlink was looping on NT) but for some reason
> a file was getting truncated and the tests failed. I stopped there as
> there was other stuff to do on the Unix ports.

Another source of fun is usually the \r\n vs \n line termination, as
expressed using text or binary mode on files.


> Then, as Damien pointed out to me, a good random source is required,
> which will probably require some native win32 code to access the
> system's entropy sources.

My first problem would be to determine how good that generator is.
Is there any test suite out there, with a minimum of consesus among the
experts, that would allow to decide if it is crap or not?

I know that there is a lot written in Knuths books - I remember that
easy test to simply plot (x_i, x_{i+1}) to spot for some of the more
obvious flaws.

Regards,
Marc
Re: Porting openssh to Win32 [ In reply to ]
On Thu, Jan 20, 2000 at 03:33:34PM +0100, Marc van Woerkom wrote:
> My first problem would be to determine how good that generator is.
> Is there any test suite out there, with a minimum of consesus among the
> experts, that would allow to decide if it is crap or not?

ftp://ftp.franken.de/pub/crypt/cryptlib/beta/cl30beta01.zip
contains Peter Gutmann's random generators for various OSes.
He has written a paper about his ideas:
http://www.cs.auckland.ac.nz/~pgut001/pubs/random.pdf
For more information see
http://www.cs.berkeley.edu/~daw/rnd/index.html
or the www.gnupg.org page. They have a windows port and need
randomness, too.
Re: Porting openssh to Win32 [ In reply to ]
Marc van Woerkom wrote:
>
> > First port of call was a cygwin port of openssl (I was using cygwin 1.0,
> > not b20.1) as the existing win32 stuff is for the M$ compiler. I got it
> > compiled with gcc (using the gcc target, and changing an 'ln -s'
> > command to a copy, as the symlink was looping on NT) but for some reason
> > a file was getting truncated and the tests failed. I stopped there as
> > there was other stuff to do on the Unix ports.
>
> Another source of fun is usually the \r\n vs \n line termination, as
> expressed using text or binary mode on files.

Yep, it's quite likely the truncated file is simply this - it spots an
EOF for an ASCII mode file (I got bitten by that when porting some unix
OpenGL stuff a while back, I had trouble opening GIFs on Windows...

-André