Subject: Re: [PATCH] Added Windows Cryptography API: Next Generation backend

Re: [PATCH] Added Windows Cryptography API: Next Generation backend

From: Marc Hoersken <info_at_marc-hoersken.de>
Date: Sun, 16 Mar 2014 02:35:31 +0100

Hi Bob,

On 14.03.2014 21:24, Bob Kast wrote:
> I tried it on a known good SFTP account and it works fine so far!

great to hear that WinCNG works for you now. :-)

> I checked out the latest and applied your patches and got Visual Studio 2013
> to work with it (notice .sln/.vcxproj files). I have 2 platforms (x64 and
> x86), and 4 configurations (LIB Debug, LIB Release, DLL Debug, DLL Release).
> I fixed the warnings for x86 compiles. There are lots more on x64 (the main
> reason: on WIN64 size_t is a 64 bit type) and didn't deal with them yet.

Thanks for fixing these within the patch you send, but I would kindly
like to ask you to put individual and independent fixes into separate
patches and post them to a separate thread on this mailinglist. This
allows me to keep track of changes to the WinCNG code separately and
other people can merge your general fixes without having to look through
all the WinCNG code.

> I attached my patches.

Thanks for your contribution of these fixes. I integrated some of your
findings into the latest WinCNG branch within my personal development
repository on GitHub:
https://github.com/mback2k/libssh2/tree/wincng-rc4

You can see the history of the individual changes for rc4 here:
https://github.com/mback2k/libssh2/tree/wincng-dev3

Keep in mind that those personal branches are moving targets and could
be rebased or moved around at all times.

Regarding your changes to the Windows makefiles and VS project files:
I guess we will have to restructure and improve them anyway, since they
currently only support the OpenSSL backend. Just replacing OpenSSL with
WinCNG might be a solution for your local build environment, but I think
that is not something that can be put into the main repository since it
would break backwards compatibility.

> A couple of notes:
>
> _LIBSSH2_SESSION::scpRecv_mode (long) is assigned to struct stat::st_mode
> (unsigned short) Are they supposed to be the same type?

Please create a separate thread for this topic by sending a completely
independent mail, e.g. do not reply to mails from this thread.

> In _libssh2_wincng_bignum_set_word() the local variable "bits" was never
> initialized. I assume it is supposed to be initialized to 0.

Thanks, I included a slightly different fix in my latest branch.
Attached is the latest patch created from my wincng-rc4 branch which is
based upon the fixes from the following mail:
http://libssh2.org/mail/libssh2-devel-archive-2014-03/0013.shtml

Best regards,
Marc

Received on 2014-03-16