From libssh2-devel-bounces@cool.haxx.se Tue Nov 1 14:04:35 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA1D47bY031928; Tue, 1 Nov 2016 14:04:28 +0100 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA1D44Ud031780 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 1 Nov 2016 14:04:05 +0100 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 4CF717F7CB; Tue, 1 Nov 2016 13:04:00 +0000 (UTC) Received: from kdudka-nb.localnet (unused-4-224.brq.redhat.com [10.34.4.224]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id uA1D3wK3029714 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 1 Nov 2016 09:03:59 -0400 From: Kamil Dudka To: Peter Stuge Subject: Re: [PATCH] configure.ac: Add single --with-crypto= instead of --with-$backend:s Date: Tue, 01 Nov 2016 14:04:04 +0100 Message-ID: <2535757.LFWz8UkFTD@kdudka-nb> User-Agent: KMail/4.14.10 (Linux/4.7.10-gentoo; KDE/4.14.24; x86_64; ; ) In-Reply-To: <20161031132342.GA31660@foo.stuge.se> References: <20161027155339.GF20941@foo.stuge.se> <1973197.XhHmMWpa8C@kdudka-nb> <20161031132342.GA31660@foo.stuge.se> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 01 Nov 2016 13:04:00 +0000 (UTC) X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: libssh2-devel@cool.haxx.se Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA1D47bY031928 On Monday, October 31, 2016 13:23:42 Peter Stuge wrote: > Hi Kamil, > > Thanks a lot for testing this! > > Kamil Dudka wrote: > > The patch does not apply on the current upstream master branch, so I > > tested > > the withcrypto branch at http://git.stuge.se/libssh2.git (68b330d2). > > Yes - it applies on top of the handful simple fixes in my simple180 > branch, which I posted before. Sorry, should have made that more clear. > > > Basic crypto backend selection seems to work. > > > > --with-crypto=auto works fine for OpenSSL but does not work for libgcrypt: > > > > $ ./configure --with-crypto=auto > > [...] > > configure: ERROR: No openssl crypto library found! > > configure: error: Required dependencies are missing! > > Good find - I believe libgcrypt was actually successfully detected by > the tests, but the end logic needs a little fixing. Patch attached. Looks good. I can confirm that the patch fixes the problem. Thanks! > > As a side note, the --with-libssl-prefix option did not take any > > effect but it seems unrelated to your patch. > > Oh! How did you notice that it does not take effect, and how did you > deal with that instead, if you need it? Good question. My previous testing was just wrong. I installed OpenSSL by 'make install DESTDIR=/tmp/usr' and afterwards configured libssh2 by './configure --with-crypto=openssl --with-libssl-prefix=/tmp/usr', which was incorrect because OpenSSL was actually installed into /tmp/usr/usr. After fixing this discrepancy, everything works as expected. Sorry for the noise! Kamil > The --with-x-prefix options are a bit unrelated; they are created and > supposed to be handled by AC_LIB_HAVE_LINKFLAGS, but they are related > because they deal with library finding, so I'd like to know more > about the problem you found. If you have config.log from a problem > run maybe you can send it to me. (Maybe off-list if it's large.) > > > Thanks again > > //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Thu Nov 3 09:39:08 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA38cEJB032340; Thu, 3 Nov 2016 09:39:03 +0100 Received: from mail-wm0-x235.google.com (mail-wm0-x235.google.com [IPv6:2a00:1450:400c:c09:0:0:0:235]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA38cCPR032297 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 3 Nov 2016 09:38:12 +0100 Received: by mail-wm0-x235.google.com with SMTP id t79so84878740wmt.0 for ; Thu, 03 Nov 2016 01:38:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:from:date:message-id:subject:to; bh=o6E0WybJBGtaQmL9KfNTsM/fbVdXjd97qNYWGYqvYXY=; b=Dx4B7wMsgkJ/MAo/1Y230tWkFvasMvVjhd2TjFXk/XnA55JYHvgRisTbG8taRf2ySZ 8V7JmaHA3+Z2deriyqdaVVS9VC+vW0OHddk1IZQtuGqrJVoYqk2jQpO2gU4GVOt+VkuY TGA9KZ8nW4kd7hBRFreyteZSv+Xy2g8x0i7dfTrE3Wz/ixEIl151hldopITMVbdEdQP1 CYEUc+Wbod1QsrxE54eF7202mXIu8sWLgEjzObGGsAHtfpjT8ho0gv2ojYvdy7ZwdmIO v2ZxmtjewihWi8fMWLCeh16pIuztmiS3cKKU+I69ejTBRxj8mOgYMWaagopBQyoYaZFv 54kw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:from:date:message-id:subject :to; bh=o6E0WybJBGtaQmL9KfNTsM/fbVdXjd97qNYWGYqvYXY=; b=iA8ZnAZ4GDEtfduV68XeAHHQrTjWDkC5R83l5KUZZ0YRs95sABIjB4lg50RcTC81w+ 6nobDhCFYNaTRKJlZG0oY1enCWkn62nZ4XFGt6kvKINFwxvxWsWaw2Dd1BeIehjb8KCc wnmlObe4KnCEymYj/Epd71e9TR0cox1hV+yxOc/BgmVOoMQVExobnTYUGH9m7QCpbmYJ 8xlkszE1/B5LDP10H17ZTaTMvyZgIs9wUeJIEoAuJxHcBwo2fnrK95QK11pRDnyS2Gl5 VR5Zlckuolgerp+hh8+4WFkdOT5nSo5IflaB0Jt0cs8fcrIXyFQxT/9q5T56O9PWiCKz ZeVA== X-Gm-Message-State: ABUngvdNyz5IFaxjrn7+yZeGY8IU/O/WopkcLIIoidcoWqnKknp+NaKlu6CPB/2cl+nqrMDcbFDzlZGDjXvkww== X-Received: by 10.28.217.131 with SMTP id q125mr7584012wmg.95.1478162287070; Thu, 03 Nov 2016 01:38:07 -0700 (PDT) MIME-Version: 1.0 Received: by 10.194.134.129 with HTTP; Thu, 3 Nov 2016 01:37:36 -0700 (PDT) From: Jeroen Wiert Pluimers Date: Thu, 3 Nov 2016 09:37:36 +0100 X-Google-Sender-Auth: 85tP4ALHip5HFG8TdfnM8VqninY Message-ID: Subject: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2-devel@cool.haxx.se X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============2129284004==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============2129284004== Content-Type: multipart/alternative; boundary=001a11467a040a93890540617af6 --001a11467a040a93890540617af6 Content-Type: text/plain; charset=UTF-8 I've tried to find instructions on how to build a monolithic libssh2.dll on Windows using Visual Studio. I don't mind coming up with a good wiki page on building on Windows using Visual Studio (2015 or newer) but the hints I find on-line on how to get going are - ehm - dense or lacking. So far I've come up with a two batch files in https://gist.github.com/jpluimers/2bf514d658488a7ddfc189b0677a3a57 The first in the text of the gist compiles with WinCNG but the libssh2.dll lacks things that web-site mentions are supported like ciphers (aes128-ctr, aes256-ctr, aes192-ctr) and MAC algorithms (hmac-ripemd160, hmac-ripemd160@openssh.com). A separate batch file in the gist shows the kinds of things I've tried to make monolithic Win64/Win32 versions of libssh2.dll to no avail. So I need help, and with that help I will write docs. Then there is testing what a built libssh2.dll supports. Reading https://www.libssh2.org/ I assumed any permutation would support all features, but boy I was wrong: WinCNG lacks features and I've not even succeeded in testing the libgcrypt and mbedTLS crypto backends as documentation on how to use them is, well, my Google foo didn't find them. Since there is no libssh2 API to query for algorithms supported (there is only https://www.libssh2.org/libssh2_session_methods.html to see what's used during a session) you need convoluted `sshd -d -d -d` to figure out what is going over the line and draw conclusions. I've summarised those conclusions so far in test-results.rst at the same gist. --jeroen --001a11467a040a93890540617af6 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I've tried to find instructions on how to build a mono= lithic libssh2.dll on Windows using Visual Studio.

= I don't mind coming up with a good wiki page on building on Windows usi= ng Visual Studio (2015 or newer) but the hints I find on-line on how to get= going are - ehm - dense or lacking.

So far = I've come up with a two batch files in=C2=A0https://gist.github.com= /jpluimers/2bf514d658488a7ddfc189b0677a3a57

Th= e first in the text of the gist compiles with WinCNG but the libssh2.dll la= cks things that web-site mentions are supported like ciphers (aes128-ctr, a= es256-ctr, aes192-ctr) and MAC algorithms (hmac-ripemd160, hmac-ripemd160@openssh.com).
A separate batch file in the gist shows the kinds of things I&= #39;ve tried to make monolithic Win64/Win32 versions of libssh2.dll to no a= vail.

So I need help, and with that help I will wr= ite docs.

Then there is testing what a built libss= h2.dll supports. Reading=C2=A0https://= www.libssh2.org/ I assumed any permutation would support all features, = but boy I was wrong: WinCNG lacks features and I've not even succeeded = in testing the libgcrypt and mbedTLS crypto backends as documentation on ho= w to use them is, well, my Google foo didn't find them.

<= /div>
Since there is no libssh2 API to query for algorithms supported (= there is only=C2=A0https://www.libssh2.org/libssh2_session_methods.html to see wh= at's used during a session) you need convoluted `sshd -d -d -d` to figu= re out what is going over the line and draw conclusions.

=
I've summarised those conclusions so far in=C2=A0test-result= s.rst at the same gist.

--jeroen
<= /div> --001a11467a040a93890540617af6-- --===============2129284004== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============2129284004==-- From libssh2-devel-bounces@cool.haxx.se Thu Nov 3 13:37:46 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA3CbHUm001430; Thu, 3 Nov 2016 13:37:42 +0100 Received: from mail-lf0-f50.google.com (mail-lf0-f50.google.com [209.85.215.50]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA3CbESa001394 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 3 Nov 2016 13:37:14 +0100 Received: by mail-lf0-f50.google.com with SMTP id t196so36767949lff.3 for ; Thu, 03 Nov 2016 05:37:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=cXyEAchBTQ1OsIL2erHz3LpqSSPPr76iI2EiXX0I8Hc=; b=CYk3ylNUq42LXFXciEcTDf5DpfL3afwicIX8qNNH639CjiQhdPrAOy0qznfiCN0Fpq xTr4GOB9bZhHeZEPrT4tWUGAmtFPbGaJsXkG+7SlytZzqLb27OGqICbQ17FeWEZxqoZz UCuk8QhLA15U6aAyX3SIfHi8/RBNKj77bIgpN/mQeLj4uouk2mI+7c+5bhKOCGpunLEp rp/z2RUnhcg01cMFAV1o/rOiDekklz6t3VSjW/kk+81Vcs71WgT7j4A+ZtMl+O7iYUse PIFi1MJJm+Kd2QzJnQPb2B5mPVonERglTWczjIV5lBwCIMscHoqbY/ljMvqlFNzyuAh5 JJqg== X-Gm-Message-State: ABUngvetoJxK5bMjZxtBU55wg2GydzhGMb/OKt4pdUoaDzJCnEyznfoilv1Js1vMu7Q845isH0rpXcvCZDCQJw== X-Received: by 10.25.195.194 with SMTP id t185mr5422202lff.172.1478176629821; Thu, 03 Nov 2016 05:37:09 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Alexander Lamaison Date: Thu, 03 Nov 2016 12:36:59 +0000 Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============1504350382==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============1504350382== Content-Type: multipart/alternative; boundary=94eb2c19e11cef96e6054064d076 --94eb2c19e11cef96e6054064d076 Content-Type: text/plain; charset=UTF-8 On Thu, 3 Nov 2016, 08:39 Jeroen Wiert Pluimers, wrote: I've tried to find instructions on how to build a monolithic libssh2.dll on Windows using Visual Studio. I don't mind coming up with a good wiki page on building on Windows using Visual Studio (2015 or newer) but the hints I find on-line on how to get going are - ehm - dense or lacking. So far I've come up with a two batch files in https://gist.github.com/jpluimers/2bf514d658488a7ddfc189b0677a3a57 The first in the text of the gist compiles with WinCNG but the libssh2.dll lacks things that web-site mentions are supported like ciphers (aes128-ctr, aes256-ctr, aes192-ctr) and MAC algorithms (hmac-ripemd160, hmac-ripemd160@openssh.com). A separate batch file in the gist shows the kinds of things I've tried to make monolithic Win64/Win32 versions of libssh2.dll to no avail. I notice you tried to link statically against OpenSSL from slproweb. I'm not sure they contain static libs for Visual Studio 2015 (or at all), so you might need to compile your own. FWIW, I use the hunter package manager to compile everything into a monolithic binary: https://github.com/ruslo/hunter Alex --94eb2c19e11cef96e6054064d076 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On Thu, 3 Nov 2016, 08:39 Je= roen Wiert Pluimers, <jeroen.pluimers.com+libssh2.org@gmail.co= m> wrote:
I've tried to find ins= tructions on how to build a monolithic libssh2.dll on Windows using Visual = Studio.

I don't mind coming up with a good= wiki page on building on Windows using Visual Studio (2015 or newer) but t= he hints I find on-line on how to get going are - ehm - dense or lacking.

So far I've come up with a two batch files in=C2=A0https://gist.github.com/jpluimers/2bf5= 14d658488a7ddfc189b0677a3a57

The first in the text of the gis= t compiles with WinCNG but the libssh2.dll lacks things that web-site menti= ons are supported like ciphers (aes128-ctr, aes256-ctr, aes192-ctr) and MAC= algorithms (hmac-ripemd160, hmac-ripemd160@openssh.com).

A separate batch file in the gist shows the kinds of things I've = tried to make monolithic Win64/Win32 versions of libssh2.dll to no avail.

I notice you tried to link statically aga= inst OpenSSL from slproweb. I'm not sure they contain static libs for V= isual Studio 2015 (or at all), so you might need to compile your own. FWIW,= I use the hunter package manager to compile everything into a monolithic b= inary:=C2=A0https://github.com/ruslo/hunter

Alex
--94eb2c19e11cef96e6054064d076-- --===============1504350382== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============1504350382==-- From libssh2-devel-bounces@cool.haxx.se Thu Nov 3 17:08:54 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA3G8S6t000619; Thu, 3 Nov 2016 17:08:49 +0100 Received: from mail-wm0-x22f.google.com (mail-wm0-x22f.google.com [IPv6:2a00:1450:400c:c09:0:0:0:22f]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA3G8QNc030745 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 3 Nov 2016 17:08:27 +0100 Received: by mail-wm0-x22f.google.com with SMTP id c184so4370744wmd.0 for ; Thu, 03 Nov 2016 09:08:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=5ARs4bKd+vU6Hlxg3jdSx3vheFooNuN5egtVeDX4WCo=; b=Iu3/xNhF9gGdBjSThT//iZHWJlNWrFcS6ZJSVYayh9709AXz8aXUSAfzgI0+tnXfeV ZaNF6NUky9bLo2nPwUjd6nNXfnPz8P38TBt1iIwM7bd/BgYkHYEtbwFDqh5ZtSH33KNG h0evu1Xvw/+FHZROMurfjIvs9zoY9lsJqFJT4hoNI8z6IjdvR8yDV55UIa/1uirIpn7z +f9yoL8ChYq6JFkENYxa55jos7XIsoooNst0tWsgyFA8KZueMcITHcuPoLogM7VraZdw 0LktR2xrKh3CRUyKl+21Y1R0F0Jw5WZFLIAg7cVH0MkfjCoidAyRtqJFZq9Hdjya5R8j 9k3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=5ARs4bKd+vU6Hlxg3jdSx3vheFooNuN5egtVeDX4WCo=; b=Rii2ncKvYeaaM/orvnnwHSbhhN0tPMNM1i7b+c63UbrZpyai1HjDH93M/Eqf4tx7PY aTrhKDZvATfiVmk1LEuiUCk3aBuJi3I/OxAC/Q6Qi7TYKcqTRa1n+MskQH3XzWvsfBGZ 6A9B9ay4m84qDmas5oxRRaugS2PuVdIhb/m/G7lu/DFlRyrnhUvvnIJZehOPhFXph2CV cXZm182B3I9kWmitunG6IM4+M4QKJ0u49NyYsXRD0o2OZexagPMMZvxHnShhXzl95ogg ejN6s+qI9jMicCKcOIZHye5Dh2e8INrdxXblrb9OMJPsTwrm547WFWCdQdspY1A0lxh7 1uhQ== X-Gm-Message-State: ABUngvefYH3zEYx8nHdBiJ9ZWl93j5lbbZezFtOXadJ1LUH/lf12W/O/wLUJ+EFMAZPFYy2v2o+LK8ICbqD+tw== X-Received: by 10.195.12.42 with SMTP id en10mr7759921wjd.126.1478189302491; Thu, 03 Nov 2016 09:08:22 -0700 (PDT) MIME-Version: 1.0 Received: by 10.194.134.129 with HTTP; Thu, 3 Nov 2016 09:07:51 -0700 (PDT) In-Reply-To: References: From: Jeroen Wiert Pluimers Date: Thu, 3 Nov 2016 17:07:51 +0100 X-Google-Sender-Auth: ZzObeqn96LPqWyeKIqUnlxnqxy4 Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============1842037433==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============1842037433== Content-Type: multipart/alternative; boundary=047d7bfd017c4930d6054067c4c1 --047d7bfd017c4930d6054067c4c1 Content-Type: text/plain; charset=UTF-8 On Thu, Nov 3, 2016 at 1:36 PM, Alexander Lamaison wrote: > > I notice you tried to link statically against OpenSSL from slproweb. I'm > not sure they contain static libs for Visual Studio 2015 (or at all), so > you might need to compile your own. FWIW, I use the hunter package manager > to compile everything into a monolithic binary: https://github.com/ > ruslo/hunter > Thanks. They slprobweb downloads contain static libs and are in fact recommended at the top of the list https://wiki.openssl.org/index.php/Binaries Any steps on how to get started with hunter (not wanting to re-invent the wheel again). Regards, --jeroen --047d7bfd017c4930d6054067c4c1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Thu, Nov 3, 2016 at 1:36 PM, Alexander Lamaison &l= t;swish@lammy.co.uk<= /a>> wrote:
=
<= /span>

T= hanks.

They slprobweb downloads contain static lib= s and are in fact recommended at the top of the list=C2=A0https://wiki.openssl.org/index.php/B= inaries

Any steps on how to get started with h= unter (not wanting to re-invent the wheel again).

= Regards,

--jeroen

=
--047d7bfd017c4930d6054067c4c1-- --===============1842037433== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============1842037433==-- From libssh2-devel-bounces@cool.haxx.se Thu Nov 3 19:15:05 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA3IEiMr020625; Thu, 3 Nov 2016 19:15:00 +0100 Received: from mail-lf0-f46.google.com (mail-lf0-f46.google.com [209.85.215.46]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA3IEhxk020510 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 3 Nov 2016 19:14:43 +0100 Received: by mail-lf0-f46.google.com with SMTP id t196so46278148lff.3 for ; Thu, 03 Nov 2016 11:14:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=Qg11M/MWnSLQB5I/jHEjz+i/1bP5G5bTdNEEamoHR1s=; b=dqrUCkfx3d8a3Ag5afrqo+zFTn7LFIIipF1UKUyO5AlYiat0sdK2I23vTPargs8dQz GZs0Ll62WQlVwPV81JiWWNK157k2BwG32KaEaH71iCz5Fbdjfy+/XumHkL+Plfa26pW2 UF8DUMxIyYXtmpFhp9sfaBLqwx1nhpX/hseUEfeXDWd3MIDMcC3eYN7zqCTq5vyXT/ZX xuATZ6JnT77/PNnfkJ6jOhUsQSqjXVx6WNnRMj4O0f+YOPsZPyD81CjxVj7vB4bKbK3l Lf2yTVYjOOgQcv8dJhrX+pO7AAITJBmT1HidUcJN3nhl/SzGMCfm5xJ5gu+MVBgdOg0s ziSA== X-Gm-Message-State: ABUngvf+aFO83pLnNWNiwHjk5OHuVQA+wbfGPV/Cjvx4cvu3c+YCX5xog7bcSmPoH/5Ucan/R5tLaG/HkGtXxQ== X-Received: by 10.25.163.132 with SMTP id m126mr6625897lfe.9.1478196878867; Thu, 03 Nov 2016 11:14:38 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Alexander Lamaison Date: Thu, 03 Nov 2016 18:14:28 +0000 Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============1355519235==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============1355519235== Content-Type: multipart/alternative; boundary=001a11411b1cdf82fe0540698752 --001a11411b1cdf82fe0540698752 Content-Type: text/plain; charset=UTF-8 On Thu, 3 Nov 2016, 16:09 Jeroen Wiert Pluimers, wrote: > On Thu, Nov 3, 2016 at 1:36 PM, Alexander Lamaison > wrote: > > > I notice you tried to link statically against OpenSSL from slproweb. I'm > not sure they contain static libs for Visual Studio 2015 (or at all), so > you might need to compile your own. FWIW, I use the hunter package manager > to compile everything into a monolithic binary: > https://github.com/ruslo/hunter > > > Thanks. > > They slprobweb downloads contain static libs and are in fact recommended > at the top of the list https://wiki.openssl.org/index.php/Binaries > But when you built libssh2 for OpenSSL and passed OPENSSL_USE_STATIC_LIBS=ON to CMake, it still linked dynamically? If so that is either a bug in CMake's FindOpenSSL.cmake, or the static libs in slproweb are not for Visual Studio 2015. > > Any steps on how to get started with hunter (not wanting to re-invent the > wheel again). > You just include the huntergate snippet in your root CMakeLists.txt and add a call to hunter_add_package for each package you use via find_package. Then run CMake. It will download and install everything. I.e add hunter_add_package(Libssh2). --001a11411b1cdf82fe0540698752 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On Thu, 3 Nov 2016, 16:= 09 Jeroen Wiert Pluimers, <jeroen= .pluimers.com+libssh2.org@gmai= l.com> wrote:
On Thu, Nov 3, 2016 at 1:36 PM, Alexander Lamaison <swish@lammy.co.uk> wr= ote:

<= /span>
I notice you tried to link statically against OpenSSL from sl= proweb. I'm not sure they contain static libs for Visual Studio 2015 (o= r at all), so you might need to compile your own. FWIW, I use the hunter pa= ckage manager to compile everything into a monolithic binary:=C2=A0https://github.co= m/ruslo/hunter

Thanks.

They slprobweb downloads contain sta= tic libs and are in fact recommended at the top of the list=C2=A0https://wiki.openssl.org/index.php/Binaries

= But when you built libssh2 for OpenSSL and passed OPENSSL_USE_STATIC_LIBS= =3DON to CMake, it still linked dynamically? If so that is either a bug in = CMake's FindOpenSSL.cmake, or the static libs in slproweb are not for V= isual Studio 2015.

Any steps on how to get sta= rted with hunter (not wanting to re-invent the wheel again).

You just include the hunter= gate snippet in your root CMakeLists.txt and add a call to hunter_add_packa= ge for each package you use via find_package. Then run CMake. It will downl= oad and install everything. I.e add hunter_add_package(Libssh2).
--001a11411b1cdf82fe0540698752-- --===============1355519235== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============1355519235==-- From libssh2-devel-bounces@cool.haxx.se Fri Nov 4 00:37:36 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA3NbDx9001408; Fri, 4 Nov 2016 00:37:31 +0100 Received: from mail-wm0-x235.google.com (mail-wm0-x235.google.com [IPv6:2a00:1450:400c:c09:0:0:0:235]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA3NbBK5001268 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 4 Nov 2016 00:37:11 +0100 Received: by mail-wm0-x235.google.com with SMTP id n67so17750895wme.1 for ; Thu, 03 Nov 2016 16:37:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=+DrAdhRvtoo3a9uMftov12iUwTXKUqPX/VFbz73a/Hk=; b=FUPgb4n15sTh2eOFyeyrFk5NcuHU3ihWb+OQV1PFC6ab1o6SE7Ka45emr0PsZIfDSL D2qyWu8p/DqxD7OpxQhXp+TwC3wyVynssPmb5F4RKMbm59I0OYLi2j3O+VnuPjDoXrNg pgyzhTs+cfkFZ+B6L/QRc7nw0rQ9P/hPiKqthrm2azl5v3b7XSW8hu2Qi6U8QydTjLXp TK5YdF0K0nl9TujhikS4uPYJnz7yFMFW4ryncVuJvDea6qCm67DyIWekiPSYiafgt8VL XwXiBqycuxklfALio+ppldn07jzyTCZ81OG4TWSN36wqPkwzTw5Tp/GkUTjCCFFSW7LT 7Big== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=+DrAdhRvtoo3a9uMftov12iUwTXKUqPX/VFbz73a/Hk=; b=O12BoMyzzjwZPDn3E056aBSPYg6WFkAVQXoajm4B8jQdOZGBTy7ah/jfh3WhZJkQ8g ek9C/PUJFEJRpvmDpCYQkJymRIP/CZ4/uPdoUM3FcsEnWpNrByWJaVOVc7KXTNVCNDFE Un4r4ScprzhRFViruz37Til/hwQ4jdyjt6fV/oSfW8Ql+UZ7QTTJDamUmjQ7nuawIyf5 WFTSRpQlORVhzCOFp0k6aORcpAzxK51g47AiRaKPXpbcawpejrIVqzNOD3UmxhxYdr8Q wfIXIqywH1IDGFVoNvosiR3gVTkdNM+ChrlX+zW19Kakx7sohDmlfRqk0KLyIsB7ETLG tk7w== X-Gm-Message-State: ABUngvdpGsnhwAPvlCTNVvcvuf3DTg94csOw8vimnuR/2fMF1DyuKhR7VMAR7cjk0dtnllZsCRYG2wby/ZEk4Q== X-Received: by 10.28.169.74 with SMTP id s71mr451101wme.1.1478216227082; Thu, 03 Nov 2016 16:37:07 -0700 (PDT) MIME-Version: 1.0 Received: by 10.194.134.129 with HTTP; Thu, 3 Nov 2016 16:36:36 -0700 (PDT) In-Reply-To: References: From: Jeroen Wiert Pluimers Date: Fri, 4 Nov 2016 00:36:36 +0100 X-Google-Sender-Auth: dSOgHYXXMDohVmSmAjaHSXIsvXE Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============0245121212==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============0245121212== Content-Type: multipart/alternative; boundary=001a114ba8541dd5cd05406e098c --001a114ba8541dd5cd05406e098c Content-Type: text/plain; charset=UTF-8 On Thu, Nov 3, 2016 at 7:14 PM, Alexander Lamaison wrote: > > On Thu, 3 Nov 2016, 16:09 Jeroen Wiert Pluimers, libssh2.org@gmail.com> wrote: > >> >> The slprobweb downloads contain static libs and are in fact recommended >> at the top of the list https://wiki.openssl.org/index.php/Binaries >> > > But when you built libssh2 for OpenSSL and passed > OPENSSL_USE_STATIC_LIBS=ON to CMake, it still linked dynamically? If so > that is either a bug in CMake's FindOpenSSL.cmake, or the static libs in > slproweb are not for Visual Studio 2015. > Below are the lib files; the lib\VC\static ones are the ones I want to use. I'll give it one more shot before the EKON conference and when it fails I will either go the hunter way or help Bert with https://github.com/Microsoft/vcpkg CMake finds the libraries but doesn't tell which one it uses: -- Found OpenSSL: optimized;C:/OpenSSL-Win64/lib/ssleay32.lib;debug;C:/OpenSSL-Win64/lib/VC/static/ssleay32MTd.lib;optimized;C:/OpenSSL-Win64/lib/libeay32.lib;debug;C:/OpenSSL-Win64/lib/VC/static/libeay32MTd.lib (found version "1.0.2j") -- Found OpenSSL: optimized;C:/OpenSSL-Win32/lib/ssleay32.lib;debug;C:/OpenSSL-Win32/lib/VC/static/ssleay32MTd.lib;optimized;C:/OpenSSL-Win32/lib/libeay32.lib;debug;C:/OpenSSL-Win32/lib/VC/static/libeay32MTd.lib (found version "1.0.2j") The odd thing is that CMake - despite specifying Release - seems to pick the Debug static libraries (*MTd.lib) cmake .. -G"Visual Studio 14 Win64" -D"BUILD_SHARED_LIBS=1" -D"CMAKE_BUILD_TYPE=Release" -D"CRYPTO_BACKEND=OpenSSL" -D"OPENSSL_USE_STATIC_LIBS=TRUE" -D"OPENSSL_MSVC_STATIC_RT=TRUE" cmake .. -G"Visual Studio 14" -D"BUILD_SHARED_LIBS=1" -D"CMAKE_BUILD_TYPE=Release" -D"CRYPTO_BACKEND=OpenSSL" -D"OPENSSL_USE_STATIC_LIBS=TRUE" -D"OPENSSL_MSVC_STATIC_RT=TRUE" The compiler output is so huge however that I have a tree/woods problem in not knowing what else to look for. In case someone knows, here is the build output: https://gist.github.com/jpluimers/040c91af087b8afe4ce551e83279acc9 C:\OpenSSL-Win32\lib C:\OpenSSL-Win32\lib\4758cca.lib C:\OpenSSL-Win32\lib\aep.lib C:\OpenSSL-Win32\lib\atalla.lib C:\OpenSSL-Win32\lib\capi.lib C:\OpenSSL-Win32\lib\chil.lib C:\OpenSSL-Win32\lib\cswift.lib C:\OpenSSL-Win32\lib\gmp.lib C:\OpenSSL-Win32\lib\gost.lib C:\OpenSSL-Win32\lib\libeay32.lib C:\OpenSSL-Win32\lib\MinGW C:\OpenSSL-Win32\lib\nuron.lib C:\OpenSSL-Win32\lib\padlock.lib C:\OpenSSL-Win32\lib\ssleay32.lib C:\OpenSSL-Win32\lib\sureware.lib C:\OpenSSL-Win32\lib\ubsec.lib C:\OpenSSL-Win32\lib\VC C:\OpenSSL-Win32\lib\MinGW\libeay32.a C:\OpenSSL-Win32\lib\MinGW\libeay32.def C:\OpenSSL-Win32\lib\MinGW\ssleay32.a C:\OpenSSL-Win32\lib\MinGW\ssleay32.def C:\OpenSSL-Win32\lib\VC\libeay32MD.lib C:\OpenSSL-Win32\lib\VC\libeay32MDd.lib C:\OpenSSL-Win32\lib\VC\libeay32MT.lib C:\OpenSSL-Win32\lib\VC\libeay32MTd.lib C:\OpenSSL-Win32\lib\VC\ssleay32MD.lib C:\OpenSSL-Win32\lib\VC\ssleay32MDd.lib C:\OpenSSL-Win32\lib\VC\ssleay32MT.lib C:\OpenSSL-Win32\lib\VC\ssleay32MTd.lib C:\OpenSSL-Win32\lib\VC\static C:\OpenSSL-Win32\lib\VC\static\libeay32MD.lib C:\OpenSSL-Win32\lib\VC\static\libeay32MDd.lib C:\OpenSSL-Win32\lib\VC\static\libeay32MT.lib C:\OpenSSL-Win32\lib\VC\static\libeay32MTd.lib C:\OpenSSL-Win32\lib\VC\static\ssleay32MD.lib C:\OpenSSL-Win32\lib\VC\static\ssleay32MDd.lib C:\OpenSSL-Win32\lib\VC\static\ssleay32MT.lib C:\OpenSSL-Win32\lib\VC\static\ssleay32MTd.lib C:\OpenSSL-Win64\lib C:\OpenSSL-Win64\lib\4758cca.lib C:\OpenSSL-Win64\lib\aep.lib C:\OpenSSL-Win64\lib\atalla.lib C:\OpenSSL-Win64\lib\capi.lib C:\OpenSSL-Win64\lib\chil.lib C:\OpenSSL-Win64\lib\cswift.lib C:\OpenSSL-Win64\lib\gmp.lib C:\OpenSSL-Win64\lib\gost.lib C:\OpenSSL-Win64\lib\libeay32.lib C:\OpenSSL-Win64\lib\nuron.lib C:\OpenSSL-Win64\lib\padlock.lib C:\OpenSSL-Win64\lib\ssleay32.lib C:\OpenSSL-Win64\lib\sureware.lib C:\OpenSSL-Win64\lib\ubsec.lib C:\OpenSSL-Win64\lib\VC C:\OpenSSL-Win64\lib\VC\libeay32MD.lib C:\OpenSSL-Win64\lib\VC\libeay32MDd.lib C:\OpenSSL-Win64\lib\VC\libeay32MT.lib C:\OpenSSL-Win64\lib\VC\libeay32MTd.lib C:\OpenSSL-Win64\lib\VC\ssleay32MD.lib C:\OpenSSL-Win64\lib\VC\ssleay32MDd.lib C:\OpenSSL-Win64\lib\VC\ssleay32MT.lib C:\OpenSSL-Win64\lib\VC\ssleay32MTd.lib C:\OpenSSL-Win64\lib\VC\static C:\OpenSSL-Win64\lib\VC\static\libeay32MD.lib C:\OpenSSL-Win64\lib\VC\static\libeay32MDd.lib C:\OpenSSL-Win64\lib\VC\static\libeay32MT.lib C:\OpenSSL-Win64\lib\VC\static\libeay32MTd.lib C:\OpenSSL-Win64\lib\VC\static\ssleay32MD.lib C:\OpenSSL-Win64\lib\VC\static\ssleay32MDd.lib C:\OpenSSL-Win64\lib\VC\static\ssleay32MT.lib C:\OpenSSL-Win64\lib\VC\static\ssleay32MTd.lib > Any steps on how to get started with hunter (not wanting to re-invent the >> wheel again). >> > > You just include the huntergate snippet in your root CMakeLists.txt and > add a call to hunter_add_package for each package you use via find_package. > Then run CMake. It will download and install everything. I.e add > hunter_add_package(Libssh2). > I'm a total n00b at CMake. Is there a good introduction somewhere? Regards, --jeroen --001a114ba8541dd5cd05406e098c Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Thu, Nov 3, 2016 at 7:14 PM, Alexander Lamaison &l= t;swish@lammy.co.uk<= /a>> wrote:
=

The slprobweb downloads contain static libs and are in fact recommen= ded at the top of the list=C2=A0https://wiki.openssl.org/index.php/Binaries

But when you built libssh2 for OpenSSL a= nd passed OPENSSL_USE_STATIC_LIBS=3DON to CMake, it still linked dynamicall= y? If so that is either a bug in CMake's FindOpenSSL.cmake, or the stat= ic libs in slproweb are not for Visual Studio 2015.
=
Below are the lib files; the lib\VC\static ones are the ones= I want to use. I'll give it one more shot before the EKON conference a= nd when it fails I will either go the hunter way or help Bert with=C2=A0https://github.com/Microsoft/vc= pkg

CMake finds the libraries but doesn't = tell which one it uses:
-- Found OpenSSL: optimized;C:/OpenSSL-Wi= n64/lib/ssleay32.lib;debug;C:/OpenSSL-Win64/lib/VC/static/ssleay32MTd.lib;o= ptimized;C:/OpenSSL-Win64/lib/libeay32.lib;debug;C:/OpenSSL-Win64/lib/VC/st= atic/libeay32MTd.lib (found version "1.0.2j")
-- Fo= und OpenSSL: optimized;C:/OpenSSL-Win32/lib/ssleay32.lib;debug;C:/OpenSSL-W= in32/lib/VC/static/ssleay32MTd.lib;optimized;C:/OpenSSL-Win32/lib/libeay32.= lib;debug;C:/OpenSSL-Win32/lib/VC/static/libeay32MTd.lib (found version &qu= ot;1.0.2j")

The odd thing is that CMake -= despite specifying Release - seems to pick the Debug static libraries (*MT= d.lib)

cmake .. -G"Visual Studio 14 Win64&quo= t; -D"BUILD_SHARED_LIBS=3D1" -D"CMAKE_BUILD_TYPE=3DRelease&q= uot; -D"CRYPTO_BACKEND=3DOpenSSL" -D"OPENSSL_USE_STATIC_LIBS= =3DTRUE" -D"OPENSSL_MSVC_STATIC_RT=3DTRUE"
cma= ke .. -G"Visual Studio 14" -D"BUILD_SHARED_LIBS=3D1" -D= "CMAKE_BUILD_TYPE=3DRelease" -D"CRYPTO_BACKEND=3DOpenSSL&quo= t; -D"OPENSSL_USE_STATIC_LIBS=3DTRUE" -D"OPENSSL_MSVC_STATIC= _RT=3DTRUE"

The compiler output is so hug= e however that I have a tree/woods problem in not knowing what else to look= for.

In case someone knows, here is the build out= put: https://gist.github.com/jpluimers/040c91af087b8afe4ce551e83279acc9=

C:\OpenSSL-Win32\lib
C:\Op= enSSL-Win32\lib\4758cca.lib
C:\OpenSSL-Win32\lib\aep.lib
C:\OpenSSL-Win32\lib\atalla.lib
C:\OpenSSL-Win32\lib\capi.lib
C:\OpenSSL-Win32\lib\chil.lib
C:\OpenSSL-Win32\lib\cswif= t.lib
C:\OpenSSL-Win32\lib\gmp.lib
C:\OpenSSL-Win32\lib= \gost.lib
C:\OpenSSL-Win32\lib\libeay32.lib
C:\OpenSSL-= Win32\lib\MinGW
C:\OpenSSL-Win32\lib\nuron.lib
C:\OpenS= SL-Win32\lib\padlock.lib
C:\OpenSSL-Win32\lib\ssleay32.lib
<= div>C:\OpenSSL-Win32\lib\sureware.lib
C:\OpenSSL-Win32\lib\ubsec.= lib
C:\OpenSSL-Win32\lib\VC
C:\OpenSSL-Win32\lib\MinGW\= libeay32.a
C:\OpenSSL-Win32\lib\MinGW\libeay32.def
C:\O= penSSL-Win32\lib\MinGW\ssleay32.a
C:\OpenSSL-Win32\lib\MinGW\ssle= ay32.def
C:\OpenSSL-Win32\lib\VC\libeay32MD.lib
C:\Open= SSL-Win32\lib\VC\libeay32MDd.lib
C:\OpenSSL-Win32\lib\VC\libeay32= MT.lib
C:\OpenSSL-Win32\lib\VC\libeay32MTd.lib
C:\OpenS= SL-Win32\lib\VC\ssleay32MD.lib
C:\OpenSSL-Win32\lib\VC\ssleay32MD= d.lib
C:\OpenSSL-Win32\lib\VC\ssleay32MT.lib
C:\OpenSSL= -Win32\lib\VC\ssleay32MTd.lib
C:\OpenSSL-Win32\lib\VC\static
C:\OpenSSL-Win32\lib\VC\static\libeay32MD.lib
C:\OpenSSL-Wi= n32\lib\VC\static\libeay32MDd.lib
C:\OpenSSL-Win32\lib\VC\static\= libeay32MT.lib
C:\OpenSSL-Win32\lib\VC\static\libeay32MTd.lib
C:\OpenSSL-Win32\lib\VC\static\ssleay32MD.lib
C:\OpenSSL-W= in32\lib\VC\static\ssleay32MDd.lib
C:\OpenSSL-Win32\lib\VC\static= \ssleay32MT.lib
C:\OpenSSL-Win32\lib\VC\static\ssleay32MTd.lib
C:\OpenSSL-Win64\lib
C:\OpenSSL-Win64\lib\4758cca.lib
C:\OpenSSL-Win64\lib\aep.lib
C:\OpenSSL-Win64\lib\atalla.l= ib
C:\OpenSSL-Win64\lib\capi.lib
C:\OpenSSL-Win64\lib\c= hil.lib
C:\OpenSSL-Win64\lib\cswift.lib
C:\OpenSSL-Win6= 4\lib\gmp.lib
C:\OpenSSL-Win64\lib\gost.lib
C:\OpenSSL-= Win64\lib\libeay32.lib
C:\OpenSSL-Win64\lib\nuron.lib
C= :\OpenSSL-Win64\lib\padlock.lib
C:\OpenSSL-Win64\lib\ssleay32.lib=
C:\OpenSSL-Win64\lib\sureware.lib
C:\OpenSSL-Win64\lib= \ubsec.lib
C:\OpenSSL-Win64\lib\VC
C:\OpenSSL-Win64\lib= \VC\libeay32MD.lib
C:\OpenSSL-Win64\lib\VC\libeay32MDd.lib
<= div>C:\OpenSSL-Win64\lib\VC\libeay32MT.lib
C:\OpenSSL-Win64\lib\V= C\libeay32MTd.lib
C:\OpenSSL-Win64\lib\VC\ssleay32MD.lib
C:\OpenSSL-Win64\lib\VC\ssleay32MDd.lib
C:\OpenSSL-Win64\lib\VC= \ssleay32MT.lib
C:\OpenSSL-Win64\lib\VC\ssleay32MTd.lib
C:\OpenSSL-Win64\lib\VC\static
C:\OpenSSL-Win64\lib\VC\static\li= beay32MD.lib
C:\OpenSSL-Win64\lib\VC\static\libeay32MDd.lib
=
C:\OpenSSL-Win64\lib\VC\static\libeay32MT.lib
C:\OpenSSL-Win= 64\lib\VC\static\libeay32MTd.lib
C:\OpenSSL-Win64\lib\VC\static\s= sleay32MD.lib
C:\OpenSSL-Win64\lib\VC\static\ssleay32MDd.lib
C:\OpenSSL-Win64\lib\VC\static\ssleay32MT.lib
C:\OpenSSL-Wi= n64\lib\VC\static\ssleay32MTd.lib
=C2=A0
Any steps on how to get started with hunter (not wanting to re-in= vent the wheel again).

<= /div>
You just include the huntergate snippet in your root CMake= Lists.txt and add a call to hunter_add_package for each package you use via= find_package. Then run CMake. It will download and install everything. I.e= add hunter_add_package(Libssh2).

I&#= 39;m a total n00b at CMake. Is there a good introduction somewhere?

Regards,

--jeroen
--001a114ba8541dd5cd05406e098c-- --===============0245121212== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============0245121212==-- From libssh2-devel-bounces@cool.haxx.se Sat Nov 5 11:38:39 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA5AcArd010149; Sat, 5 Nov 2016 11:38:33 +0100 Received: from giant.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA5Ac8fZ010141 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sat, 5 Nov 2016 11:38:08 +0100 Received: from localhost (dast@localhost) by giant.haxx.se (8.15.2/8.15.2/Submit) with ESMTP id uA5Ac8Mj010137 for ; Sat, 5 Nov 2016 11:38:08 +0100 X-Authentication-Warning: giant.haxx.se: dast owned process doing -bs Date: Sat, 5 Nov 2016 11:38:08 +0100 (CET) From: Daniel Stenberg X-X-Sender: dast@giant.haxx.se To: libssh2 development Subject: energy boost? Message-ID: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) X-fromdanielhimself: yes MIME-Version: 1.0 X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8"; Format="flowed" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA5AcArd010149 Hi friends, We've been stalling in this project lately[1]. We get pull requests and issues filed, but they mostly just accumulate without being dealt with. I am of course personally guilty of this neglect but I'm not alone. I'm interested in hearing what you all think we can do to up our game. I've spent almost exactly ten years in this project and I've done 769 source code commits to date, but these days libssh2 is not a priority in my life anymore. I don't plan to run away or hide, but I am interested in seeing others step up their game to help driving the project forward so that I can remain in a backseat position without having the project suffer. [1] = https://www.openhub.net/p/libssh2/contributors/summary -- / daniel.haxx.se _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 5 23:25:21 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA5MOo9t023691; Sat, 5 Nov 2016 23:25:15 +0100 Received: from mail-lf0-x22c.google.com (mail-lf0-x22c.google.com [IPv6:2a00:1450:4010:c07:0:0:0:22c]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA5MOn7I023670 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 5 Nov 2016 23:24:49 +0100 Received: by mail-lf0-x22c.google.com with SMTP id c13so88283646lfg.0 for ; Sat, 05 Nov 2016 15:24:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=B/FXYVY9Die5VxH+yYMoOAp5ImalMSqdAar9wQBLhrY=; b=cz9K6RsPtjart9k7P1u0COklzKX9OIHzBmcZnG3PhiXdfLU1VCIvFXi4/7BWKJj8ql 5lPfOGc+07PJ/KvPgJ6LyzvEvAna5nNBwknzPBg0x2f2xlpXpavghwuWYuK2HHfCE1rN G+4cyHAqJ9Zzal5NXY95lMLypflY8eqRNRHtt3PYGkBKiQ5aGVikMnw8tf9Nltd7BPwM oQP21Ld3GQ16qbjx4vruQwoWiOtdfHcL3USIDP3fU1lERmM2OtMX3ZUiGQi06Gelsj+3 odQHf02FMGCvDSRej/DKEMiQba+Zee+f4WGa9GIgOmzWk4GtVOZPv1wuHmWTgrEKFPS0 Ms1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=B/FXYVY9Die5VxH+yYMoOAp5ImalMSqdAar9wQBLhrY=; b=bctNaWe3QKceITrGhg3AFVNLHXKI4kB75dwOeIuRD4pfkIVKZ04CGeN7FRd5PdZERB DL0cCYizR6LMDBcU1kP4lDWqcMGgyqkrSKWBlSvOV0V2EPQDlqSAtebDREHBkAw0R7Wn rFPX6tX0qWTNHnHWWY8vC1Es9wit0l/3iqodfyLrpOzPxUZMQtZClFoAQEvgQG+4FU0L 6RyiPaYjf9QG4cF55zJw2SbLGjPXmWm57QHaVx3MlBqTd97RzNjEQ8/H/bYyhDwBxD3e io3hrgOUQ8RbnKOHXkmFfKG8v/da+W9tfibRRuWMfVN/2meTZ9nDRhMQDV4v5ntpfP3W ZH4Q== X-Gm-Message-State: ABUngvecVKazIFVrFLaMMeWOgy95XwrJOvPzasfm7CYPO4mOHClxgq+P4LdSKE/rT5gC6UGzfn6sw2UQ+unM0g== X-Received: by 10.25.190.79 with SMTP id o76mr15107lff.56.1478384685022; Sat, 05 Nov 2016 15:24:45 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 5 Nov 2016 15:24:44 -0700 (PDT) In-Reply-To: <1477600475-18709-1-git-send-email-peter@stuge.se> References: <1477600475-18709-1-git-send-email-peter@stuge.se> From: Alexander Lamaison Date: Sat, 5 Nov 2016 22:24:44 +0000 X-Google-Sender-Auth: YoasEMRfURMuLbvCOtNE3FCxCp4 Message-ID: Subject: Re: A handful simple fixes To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA5MOo9t023691 On 27 October 2016 at 21:34, Peter Stuge wrote: > Here's a set with a few unrelated fixes. ...snip Applied to repo in github. Thanks Peter. -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 5 23:32:49 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA5MWiNA028168; Sat, 5 Nov 2016 23:32:48 +0100 Received: from mail-lf0-x234.google.com (mail-lf0-x234.google.com [IPv6:2a00:1450:4010:c07:0:0:0:234]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA5MWgAQ028150 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 5 Nov 2016 23:32:43 +0100 Received: by mail-lf0-x234.google.com with SMTP id t196so88575081lff.3 for ; Sat, 05 Nov 2016 15:32:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=Y2HTjmbYSOLgpv+3gWtOW8g5AKjJCVa1ZhCO5Yt8PDE=; b=C2Bw07ZF2gluIl2CqRerfA3mfajryFsJvgUHOBBh1TLZSSWYmnnJ2vQLr3OYX5Y219 4uRZyjb2EtIvCvRQW9wnjTgjOhdLmICgs52z1GvaNb7e3uQyXTvlZJ9z06l3xDZbhznk bI3VzuGue3uv/hHNxeXM9BIlEIk/y0tVJ6MeB5ysd5RhLgmTTnfbLK76pvqOINNJXVMq N6kmE3xVqxjxeETD8lBY0tIM+7GqsXXugD71usY9zf5MQpAScXPppVhpmm9+1WSVYIuy TcIvBZmjbbe1PY3Pg6VRI9y1uHcf909XrWeSndYLOwPKAydwOyr4PMufgcIFQdqjLBqk au/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=Y2HTjmbYSOLgpv+3gWtOW8g5AKjJCVa1ZhCO5Yt8PDE=; b=HiolcuEz/nbgcYSg0rctQ8nXRBXvbDho/Y+9b2wn3roAKXzuUGTbuTjobq28jnoRDa G6u5tE3bYEzxbG65KzeImiwpUkX75IloeWYPnt0M9HoEvsNjw1iUpll+iRYCPFuHEk8D /t8KiJNW0Gw+9R6nnb/uvxDY5II2rk614oN4fD74D27b8SzdYFB4sMpg3XuYXWE08jaq TenNBeB/aMlwU98WQ61F8/aikDStDF5THQEM9OXtAg8I7UxZL5ptjHNIMMKAGCFoAre3 VOk+RO2rJ5Jkb1a1BTcxefVtgQSsA4hgX3XQ+2ym7QpK8jnJze7CQYLzmRQSv8xsHT2p d6WQ== X-Gm-Message-State: ABUngvc581whEsfbgQjWODDdW0oXSpoGcoYaixORsvRjcryft5+nDBA47mymVyoFtDOxCpHfTjh+JKG4MJNYHA== X-Received: by 10.25.129.148 with SMTP id c142mr20513lfd.136.1478385158924; Sat, 05 Nov 2016 15:32:38 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 5 Nov 2016 15:32:38 -0700 (PDT) In-Reply-To: <20161031132342.GA31660@foo.stuge.se> References: <20161027155339.GF20941@foo.stuge.se> <1477620557-1859-1-git-send-email-peter@stuge.se> <1477620557-1859-2-git-send-email-peter@stuge.se> <1973197.XhHmMWpa8C@kdudka-nb> <20161031132342.GA31660@foo.stuge.se> From: Alexander Lamaison Date: Sat, 5 Nov 2016 22:32:38 +0000 X-Google-Sender-Auth: CHmeCWjWoq7ZP-_K2vcilgU4h64 Message-ID: Subject: Re: [PATCH] configure.ac: Add single --with-crypto= instead of --with-$backend:s To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA5MWiNA028168 On 31 October 2016 at 13:23, Peter Stuge wrote: > Hi Kamil, > > Thanks a lot for testing this! > > Kamil Dudka wrote: >> The patch does not apply on the current upstream master branch, so I tested >> the withcrypto branch at http://git.stuge.se/libssh2.git (68b330d2). > > Yes - it applies on top of the handful simple fixes in my simple180 > branch, which I posted before. Sorry, should have made that more clear. I'm getting merge conflicts with master (which now contains your simple180 changes). Could you resolve them and repost? Thanks, Alex -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sun Nov 6 00:05:49 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA5N5b0Y006954; Sun, 6 Nov 2016 00:05:47 +0100 Received: from mail-lf0-x234.google.com (mail-lf0-x234.google.com [IPv6:2a00:1450:4010:c07:0:0:0:234]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA5N5Zv6005707 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sun, 6 Nov 2016 00:05:35 +0100 Received: by mail-lf0-x234.google.com with SMTP id o141so16533179lff.1 for ; Sat, 05 Nov 2016 16:05:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=m4zCDaf9IjsO10kuLab8iQeg82nsPhGLKpTO2a0A0Z8=; b=HiXIwspHgPxalaVvAfBWt/KsaHBbMU0Xc5qjJMba5qzOYAxwAdxgNcZg0qG7g8DQW5 xgE0OhYMvA6dzXJFZnEWX50Es1yVR7pkRZbA1vRDagoLoU7ykaq8Md4QwSUzEwngzmpx jBmctxaCecdbc+OSse5kUwgqhQXdpKxlfbgTOS//xvC1seal4UfPXTpYY+3SFk/4gjaE C2ZONAWNzMezLyU4NcGKPVxJxYztf45NLNzZZ9CtFxw/7PQrNadpy6Utl8YNo2NPYZ2s eeRFN6lfOc5Sy1HEvE8YI6v89cM5HIHKmO8QZD9pEVjSMkdvndIuI/BmD10xx7QDUwy2 8Dbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=m4zCDaf9IjsO10kuLab8iQeg82nsPhGLKpTO2a0A0Z8=; b=dkHgU/5rLFcErsUyfXVezug5XEZNepQzQHfvAjP2S9mwL1i6XB3q4Yp2a9xMloGLsT lrYstJPBHId8Fle7GH/GTVh7LT9E1ROGNRGPzJyy4K3ZQ8s8JxaL50NwBZ9yZehQkGMV 6hV9xrT0Fr9AB2n2dfUCLdS/LDEwE3LjMqbQbYbDJ9GH+dpWcpZkXpzsmnaIbmmGJRa/ YZIak5VWUujO3L7I8FA9lDmEwuJ4PEMv61ZWyTo1lyCI5LP7frnFMfwfHWNV5gQSuZRk H7NmRTTAHBPA2bGvplV0DBI6Oo+7NoWsgxh/dTODUQLFi7tZeZcxK+pNXK2ahUSn8lul b5fw== X-Gm-Message-State: ABUngvd8eWxZgZb5ftl6RIUBfsu7+oFgLlsIvGPE/P1vaRW3sRDtyRp1bEouxuz8SfCx0Eyso5NJZqvvk56e1g== X-Received: by 10.25.87.83 with SMTP id l80mr43221lfb.178.1478387131640; Sat, 05 Nov 2016 16:05:31 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 5 Nov 2016 16:05:30 -0700 (PDT) In-Reply-To: References: From: Alexander Lamaison Date: Sat, 5 Nov 2016 23:05:30 +0000 X-Google-Sender-Auth: bPa8xN8YDofdq14aALlY-UhA4dc Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA5N5b0Y006954 On 3 November 2016 at 23:36, Jeroen Wiert Pluimers wrote: > > > On Thu, Nov 3, 2016 at 7:14 PM, Alexander Lamaison > wrote: >> >> >> On Thu, 3 Nov 2016, 16:09 Jeroen Wiert Pluimers, >> wrote: >>> >>> >>> The slprobweb downloads contain static libs and are in fact recommended >>> at the top of the list https://wiki.openssl.org/index.php/Binaries >> >> >> But when you built libssh2 for OpenSSL and passed >> OPENSSL_USE_STATIC_LIBS=ON to CMake, it still linked dynamically? If so that >> is either a bug in CMake's FindOpenSSL.cmake, or the static libs in slproweb >> are not for Visual Studio 2015. > > > Below are the lib files; the lib\VC\static ones are the ones I want to use. > I'll give it one more shot before the EKON conference and when it fails I > will either go the hunter way or help Bert with > https://github.com/Microsoft/vcpkg > > CMake finds the libraries but doesn't tell which one it uses: > -- Found OpenSSL: > optimized;C:/OpenSSL-Win64/lib/ssleay32.lib;debug;C:/OpenSSL-Win64/lib/VC/static/ssleay32MTd.lib;optimized;C:/OpenSSL-Win64/lib/libeay32.lib;debug;C:/OpenSSL-Win64/lib/VC/static/libeay32MTd.lib > (found version "1.0.2j") > -- Found OpenSSL: > optimized;C:/OpenSSL-Win32/lib/ssleay32.lib;debug;C:/OpenSSL-Win32/lib/VC/static/ssleay32MTd.lib;optimized;C:/OpenSSL-Win32/lib/libeay32.lib;debug;C:/OpenSSL-Win32/lib/VC/static/libeay32MTd.lib > (found version "1.0.2j") > > The odd thing is that CMake - despite specifying Release - seems to pick the > Debug static libraries (*MTd.lib) When you say it seems to pick the debug static libraries, are you basing that on the lines you pasted above? Because that's not what they mean. When you configure a CMake project for Visual Studio, it generates a project file that can build both debug and release (you can toggle with the dropdown thingie) so when CMake looks for libraries for visual studio, it looks for both kinds. Essentially CMAKE_BUILD_TYPE is ignored. Now what _is_ interesting from the lines above is that you are getting static libraries for debug builds but dynamic libraries for release builds! I don't know what could cause that. Though I've just spotted a change in CMake 3.6 that might cause it [1]. Could you try with CMake 3.5.2 or older? If that doesn't work, did you perhaps configure it before in this directory some time previously? I suggest starting with a completely clean build directory. [1]: https://gitlab.kitware.com/cmake/cmake/commit/b148440381df0143a665b7ceebe8606a052e2cdf -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Mon Nov 7 03:26:26 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA72Pw8h009278; Mon, 7 Nov 2016 03:26:20 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA72Pv7M009112 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 7 Nov 2016 03:25:57 +0100 Received: (qmail 20800 invoked by uid 1000); 7 Nov 2016 03:11:31 -0000 Date: Mon, 7 Nov 2016 03:11:31 +0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: Re: [PATCH] configure.ac: Add single --with-crypto= instead of --with-$backend:s Message-ID: <20161107031131.GG31660@foo.stuge.se> References: <20161027155339.GF20941@foo.stuge.se> <1477620557-1859-1-git-send-email-peter@stuge.se> <1477620557-1859-2-git-send-email-peter@stuge.se> <1973197.XhHmMWpa8C@kdudka-nb> <20161031132342.GA31660@foo.stuge.se> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-MIME-Autoconverted: from quoted-printable to 8bit by giant.haxx.se id uA72Pv7M009112 X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: cynede@gentoo.org, siarheit@google.com Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA72Pw8h009278 Alexander Lamaison wrote: > I'm getting merge conflicts with master (which now contains your > simple180 changes). That's because of Sergei's commit ced924b7 which changes the libgcrypt checking in acinclude.m4 but overlooks the issues I had fixed. Sergei's commit however inspired me to do some more testing of my new code, and I found another problem with search prefixes, which I have also resolved; configure would only look in $prefix/lib64 when output from gcc -print-search-dirs includes any lib64 directory. > Could you resolve them and repost? I'll send it as a reply to this mail. I would appreciate a new round of testing, especially by Kamil, Mikhail and Sergei. Thanks //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Mon Nov 7 03:34:37 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA72YWw5000625; Mon, 7 Nov 2016 03:34:35 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA72YVwM032682 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 7 Nov 2016 03:34:31 +0100 Received: (qmail 21077 invoked from network); 7 Nov 2016 03:20:05 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 7 Nov 2016 03:20:05 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend Date: Mon, 7 Nov 2016 03:34:27 +0100 Message-Id: <1478486067-29645-1-git-send-email-peter@stuge.se> In-Reply-To: <20161107031131.GG31660@foo.stuge.se> References: <20161107031131.GG31660@foo.stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: cynede@gentoo.org, siarheit@google.com MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA72YWw5000625 The new --with-crypto option replaces the previous backend-specific --with-{openssl,libgcrypt,mbedtls,wincng} options and fixes some issues. * libgcrypt or mbedtls would previously be used whenever found, even if configure was passed --without-libgcrypt or --without-mbedtls. * If --with-$backend was specified then configure would not fail even if that library could not be found, and would instead use whichever crypto library was found first. The new option defaults to `auto`, which makes configure check for all supported crypto libraries in turn, choosing the first one found, or exiting with an error if none can be found. --- Makefile.OpenSSL.inc | 1 + Makefile.WinCNG.inc | 1 + Makefile.libgcrypt.inc | 1 + Makefile.mbedTLS.inc | 1 + acinclude.m4 | 127 ++++++++++++++++++++++---------------------- configure.ac | 139 ++++++++++++++++++++++++++++--------------------- docs/HACKING.CRYPTO | 27 ++++++++++ src/Makefile.am | 4 +- 8 files changed, 175 insertions(+), 126 deletions(-) diff --git a/Makefile.OpenSSL.inc b/Makefile.OpenSSL.inc index 76f3e85..1e4e8f0 100644 --- a/Makefile.OpenSSL.inc +++ b/Makefile.OpenSSL.inc @@ -1,2 +1,3 @@ CRYPTO_CSOURCES = openssl.c CRYPTO_HHEADERS = openssl.h +CRYPTO_LTLIBS = $(LTLIBSSL) diff --git a/Makefile.WinCNG.inc b/Makefile.WinCNG.inc index c18350e..bbcb82b 100644 --- a/Makefile.WinCNG.inc +++ b/Makefile.WinCNG.inc @@ -1,2 +1,3 @@ CRYPTO_CSOURCES = wincng.c CRYPTO_HHEADERS = wincng.h +CRYPTO_LTLIBS = $(LTLIBBCRYPT) $(LTLIBCRYPT32) diff --git a/Makefile.libgcrypt.inc b/Makefile.libgcrypt.inc index 5d56292..0a3aae9 100644 --- a/Makefile.libgcrypt.inc +++ b/Makefile.libgcrypt.inc @@ -1,2 +1,3 @@ CRYPTO_CSOURCES = libgcrypt.c CRYPTO_HHEADERS = libgcrypt.h +CRYPTO_LTLIBS = $(LTLIBGCRYPT) diff --git a/Makefile.mbedTLS.inc b/Makefile.mbedTLS.inc index 7e97864..c22e51a 100644 --- a/Makefile.mbedTLS.inc +++ b/Makefile.mbedTLS.inc @@ -1,2 +1,3 @@ CRYPTO_CSOURCES = mbedtls.c CRYPTO_HHEADERS = mbedtls.h +CRYPTO_LTLIBS = $(LTLIBMBEDTLS) diff --git a/acinclude.m4 b/acinclude.m4 index c78260c..e0bef46 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -382,86 +382,85 @@ AC_DEFUN([CURL_CONFIGURE_REENTRANT], [ # ]) -AC_DEFUN([LIBSSH2_CHECKFOR_MBEDTLS], [ +dnl LIBSSH2_LIB_HAVE_LINKFLAGS +dnl -------------------------- +dnl Wrapper around AC_LIB_HAVE_LINKFLAGS to also check $prefix/lib, if set. +dnl +dnl autoconf only checks $prefix/lib64 if gcc -print-search-dirs output +dnl includes a directory named lib64. So, to find libraries in $prefix/lib +dnl we append -L$prefix/lib to LDFLAGS before checking. +dnl +dnl For conveniece, $4 is expanded if [lib]$1 is found. - old_LDFLAGS=$LDFLAGS - old_CFLAGS=$CFLAGS - if test -n "$use_mbedtls" && test "$use_mbedtls" != "no"; then - LDFLAGS="$LDFLAGS -L$use_mbedtls/lib" - CFLAGS="$CFLAGS -I$use_mbedtls/include" - fi +AC_DEFUN([LIBSSH2_LIB_HAVE_LINKFLAGS], [ + libssh2_lib_have_linkflags_LDFLAGS="$LDFLAGS" - AC_LIB_HAVE_LINKFLAGS([mbedtls], [], [ - #include - ]) + test "${with_lib$1_prefix+set}" = set && + LDFLAGS="$LDFLAGS${LDFLAGS:+ }-L${with_lib$1_prefix}/lib" - if test "$ac_cv_libmbedtls" = "yes"; then - AC_DEFINE(LIBSSH2_MBEDTLS, 1, [Use mbedtls]) - LIBSREQUIRED= # mbedtls doesn't provide a .pc file - LIBS="$LIBS -lmbedtls -lmbedcrypto" - found_crypto=libmbedtls - support_clear_memory=yes - else - # restore - LDFLAGS=$old_LDFLAGS - CFLAGS=$old_CFLAGS + AC_LIB_HAVE_LINKFLAGS([$1], [$2], [$3]) + + LDFLAGS="$libssh2_lib_have_linkflags_LDFLAGS" + + if test "$ac_cv_lib$1" = "yes"; then : + $4 fi ]) -AC_DEFUN([LIBSSH2_CHECKFOR_GCRYPT], [ +AC_DEFUN([LIBSSH2_CHECK_CRYPTO], [ +if test "$use_crypto" = "auto" && test "$found_crypto" = "none" || test "$use_crypto" = "$1"; then +m4_case([$1], +[openssl], [ + LIBSSH2_LIB_HAVE_LINKFLAGS([ssl], [crypto], [#include ], [ + AC_DEFINE(LIBSSH2_OPENSSL, 1, [Use $1]) + LIBSREQUIRED="$LIBSREQUIRED${LIBSREQUIRED:+ }libssl libcrypto" - old_LDFLAGS=$LDFLAGS - old_CFLAGS=$CFLAGS - if test -n "$with_libgcrypt_prefix" && test "$use_libgcrypt" != "no"; then - LDFLAGS="$LDFLAGS -L$with_libgcrypt_prefix/lib" - CFLAGS="$CFLAGS -I$with_libgcrypt_prefix/include" - fi - AC_LIB_HAVE_LINKFLAGS([gcrypt], [], [ - #include - ]) + # Not all OpenSSL have AES-CTR functions. + AC_CHECK_FUNCS(EVP_aes_128_ctr) - if test "$ac_cv_libgcrypt" = "yes"; then - AC_DEFINE(LIBSSH2_LIBGCRYPT, 1, [Use libgcrypt]) - LIBSREQUIRED= # libgcrypt doesn't provide a .pc file. sad face. - LIBS="$LIBS -lgcrypt" - found_crypto=libgcrypt - else - # restore - LDFLAGS=$old_LDFLAGS - CFLAGS=$old_CFLAGS - fi -]) + found_crypto="$1" + found_crypto_str="OpenSSL (AES-CTR: ${ac_cv_func_EVP_aes_128_ctr:-N/A})" + ]) +], +[libgcrypt], [ + LIBSSH2_LIB_HAVE_LINKFLAGS([gcrypt], [], [#include ], [ + AC_DEFINE(LIBSSH2_LIBGCRYPT, 1, [Use $1]) + found_crypto="$1" + ]) +], -AC_DEFUN([LIBSSH2_CHECKFOR_WINCNG], [ +[mbedtls], [ + LIBSSH2_LIB_HAVE_LINKFLAGS([mbedtls], [], [#include ], [ + AC_DEFINE(LIBSSH2_MBEDTLS, 1, [Use $1]) + found_crypto="$1" + support_clear_memory=yes + ]) +], +[wincng], [ # Look for Windows Cryptography API: Next Generation - AC_LIB_HAVE_LINKFLAGS([bcrypt], [], [ - #include - #include - ]) - AC_LIB_HAVE_LINKFLAGS([crypt32], [], [ + AC_CHECK_HEADERS([ntdef.h ntstatus.h], [], [], [#include ]) + AC_CHECK_DECLS([SecureZeroMemory], [], [], [#include ]) + + LIBSSH2_LIB_HAVE_LINKFLAGS([crypt32], [], [ #include #include ]) - AC_CHECK_HEADERS([ntdef.h ntstatus.h], [], [], [ - #include - ]) - AC_CHECK_DECLS([SecureZeroMemory], [], [], [ + LIBSSH2_LIB_HAVE_LINKFLAGS([bcrypt], [], [ #include + #include + ], [ + AC_DEFINE(LIBSSH2_WINCNG, 1, [Use $1]) + found_crypto="$1" + found_crypto_str="Windows Cryptography API: Next Generation" + support_clear_memory="$ac_cv_have_decl_SecureZeroMemory" ]) - - if test "$ac_cv_libbcrypt" = "yes"; then - AC_DEFINE(LIBSSH2_WINCNG, 1, [Use Windows CNG]) - LIBSREQUIRED= # wincng doesn't provide a .pc file. sad face. - LIBS="$LIBS -lbcrypt" - if test "$ac_cv_libcrypt32" = "yes"; then - LIBS="$LIBS -lcrypt32" - fi - found_crypto="Windows Cryptography API: Next Generation" - if test "$ac_cv_have_decl_SecureZeroMemory" = "yes"; then - support_clear_memory=yes - fi - fi +], +) + test "$found_crypto" = "none" && + crypto_errors="${crypto_errors}No $1 crypto library found! +" +fi ]) diff --git a/configure.ac b/configure.ac index f7fe247..c6ff753 100644 --- a/configure.ac +++ b/configure.ac @@ -83,78 +83,81 @@ AC_C_BIGENDIAN dnl check for how to do large files AC_SYS_LARGEFILE -found_crypto=none - # Configure parameters -AC_ARG_WITH(openssl, - AC_HELP_STRING([--with-openssl],[Use OpenSSL for crypto]), - use_openssl=$withval,use_openssl=auto) -AC_ARG_WITH(libgcrypt, - AC_HELP_STRING([--with-libgcrypt],[Use libgcrypt for crypto]), - [ use_libgcrypt=$withval - LIBSSH2_CHECKFOR_GCRYPT - ], use_libgcrypt=auto) -AC_ARG_WITH(wincng, - AC_HELP_STRING([--with-wincng],[Use Windows CNG for crypto]), - [ use_wincng=$withval - LIBSSH2_CHECKFOR_WINCNG - ] ,use_wincng=auto) -AC_ARG_WITH([mbedtls], - AC_HELP_STRING([--with-mbedtls],[Use mbedTLS for crypto]), - [ use_mbedtls=$withval - LIBSSH2_CHECKFOR_MBEDTLS - ], use_mbedtls=auto -) -AC_ARG_WITH(libz, - AC_HELP_STRING([--with-libz],[Use zlib for compression]), - use_libz=$withval,use_libz=auto) + +# Crypto backends + +found_crypto=none +found_crypto_str="" support_clear_memory=no +crypto_errors="" + +m4_set_add([crypto_backends], [openssl]) +m4_set_add([crypto_backends], [libgcrypt]) +m4_set_add([crypto_backends], [mbedtls]) +m4_set_add([crypto_backends], [wincng]) + +AC_ARG_WITH([crypto], + AC_HELP_STRING([--with-crypto=auto|]m4_set_contents([crypto_backends], [|]), + [Select crypto backend (default: auto)]), + use_crypto=$withval, + use_crypto=auto +) -# Look for OpenSSL -if test "$found_crypto" = "none" && test "$use_openssl" != "no"; then - AC_LIB_HAVE_LINKFLAGS([ssl], [crypto], [#include ]) -fi -if test "$ac_cv_libssl" = "yes"; then - AC_DEFINE(LIBSSH2_OPENSSL, 1, [Use OpenSSL]) - LIBSREQUIRED=libssl,libcrypto +case "${use_crypto}" in + auto|m4_set_contents([crypto_backends], [|])) + m4_set_map([crypto_backends], [LIBSSH2_CHECK_CRYPTO]) + ;; + yes|"") + crypto_errors="No crypto backend specified!" + ;; + *) + crypto_errors="Unknown crypto backend '${use_crypto}' specified!" + ;; +esac - # Not all OpenSSL have AES-CTR functions. - save_LIBS="$LIBS" - LIBS="$LIBS $LIBSSL" - AC_CHECK_FUNCS(EVP_aes_128_ctr) - LIBS="$save_LIBS" +if test "$found_crypto" = "none"; then + crypto_errors="${crypto_errors} +Specify --with-crypto=\$backend and/or the neccessary library search prefix. - found_crypto="OpenSSL (AES-CTR: ${ac_cv_func_EVP_aes_128_ctr:-N/A})" +Known crypto backends: auto, m4_set_contents([crypto_backends], [, ])" + AS_MESSAGE([ERROR: ${crypto_errors}]) +else + test "$found_crypto_str" = "" && found_crypto_str="$found_crypto" fi -AM_CONDITIONAL(OPENSSL, test "$ac_cv_libssl" = "yes") -AM_CONDITIONAL(WINCNG, test "$ac_cv_libbcrypt" = "yes") -AM_CONDITIONAL(LIBGCRYPT, test "$ac_cv_libgcrypt" = "yes") -AM_CONDITIONAL(MBEDTLS, test "$ac_cv_libmbedtls" = "yes") +m4_set_foreach([crypto_backends], [backend], + [AM_CONDITIONAL(m4_toupper(backend), test "$found_crypto" = "backend")] +) +m4_undefine([backend]) -# Check if crypto library was found -if test "$found_crypto" = "none"; then - AC_MSG_ERROR([No crypto library found! -Try --with-libssl-prefix=PATH - or --with-libgcrypt-prefix=PATH - or --with-libmbedtls-prefix=PATH - or --with-wincng on Windows\ -]) -fi -# Look for Libz -if test "$use_libz" != "no"; then +# libz + +AC_ARG_WITH([libz], + AC_HELP_STRING([--with-libz],[Use libz for compression]), + use_libz=$withval, + use_libz=auto) + +found_libz=no +libz_errors="" + +if test "$use_libz" != no; then AC_LIB_HAVE_LINKFLAGS([z], [], [#include ]) if test "$ac_cv_libz" != yes; then - AC_MSG_NOTICE([Cannot find zlib, disabling compression]) - AC_MSG_NOTICE([Try --with-libz-prefix=PATH if you know you have it]) + if test "$use_libz" = auto; then + AC_MSG_NOTICE([Cannot find libz, disabling compression]) + found_libz="disabled; no libz found" + else + libz_errors="No libz found! +Try --with-libz-prefix=PATH if you know that you have it." + AS_MESSAGE([ERROR: $libz_errors]) + fi else AC_DEFINE(LIBSSH2_HAVE_ZLIB, 1, [Compile in zlib support]) - if test "${LIBSREQUIRED}" != ""; then - LIBSREQUIRED="${LIBSREQUIRED}," - fi - LIBSREQUIRED="${LIBSREQUIRED}zlib" + LIBSREQUIRED="$LIBSREQUIRED${LIBSREQUIRED:+ }zlib" + found_libz="yes" fi fi @@ -351,6 +354,22 @@ AC_C_INLINE CURL_CHECK_NONBLOCKING_SOCKET +missing_required_deps=0 + +if test "${libz_errors}" != ""; then + AS_MESSAGE([ERROR: ${libz_errors}]) + missing_required_deps=1 +fi + +if test "$found_crypto" = "none"; then + AS_MESSAGE([ERROR: ${crypto_errors}]) + missing_required_deps=1 +fi + +if test $missing_required_deps = 1; then + AC_MSG_ERROR([Required dependencies are missing!]) +fi + AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile @@ -367,10 +386,10 @@ AC_MSG_NOTICE([summary of build options: Compiler: ${CC} Compiler flags: ${CFLAGS} Library types: Shared=${enable_shared}, Static=${enable_static} - Crypto library: ${found_crypto} + Crypto library: ${found_crypto_str} Clear memory: $enable_clear_memory Debug build: $enable_debug Build examples: $build_examples Path to sshd: $ac_cv_path_SSHD (only for self-tests) - zlib compression: $ac_cv_libz + zlib compression: ${found_libz} ]) diff --git a/docs/HACKING.CRYPTO b/docs/HACKING.CRYPTO index 6fdcf71..21c99c3 100644 --- a/docs/HACKING.CRYPTO +++ b/docs/HACKING.CRYPTO @@ -13,6 +13,33 @@ Procedures listed as "void" may indeed have a result type: the void indication indicates the libssh2 core modules never use the function result. +0) Build system. + +Add a new crypto backend to the autotools build system (./configure) as such: + +* Add one new line to configure.ac: + +m4_set_add([crypto_backends], [newname]) + +This automatically creates a new --with-crypto=newname option which users can +specify when invoking configure at compile-time to select the new backend. + +* Add a new m4_case stanza to acinclude.m4 within LIBSSH2_CRYPTO_CHECK, + with checks for library availability. A successful check should set + library linking variables. The LIBSSH2_LIB_HAVE_LINKFLAGS macro creates + such a variable automatically if the checked library can be found. + +* Add a Makefile.newname.inc in the top-level directory which sets + CRYPTO_CSOURCES and CRYPTO_HHEADERS to the new backend source files, + and CRYPTO_LTLIBS to the libtool linking parameters for the library, set + e.g. by a LIBSSH2_LIB_HAVE_LINKFLAGS call in LIBSSH2_CRYPTO_CHECK. + +* Add a new block to src/Makefile.am: + if NEWNAME + include ../Makefile.newname.inc + endif + + 1) Crypto library initialization/termination. void libssh2_crypto_init(void); diff --git a/src/Makefile.am b/src/Makefile.am index 1fa0751..31d58ed 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,7 @@ # $Id: Makefile.am,v 1.21 2009/05/07 17:21:56 bagder Exp $ AUTOMAKE_OPTIONS = foreign nostdinc -# Get the CRYPTO_CSOURCES and CRYPTO_HHEADERS defines +# Get the CRYPTO_CSOURCES, CRYPTO_HHEADERS and CRYPTO_LTLIBS defines if OPENSSL include ../Makefile.OpenSSL.inc endif @@ -62,4 +62,4 @@ VERSION=-version-info 1:1:0 libssh2_la_LDFLAGS = $(VERSION) -no-undefined \ -export-symbols-regex '^libssh2_.*' \ - $(LTLIBGCRYPT) $(LTLIBSSL) $(LTLIBZ) + $(CRYPTO_LTLIBS) $(LTLIBZ) -- _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Tue Nov 8 12:45:00 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA8BiX1d026091; Tue, 8 Nov 2016 12:44:56 +0100 Received: from mail-wm0-x236.google.com (mail-wm0-x236.google.com [IPv6:2a00:1450:400c:c09:0:0:0:236]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA8BiVGO026057 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 8 Nov 2016 12:44:32 +0100 Received: by mail-wm0-x236.google.com with SMTP id f82so175241237wmf.1 for ; Tue, 08 Nov 2016 03:44:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=RkbneF7uOmS5YgUZ+QLLS6CHS/xixv0291G8lM8Pfa4=; b=p9CUcZb8m/W1gT+vtqP2uQos/eFm0+dTuFXtfXS2dHMZiBJ57Z0vmk0RZk1hDMfO3f yUCpXBw3cTt6gyHaOU9qeViK9BahvOBQhD59S2hqP4iZHeXcI3QgqYtG5GpmLROXoTNT kcgLhPr/ZK0BWpj1t/xrCn0+bH5j5C+jBuXGsicAJ/txTaInm+VmQonZRl2brH/0bIAf kjFku1I0/cqp5m46CiPkSxvDXCEmgIVdBLWPanATqLMxH1JbwR77YXdQBHuwr/emVrcw wElVUZiVptI8DM56xxkgCKVKzfvNc1pL6V5FXWu8QBAqhAPg0t2+Gq2ERzjQnqNmh2Ei uWkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=RkbneF7uOmS5YgUZ+QLLS6CHS/xixv0291G8lM8Pfa4=; b=OlHQ0FabdxQR0UyNA4EnLxJae2KJl+JVSIjpkOVyb+awhMUtMU5wperVNaNLUG4YPC /66MuK0cWBbugsFlf34A2BPorjaM1HjyOjnXJZx8SR0GUoYDzS977tgsfIpfyS5WMD8J kJP8EfAFux5Ub2/iOgx2NEUMgUV7YqKUcWkCVDaJp9U1puW7B3If25fWZaAPNN4X+Y8F 22JXJ3dV0Y/W1M99bpOhe3jlwMoy0aVjzLfv0XA0VRRxun+4jL9EH2wuT7nriJOJgsuj QZHQJBFVZv+LXEGVyEwq8XhWCamYZQOORDXu+QfsBfn8qnRaREjQOg4M0Kw9pKJ/cXNw o51Q== X-Gm-Message-State: ABUngvfXp4Jv1zs8HQ0AxRn+HQuyGZv9VedB9gFccHVCnV/b/DxS9OWNAxTpODj6hodfXpxClhYv65t1XMZZVw== X-Received: by 10.195.12.42 with SMTP id en10mr9556542wjd.126.1478605467524; Tue, 08 Nov 2016 03:44:27 -0800 (PST) MIME-Version: 1.0 Received: by 10.194.134.129 with HTTP; Tue, 8 Nov 2016 03:43:57 -0800 (PST) In-Reply-To: References: From: Jeroen Wiert Pluimers Date: Tue, 8 Nov 2016 12:43:57 +0100 X-Google-Sender-Auth: ViGoAXvx280detYhVLmuI08wP0U Message-ID: Subject: Re: Want to build monolithic libssh2.dll on Windows (preferably Win32 and Win64) but no real success so far To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============0478547460==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============0478547460== Content-Type: multipart/alternative; boundary=047d7bfd017ca7c39d0540c8a9f2 --047d7bfd017ca7c39d0540c8a9f2 Content-Type: text/plain; charset=UTF-8 On Sun, Nov 6, 2016 at 12:05 AM, Alexander Lamaison wrote: > On 3 November 2016 at 23:36, Jeroen Wiert Pluimers > wrote: > > Now what _is_ interesting from the lines above is that you are getting > static libraries for debug builds but dynamic libraries for release > builds! I don't know what could cause that. Though I've just spotted > a change in CMake 3.6 that might cause it [1]. Could you try with > CMake 3.5.2 or older? > I will do somewhere after https://entwickler-konferenz.de/sessions-en/ is over. You might have guessed from my messages that I'm very new on CMAKE, C/C++ efforts have been a long time ago but I'm willing to learn. If that doesn't work, did you perhaps configure it before in this > directory some time previously? I suggest starting with a completely > clean build directory. > I run this script from a fresh directory under %TEMP% where it starts with a `git clone`. I hope that's clean enough (: [1]: https://gitlab.kitware.com/cmake/cmake/commit/ > b148440381df0143a665b7ceebe8606a052e2cdf For my own reference: https://www.libssh2.org/mail/libssh2-devel-archive-2016-11/0009.shtml --jeroen --047d7bfd017ca7c39d0540c8a9f2 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Sun, Nov 6, 2016 at 12:05 AM, Alexander Lamaison &= lt;swish@lammy.co.uk= > wrote:
On 3 November 2016 at 23:36, Jeroen Wiert Pluimers
<jeroen.pluimers.com+libssh2.org@gmail.com> wrote:
=C2=A0
= Now what _is_ interesting from the lines above is that you are getting
static libraries for debug builds but dynamic libraries for release
builds!=C2=A0 I don't know what could cause that.=C2=A0 Though I've= just spotted
a change in CMake 3.6 that might cause it [1].=C2=A0 Could you try with
CMake 3.5.2 or older?

I will do somewhe= re after https://e= ntwickler-konferenz.de/sessions-en/ is over.=C2=A0

=
You might have guessed from my messages that I'm very new on CMAKE= , C/C++ efforts have been a long time ago but I'm willing to learn.

If that doesn't work, did you perhaps configure it before in this
directory some time previously?=C2=A0 I suggest starting with a completely<= br> clean build directory.

I run this scrip= t from a fresh directory under %TEMP% where it starts with a `git clone`. I= hope that's clean enough (:

[1]: https://g= itlab.kitware.com/cmake/cmake/commit/b148440381df0143a665b7ceebe8= 606a052e2cdf


--jeroen
--047d7bfd017ca7c39d0540c8a9f2-- --===============0478547460== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============0478547460==-- From libssh2-devel-bounces@cool.haxx.se Tue Nov 8 13:01:07 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA8C0wlX004613; Tue, 8 Nov 2016 13:01:05 +0100 Received: from mail-wm0-x235.google.com (mail-wm0-x235.google.com [IPv6:2a00:1450:400c:c09:0:0:0:235]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA8C0vKU004583 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 8 Nov 2016 13:00:57 +0100 Received: by mail-wm0-x235.google.com with SMTP id a197so240697343wmd.0 for ; Tue, 08 Nov 2016 04:00:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=g4GoPLSaVeSCDGufzZjIg4hUvr3mPlkgWLHne6eYutw=; b=am4M8Tov02cudG/bh7qLyuDM1iUWFZQIeqzqcxjiIVGfWKqllazUSNfm5i/Zas+DVf 5TpjkVOZA/4LBVXvRcpaRTrhKgCm66RJiEWqEXITXTeRIv8+1ZSFqsH0cSN9TJInvTkg SLrkydbr1ZjtiIkigH1FgNTF+eoBNvLZB55i4ya7AmsrYQZkGtiT1N0X1kkoNSsx8ekl CRHoDMluEZMmSgW5JPuzajmLhUKu8KtsYFagCSxwUTXfII9EMUQJtYP5kyGS0m3AZnO4 3UjLF6KIaBCyjA11tdEStLYKjVimxUYpIcFIu8jBuoUfNdSjThKiP+C7IG1Os3OXmWLQ Sa5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=g4GoPLSaVeSCDGufzZjIg4hUvr3mPlkgWLHne6eYutw=; b=Q5OnoKesML9tWmnCEP0q8RBIrdw4R/OBF1Fana6deOfNwXHayVu7m0cfX8reNyDJ76 +4cIMosYR+yqIUyRtFFfiv9McCa8zb2w5XKdARSZg/3An6ACeE+nZsIrHg2QfdHMKKEw NtLxqQ5tXPs9qplt7rJBRG2OPj/dir4uSGsTEDP+YprMVJicPmIKmtzeG24MCtH6VeX+ 3ksYNite7F7i0HvxL1IFjGc1iwarCy3x0UWql681go7907Xuo3RDStkL9Wv3P7JTrff4 Ld7ACdMPbn/X1ThcDvoKyemg0gM4rivTAp3/2y4wteXtL6P68dJPha4f+BNvvGA1x0x/ j+Vg== X-Gm-Message-State: ABUngvei1qfY4EAFAKw9SnA7HZmXLM7B3MWOEnolnb4GiVA7qkdd7lRp4soTbQrgw6WjT/gomXDay64ICeGvYw== X-Received: by 10.194.88.131 with SMTP id bg3mr12572174wjb.32.1478606453060; Tue, 08 Nov 2016 04:00:53 -0800 (PST) MIME-Version: 1.0 Received: by 10.194.134.129 with HTTP; Tue, 8 Nov 2016 04:00:22 -0800 (PST) In-Reply-To: References: From: Jeroen Wiert Pluimers Date: Tue, 8 Nov 2016 13:00:22 +0100 X-Google-Sender-Auth: NyVCEZ-SMho61Sr4yimESww7Hqw Message-ID: Subject: Re: energy boost? To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============0548736137==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============0548736137== Content-Type: multipart/alternative; boundary=089e010d849e65bb5a0540c8e475 --089e010d849e65bb5a0540c8e475 Content-Type: text/plain; charset=UTF-8 Thanks Daniel for all your efforts so far. I understand your position and know how tough contributing over a long time can be. For the foreseeable time I need to limit my open source contribution efforts to a combination that satisfies: - occasional sprees of effort - areas that I'm either already comfortable with or are in close-term need (note: I'm willing to learn new things outside my comfort zone, but doing that well takes time which I need to fit in) - aim for the Windows side of things focussed on Visual Studio and/or Delphi tool-chains - fit in my day-to-day life involving more and more family care - don't interfere with the preparations for the 4-yearly World Music Contest mid next year (my marching band has been in the world top-10 for like 3 decades which each time is a sort of Herculean effort but worth it as counter-weight to my computing efforts) I've sort of promised to help Bert with efforts in the direction of https://blogs.msdn.microsoft.com/vcblog/2016/09/19/vcpkg-a-tool-to-acquire-and-build-c-open-source-libraries-on-windows/ My short to medium term aim is to get libssh2 to build as a monolithic Windows DLL (x86 needed, x64 nice to have) with as much ciphers as possible as it's on https://bitbucket.org/ZeljkoMarjanovic/libssh2-delphi/src/tip/bin/libssh2.dll without any build instructions. Almost everything I do that's sort of publicly usable eventually appears on the existing open source repository my https://wiert.me, blog, https://bitbucket.org/jeroenp/ or https://github.com/jpluimers I try to push things as much upstream as I can since forks are the achilles heel of Open Source (though I get the emotional side of many forks, I learned that those take away too much energy so I try to get over them/ignore/whatever as much as possible. Sorry if/when people find that an offence). Recent contributions have been incidental but broad and include: - https://github.com/deadlockempire/deadlockempire.github.io - https://github.com/certbot/certbot - https://github.com/jpluimers/mikrotik-routeros - https://github.com/VSoftTechnologies/DUnitX - https://github.com/Hexxeh/rpi-update - https://github.com/drwetter/testssl.sh - https://github.com/jrsoftware/issrc - https://bitbucket.org/jeroenp/libssh2-delphi It shows the dilemma I'm in, hence the occasional sprees. Regards, On Sat, Nov 5, 2016 at 11:38 AM, Daniel Stenberg wrote: > Hi friends, > > We've been stalling in this project lately[1]. We get pull requests and > issues filed, but they mostly just accumulate without being dealt with. I > am of course personally guilty of this neglect but I'm not alone. > > I'm interested in hearing what you all think we can do to up our game. > > I've spent almost exactly ten years in this project and I've done 769 > source code commits to date, but these days libssh2 is not a priority in my > life anymore. I don't plan to run away or hide, but I am interested in > seeing others step up their game to help driving the project forward so > that I can remain in a backseat position without having the project suffer. > > [1] = https://www.openhub.net/p/libssh2/contributors/summary > > -- > > / daniel.haxx.se > _______________________________________________ > libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel > --089e010d849e65bb5a0540c8e475 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Thanks Daniel for all your efforts so far.

<= div>I understand your position and know how tough contributing over a long = time can be.

For the foreseeable time I need to limit my= open source contribution efforts to a combination that satisfies:

- occasional sprees of effort
- areas that I'= ;m either already comfortable with or are in close-term need (note: I'm= willing to learn new things outside my comfort zone, but doing that well t= akes time which I need to fit in)
- aim for the Windows side of t= hings focussed on Visual Studio and/or Delphi tool-chains
- fit i= n my day-to-day life involving more and more family care
- don= 9;t interfere with the preparations for the 4-yearly World Music Contest mi= d next year (my marching band has been in the world top-10 for like 3 decad= es which each time is a sort of Herculean effort but worth it as counter-we= ight to my computing efforts)


My short to medium term aim i= s to get libssh2 to build as a monolithic Windows DLL (x86 needed, x64 nice= to have) with as much ciphers as possible as it's on=C2=A0https://bitbucket.org/ZeljkoMarjanovic/libssh2-delphi/src/tip/bin/libssh= 2.dll without any build instructions.

Almost e= verything I do that's sort of publicly usable eventually appears on the= existing open source repository my https://wi= ert.me, blog, https://bitbuc= ket.org/jeroenp/ or https://gi= thub.com/jpluimers

I try to push things as muc= h upstream as I can since forks are the achilles heel of Open Source (thoug= h I get the emotional side of many forks, I learned that those take away to= o much energy so I try to get over them/ignore/whatever as much as possible= . Sorry if/when people find that an offence).=C2=A0

Recent contributions have been incidental but broad and include:


It shows the dilemma I'm in, hence the occasional sprees.
<= div>
Regards,

=C2=A0=C2=A0

On Sat, N= ov 5, 2016 at 11:38 AM, Daniel Stenberg <daniel@haxx.se> wrote:=
Hi friends,

We've been stalling in this project lately[1]. We get pull requests and= issues filed, but they mostly just accumulate without being dealt with. I = am of course personally guilty of this neglect but I'm not alone.

I'm interested in hearing what you all think we can do to up our game.<= br>
I've spent almost exactly ten years in this project and I've done 7= 69 source code commits to date, but these days libssh2 is not a priority in= my life anymore. I don't plan to run away or hide, but I am interested= in seeing others step up their game to help driving the project forward so= that I can remain in a backseat position without having the project suffer= .

[1] =3D https://www.openhub.net/p/libssh2= /contributors/summary
--

=C2=A0/ daniel.haxx.se
_______________________________________________
libssh2-devel https://cool.haxx.se/cgi-bi= n/mailman/listinfo/libssh2-devel

--089e010d849e65bb5a0540c8e475-- --===============0548736137== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============0548736137==-- From libssh2-devel-bounces@cool.haxx.se Tue Nov 8 17:32:11 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA8GVh7K021990; Tue, 8 Nov 2016 17:32:05 +0100 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA8GVdLx021933 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 8 Nov 2016 17:31:40 +0100 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 92ED119C31A; Tue, 8 Nov 2016 16:31:34 +0000 (UTC) Received: from kdudka-nb.localnet (unused-4-122.brq.redhat.com [10.34.4.122]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id uA8GVWgk019818 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 8 Nov 2016 11:31:34 -0500 From: Kamil Dudka To: Peter Stuge Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend Date: Tue, 08 Nov 2016 17:31:36 +0100 Message-ID: <36069894.ay4bUJqtHz@kdudka-nb> User-Agent: KMail/4.14.10 (Linux/4.7.10-gentoo; KDE/4.14.24; x86_64; ; ) In-Reply-To: <1478486067-29645-1-git-send-email-peter@stuge.se> References: <20161107031131.GG31660@foo.stuge.se> <1478486067-29645-1-git-send-email-peter@stuge.se> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Tue, 08 Nov 2016 16:31:34 +0000 (UTC) X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: cynede@gentoo.org, siarheit@google.com, libssh2-devel@cool.haxx.se Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uA8GVh7K021990 On Monday, November 07, 2016 03:34:27 Peter Stuge wrote: > The new --with-crypto option replaces the previous backend-specific > --with-{openssl,libgcrypt,mbedtls,wincng} options and fixes some issues. > > * libgcrypt or mbedtls would previously be used whenever found, even > if configure was passed --without-libgcrypt or --without-mbedtls. > > * If --with-$backend was specified then configure would not fail even > if that library could not be found, and would instead use whichever > crypto library was found first. > > The new option defaults to `auto`, which makes configure check for all > supported crypto libraries in turn, choosing the first one found, or > exiting with an error if none can be found. This patch seems to break detection of EVP_aes_128_ctr() while building against OpenSSL. This is the corresponding part of config.log with the current master branch: configure:16982: checking for EVP_aes_128_ctr configure:16982: gcc -o conftest -g -O2 conftest.c -lssl -lcrypto >&5 configure:16982: $? = 0 configure:16982: result: yes But with this patch applied, it looks like this: configure:14772: checking for EVP_aes_128_ctr configure:14772: gcc -o conftest -g -O2 conftest.c >&5 /tmp/ccARmUY4.o: In function `main': conftest.c:60: undefined reference to `EVP_aes_128_ctr' collect2: error: ld returned 1 exit status configure:14772: $? = 1 Kamil _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 9 20:11:17 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA9JAhpG030679; Wed, 9 Nov 2016 20:11:09 +0100 Received: from COL004-OMC3S11.hotmail.com (col004-omc3s11.hotmail.com [65.55.34.149]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA9JAeUQ030647 for ; Wed, 9 Nov 2016 20:10:41 +0100 Received: from NAM04-BN3-obe.outbound.protection.outlook.com ([65.55.34.136]) by COL004-OMC3S11.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008); Wed, 9 Nov 2016 11:10:30 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=msn.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=kPHUrCCh9g997Lgcqf63FYVhYJQIiPnwYQ98hKwINuw=; b=gPtnooh1jZ26dHJ2IQFXply6rDBsR1QShUY6mbPa6hpev8bfeMEHpdr5EXAJTAphnay94jZTxk317/nD1S78BgHpl9mlu/lxF4lWFvw1HszePFADJf/a4uBRwI8qnSUhMKPa3eK4LmHShq1ccWvw8f43zuTnlUK9wQIpe+NrKry0w7dJwN0wrV9e57Le2ylhrE4HAtfv2ZtnimdzozLaeRY/YjApW4pK9JztQRJVxv1jOmocopyHrhQuBiYoumzGzaoF/9B7w/8hvl+QfiJHT6Wh1kl+gGGcn42wQVXtYnJD927iZJIonnBqCz6OiITNAr6SXU6HytSUMDTdBZDapA== Received: from BN3NAM04FT039.eop-NAM04.prod.protection.outlook.com (10.152.92.51) by BN3NAM04HT223.eop-NAM04.prod.protection.outlook.com (10.152.93.168) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.707.3; Wed, 9 Nov 2016 19:10:28 +0000 Received: from BY1PR11MB0295.namprd11.prod.outlook.com (10.152.92.59) by BN3NAM04FT039.mail.protection.outlook.com (10.152.93.3) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.707.3 via Frontend Transport; Wed, 9 Nov 2016 19:10:27 +0000 Received: from BY1PR11MB0295.namprd11.prod.outlook.com ([10.160.206.145]) by BY1PR11MB0295.namprd11.prod.outlook.com ([10.160.206.145]) with mapi id 15.01.0707.013; Wed, 9 Nov 2016 19:10:28 +0000 From: Dave Taflin To: "libssh2-devel@cool.haxx.se" Subject: All tests failing Thread-Topic: All tests failing Thread-Index: AQHSOrvY4evydgCJwk6ZqMXoRXzleQ== Date: Wed, 9 Nov 2016 19:10:27 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: cool.haxx.se; dkim=none (message not signed) header.d=none;cool.haxx.se; dmarc=none action=none header.from=msn.com; x-incomingtopheadermarker: OriginalChecksum:; UpperCasedChecksum:; SizeAsReceived:2249; Count:36 x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [/31VL0r0bFuYvvhRCWs9vVL6FiuGJPYe] x-incomingheadercount: 36 x-eopattributedmessage: 0 x-microsoft-exchange-diagnostics: 1; BN3NAM04HT223; 7:qREcSIQd6ynpTX7wLvQM5rxHs3/xQGMIdkaiNmsJBaHbC5+YmZ80itfKUdvNJ+vP3cUfYxb6vd/yxsFrYMHbb9NsYSdplivX8SzPxrk4fHq/n+TPA/OxwA4iuz19Buw0Pu7u1UrNLLaaf7H1N02uAZGxtJwJV8t6Jz4MbyDE2x+qAHNv8QDGfUOtI94ZoMgboSqCySCny5C9pmqh/pZNAB+TSN7vIN9zktzDOTT1ZN9NKyiHG+jpwF+d7MY3W4dYfCvpLUwTdB+dTtciVroKt24FIo55L7Zekt9VSA6Tv73Ystqdzx6VKhddQi6Ppft5b5me8ezDmkGd5i/ti2BFhH3Ohfm6iwO6A9PMjlp5CvE= x-forefront-antispam-report: EFV:NLI; SFV:NSPM; SFS:(10019020)(98900003); DIR:OUT; SFP:1102; SCL:1; SRVR:BN3NAM04HT223; H:BY1PR11MB0295.namprd11.prod.outlook.com; FPR:; SPF:None; LANG:en; x-ms-office365-filtering-correlation-id: e0ecf811-c0e4-40f2-9d89-08d408d4113c x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BN3NAM04HT223; x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(432015012)(82015046); SRVR:BN3NAM04HT223; BCL:0; PCL:0; RULEID:; SRVR:BN3NAM04HT223; x-forefront-prvs: 0121F24F22 spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Nov 2016 19:10:27.8914 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3NAM04HT223 X-OriginalArrivalTime: 09 Nov 2016 19:10:30.0503 (UTC) FILETIME=[F02ED770:01D23ABC] X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============2026193246==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============2026193246== Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_BY1PR11MB02950721FEFB0891BBDC25A6B9B90BY1PR11MB0295namp_" --_000_BY1PR11MB02950721FEFB0891BBDC25A6B9B90BY1PR11MB0295namp_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I'm considering using libssh2 in software I'm developing. I've configured w= ith CMake and built on Windows Vista with Visual Studio 2013. The build wen= t fine, but all the tests (building the RUN_TESTS target) failed. Running t= hem verbosely in a command shell, I observed that they require Docker--all = the test commands are something like: docker build -t libssh2/openssh_server openssh_server So I installed Docker (that took awhile!) and ran the tests in the Docker Q= uickstart Terminal. They all fail with the following message: libssh2_session_handshake failed (-5): Unable to exchange encryption keys So, a question and a suggestion... Question: Should I be concerned about the failed tests? Suggestion: Document the requirement for Docker to run the tests, and/or ma= ke the CMake BUILD_TESTING flag default to off so developers don't see the = tests and expect them to work like I did. Thanks, Dave --_000_BY1PR11MB02950721FEFB0891BBDC25A6B9B90BY1PR11MB0295namp_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable

I'm considering using libssh2 in software I'm developing. I've configure= d with CMake and built on Windows Vista with Visual Studio 2013. The build = went fine, but all the tests (building the RUN_TESTS target) failed. Runnin= g them verbosely in a command shell, I observed that they require Docker--all the test commands are someth= ing like:


docker build -t libssh2/openssh_server openssh_server


So I installed Docker (that took awhile!) and ran the tests in the Docke= r Quickstart Terminal. They all fail with the following message:


libssh2_session_handshake failed (-5): Unable to exchange encryption key= s


So, a question and a suggestion...


Question: Should I be concerned about the failed tests?


Suggestion: Document the requirement for Docker to run the tests, and/or= make the CMake BUILD_TESTING flag default to off so developers don't see t= he tests and expect them to work like I did.


Thanks,


Dave

--_000_BY1PR11MB02950721FEFB0891BBDC25A6B9B90BY1PR11MB0295namp_-- --===============2026193246== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============2026193246==-- From libssh2-devel-bounces@cool.haxx.se Wed Nov 9 21:51:27 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uA9KpALi024579; Wed, 9 Nov 2016 21:51:23 +0100 Received: from mail-lf0-f46.google.com (mail-lf0-f46.google.com [209.85.215.46]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uA9Kp9uH024499 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Wed, 9 Nov 2016 21:51:09 +0100 Received: by mail-lf0-f46.google.com with SMTP id t196so174490016lff.3 for ; Wed, 09 Nov 2016 12:51:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=uuNqvcrSNtKUYqhsT9ZHpFU6InhO0AA5Q+NODHq05iw=; b=anX/C0Kv+VBtwCf8zyNxF0hnaMAXOP8q4MCTzSNnt+K5eyJfAXS636t2qKN5MrdX6L EUUxc/Kpuqa6JbVPLZNBljv/F5zP2MLqAzy0/k+fU+zF1HGu7oyeakrf/wWD3cN+27Y5 7NikrXQ8pB5iDFDdgDI7ns7TDk6ZLeLfciglcEG8U/8qxA7nVFnoUrAp1sJgMFCN8eTm VA/wjk/1m+BugQzh8e53unIZcMwoLmIpYIHgQPgSDIe592Tsiw2epYetg3wDWkDCvHv7 HU5GfwlQVKUqMUAgNr6+TmigGhAqH+ajSUTZMkWkAHJ8TFKBqC9IkEpyVWdA3TmTz9l2 O2yQ== X-Gm-Message-State: ABUngveDkrPG6paUO1OHrBqFPKQt48zxxH+DfzbSD2fCTWZLtJ+b3pbPZV2+Ise54MOK1Ywt4pYtsIJOzo53lw== X-Received: by 10.25.206.2 with SMTP id e2mr694782lfg.64.1478724665061; Wed, 09 Nov 2016 12:51:05 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Alexander Lamaison Date: Wed, 09 Nov 2016 20:50:54 +0000 Message-ID: Subject: Re: All tests failing To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: multipart/mixed; boundary="===============0410710575==" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --===============0410710575== Content-Type: multipart/alternative; boundary=001a114212f661b8210540e46a3c --001a114212f661b8210540e46a3c Content-Type: text/plain; charset=UTF-8 On Wed, 9 Nov 2016, 19:11 Dave Taflin, wrote: > I'm considering using libssh2 in software I'm developing. I've configured > with CMake and built on Windows Vista with Visual Studio 2013. The build > went fine, but all the tests (building the RUN_TESTS target) failed. > Running them verbosely in a command shell, I observed that they require > Docker--all the test commands are something like: > > > docker build -t libssh2/openssh_server openssh_server > > > So I installed Docker (that took awhile!) and ran the tests in the Docker > Quickstart Terminal. They all fail with the following message: > > > libssh2_session_handshake failed (-5): Unable to exchange encryption keys > At a guess, you compiled libssh2 without OpenSSL, so it uses the WinCNG crypto backend. That backend doesn't support any of the ciphers required by the recent version of OpenSSL that's in the docker container. The tests that build and run in appveyor on every commit are built using OpenSSL and work fine. > So, a question and a suggestion... > > > Question: Should I be concerned about the failed tests? > Only if you compiled using OpenSSL and they still don't pass. > Suggestion: Document the requirement for Docker to run the tests, and/or > make the CMake BUILD_TESTING flag default to off so developers don't see > the tests and expect them to work like I did. > That seems sensible, though the flag should only be disabled by default if using the WinCNG backend. Patches welcome. Alex --001a114212f661b8210540e46a3c Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On Wed, 9 Nov 2016, 19:= 11 Dave Taflin, <dtaflin@msn.com&= gt; wrote:

I'm considering using libssh2 in software I'= m developing. I've configured with CMake and built on Windows Vista wit= h Visual Studio 2013. The build went fine, but all the tests (building the = RUN_TESTS target) failed. Running them verbosely in a command shell, I observed that they=C2=A0require Docker--all the test commands are someth= ing like:


docker build -t libssh2/op= enssh_server openssh_server


So I installed Docker (that took awhile!) and ran th= e tests in the Docker Quickstart Terminal. They all fail with the following= message:


libssh2_session_handshake failed (-5): Unable to exc= hange encryption keys


At a guess, you compiled libssh2 without OpenSSL, so it uses the WinCNG cr= ypto backend. That backend doesn't support any of the ciphers required = by the recent version of OpenSSL that's in the docker container. The te= sts that build and run in appveyor on every commit are built using OpenSSL = and work fine.

So, a question and a suggestion...


Question: Should I be concerned about the failed tes= ts?

Only if you compiled using OpenS= SL and they still don't pass.

Suggestion: Document the requirement for Docker to r= un the tests, and/or make the CMake BUILD_TESTING flag default to off so de= velopers don't see the tests and expect them to work like I did.


That seems sensible, though= the flag should only be disabled by default if using the WinCNG backend. P= atches welcome.=C2=A0

Alex
--001a114212f661b8210540e46a3c-- --===============0410710575== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --===============0410710575==-- From libssh2-devel-bounces@cool.haxx.se Fri Nov 11 00:46:32 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAANciYU024189; Fri, 11 Nov 2016 00:39:12 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAANcg8G024172 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 11 Nov 2016 00:38:42 +0100 Received: (qmail 25311 invoked by uid 1000); 11 Nov 2016 00:23:58 -0000 Date: Fri, 11 Nov 2016 00:23:58 +0000 From: Peter Stuge To: libssh2 development Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend Message-ID: <20161111002358.GS31660@foo.stuge.se> References: <20161107031131.GG31660@foo.stuge.se> <1478486067-29645-1-git-send-email-peter@stuge.se> <36069894.ay4bUJqtHz@kdudka-nb> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="hABqaeELJqnDDeDE" Content-Disposition: inline In-Reply-To: <36069894.ay4bUJqtHz@kdudka-nb> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: cynede@gentoo.org, siarheit@google.com Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" --hABqaeELJqnDDeDE Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Hi Kamil, Kamil Dudka wrote: > This patch seems to break detection of EVP_aes_128_ctr() while building > against OpenSSL. Thank you very much for testing, it is much appreciated! I cleaned up the detection code a bit too much. The attached fixup patch applies on top of the previous withcrypto commit and fixes detection for me. I've also pushed the fixup to my withcrypto branch. I'm feeling comfortable about --with-crypto now, but it would of course be great to get even more testing by as many as possible. If nothing new pops up I'll prepare a single patch for master. //Peter --hABqaeELJqnDDeDE Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename="0001-acinclude.m4-Fixup-OpenSSL-EVP_aes_128_ctr-detection.patch" Content-Transfer-Encoding: quoted-printable =46rom 63bd0c7c12e522a8abc56f940153c5392ca9f739 Mon Sep 17 00:00:00 2001 =46rom: Peter Stuge Date: Fri, 11 Nov 2016 00:15:46 +0100 Subject: [PATCH] acinclude.m4: Fixup OpenSSL EVP_aes_128_ctr() detection --- acinclude.m4 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/acinclude.m4 b/acinclude.m4 index e0bef46..b6eb7eb 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -416,7 +416,10 @@ m4_case([$1], LIBSREQUIRED=3D"$LIBSREQUIRED${LIBSREQUIRED:+ }libssl libcrypto" =20 # Not all OpenSSL have AES-CTR functions. + save_LIBS=3D"${LIBS}" + LIBS=3D"$LIBS $LIBSSL" AC_CHECK_FUNCS(EVP_aes_128_ctr) + LIBS=3D"${save_LIBS}" =20 found_crypto=3D"$1" found_crypto_str=3D"OpenSSL (AES-CTR: ${ac_cv_func_EVP_aes_128_ctr:-N/= A})" --=20 --hABqaeELJqnDDeDE Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KbGlic3NoMi1k ZXZlbCBodHRwczovL2Nvb2wuaGF4eC5zZS9jZ2ktYmluL21haWxtYW4vbGlzdGluZm8vbGlic3No Mi1kZXZlbAo= --hABqaeELJqnDDeDE-- From libssh2-devel-bounces@cool.haxx.se Fri Nov 11 15:33:47 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uABEXJM7012865; Fri, 11 Nov 2016 15:33:41 +0100 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uABEXFcC012757 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 11 Nov 2016 15:33:16 +0100 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D19BE63172; Fri, 11 Nov 2016 14:33:10 +0000 (UTC) Received: from kdudka-nb.localnet (unused-4-224.brq.redhat.com [10.34.4.224]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id uABEX8vb031882 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 11 Nov 2016 09:33:10 -0500 From: Kamil Dudka To: Peter Stuge Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend Date: Fri, 11 Nov 2016 15:33:11 +0100 Message-ID: <1885552.pEofN6nT8x@kdudka-nb> User-Agent: KMail/4.14.10 (Linux/4.8.6-gentoo; KDE/4.14.24; x86_64; ; ) In-Reply-To: <20161111002358.GS31660@foo.stuge.se> References: <20161107031131.GG31660@foo.stuge.se> <36069894.ay4bUJqtHz@kdudka-nb> <20161111002358.GS31660@foo.stuge.se> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Fri, 11 Nov 2016 14:33:11 +0000 (UTC) X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Cc: cynede@gentoo.org, siarheit@google.com, libssh2-devel@cool.haxx.se Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uABEXJM7012865 On Friday, November 11, 2016 00:23:58 Peter Stuge wrote: > Hi Kamil, > > Kamil Dudka wrote: > > This patch seems to break detection of EVP_aes_128_ctr() while building > > against OpenSSL. > > Thank you very much for testing, it is much appreciated! > > I cleaned up the detection code a bit too much. > > The attached fixup patch applies on top of the previous withcrypto > commit and fixes detection for me. Yes, it works fine now with the patch applied. Thanks! Kamil > I've also pushed the fixup to my withcrypto branch. > > > I'm feeling comfortable about --with-crypto now, but it would of > course be great to get even more testing by as many as possible. > > If nothing new pops up I'll prepare a single patch for master. > > > //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 12 12:29:56 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uACBTQIq027968; Sat, 12 Nov 2016 12:29:51 +0100 Received: from mail-lf0-x230.google.com (mail-lf0-x230.google.com [IPv6:2a00:1450:4010:c07:0:0:0:230]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uACBTOvj027943 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 12 Nov 2016 12:29:25 +0100 Received: by mail-lf0-x230.google.com with SMTP id t196so28976706lff.3 for ; Sat, 12 Nov 2016 03:29:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=dfMfREAKQFqhGSSdsEYPVErTMp4YD6pFjbacKete5ic=; b=VPvRM+C53uQhoyq8Z92+QLGoy0ZyQM5xEMXJg3sQyx2f/H6mX7ssct899dSBIcB/4d YJ8jlDohOl6O97OzXVnBjEREXBkFbz8LaLBgQXkZCnaWM9xWxKxxsDcGxWFQLcmZV7Su 0L8Ewq5cLYT1MxhNQUg0eZQKRAK+Wpo+8OkPzgIgSdwRx2j5SxWJy/vb91f/Svg/+GBs s43D3xDUJeyNb/NjKjz0SLjc2Ll50X2vqjBKbtjtcpXoM1lEAvq733WOvH5zwkdSfb09 RrrcgQ8A+817OQ9kWKvr2oDVZPtwQEOi4G8q7o/uL8Bmg1fwbt376HKYsuGLaYANaB79 t0Dg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=dfMfREAKQFqhGSSdsEYPVErTMp4YD6pFjbacKete5ic=; b=KzqmkE5EEUWjv1xQ5e4i9jspXFsR4AnECHQN+M1IGnBbIh0g65rL7Qi9w1Yo3jA721 nFc+VZsQZXpbS0JS0EfxHt4N3mOuxhpGtbeH/8J4rscZnILr3JCA+HqE0WTUBBX4qz0a 9o9frZzRnsmaE0DoUKWl5JxuAhYILmBWPSoVlBzKlCHvIrptR/LEtScNKnBi5CeAjmkx 1kRi0D8pWabX/J9LyWMkTMnXrnXuMWR3hya8d4063WZw1vQ42si9YkEdGScjRZeZUfyG e+7AGrIO+4VVtXNoQBa6/ukQh55Mxeucne590m4/0OANXGT3vI1AdIA7LQjE+IvjAe+T 2L0Q== X-Gm-Message-State: ABUngvcNZCLdUXRM4mxPPmjh4hItvCMUscN1+sMvJ7MFzK+qWpJ9X0xUoKS4ntH0/99z03awuX7HwEZBHmhYHw== X-Received: by 10.25.75.213 with SMTP id y204mr2974117lfa.64.1478950160240; Sat, 12 Nov 2016 03:29:20 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 12 Nov 2016 03:29:19 -0800 (PST) In-Reply-To: <1885552.pEofN6nT8x@kdudka-nb> References: <20161107031131.GG31660@foo.stuge.se> <36069894.ay4bUJqtHz@kdudka-nb> <20161111002358.GS31660@foo.stuge.se> <1885552.pEofN6nT8x@kdudka-nb> From: Alexander Lamaison Date: Sat, 12 Nov 2016 11:29:19 +0000 X-Google-Sender-Auth: 1kxyb27gzDc19_L_EH5FmsyaP9g Message-ID: Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uACBTQIq027968 On 11 November 2016 at 14:33, Kamil Dudka wrote: > On Friday, November 11, 2016 00:23:58 Peter Stuge wrote: >> Hi Kamil, >> >> Kamil Dudka wrote: >> > This patch seems to break detection of EVP_aes_128_ctr() while building >> > against OpenSSL. >> >> Thank you very much for testing, it is much appreciated! >> >> I cleaned up the detection code a bit too much. >> >> The attached fixup patch applies on top of the previous withcrypto >> commit and fixes detection for me. > > Yes, it works fine now with the patch applied. Thanks! I've pushed the changes to master. Thanks Peter. And thanks Kamil for testing. Alex -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 12 13:18:10 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uACCHuL3030533; Sat, 12 Nov 2016 13:18:07 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uACCHsUP030420 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sat, 12 Nov 2016 13:17:54 +0100 Received: (qmail 5439 invoked by uid 1000); 12 Nov 2016 13:03:05 -0000 Date: Sat, 12 Nov 2016 13:03:05 +0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend Message-ID: <20161112130305.GW31660@foo.stuge.se> References: <20161107031131.GG31660@foo.stuge.se> <36069894.ay4bUJqtHz@kdudka-nb> <20161111002358.GS31660@foo.stuge.se> <1885552.pEofN6nT8x@kdudka-nb> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uACCHuL3030533 Alexander Lamaison wrote: > I've pushed the changes to master. Thanks Peter. And thanks Kamil > for testing. Thanks I guess, but I wanted this to sit for a bit longer, and I've found that it actually still needs work to cover all cases. I'll try to post a follow-up patch as soon as possible. //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 12 13:21:42 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uACCLeBc032663; Sat, 12 Nov 2016 13:21:41 +0100 Received: from mail-lf0-x236.google.com (mail-lf0-x236.google.com [IPv6:2a00:1450:4010:c07:0:0:0:236]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uACCLdwR032644 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 12 Nov 2016 13:21:39 +0100 Received: by mail-lf0-x236.google.com with SMTP id t196so29484215lff.3 for ; Sat, 12 Nov 2016 04:21:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=1a4cNdahVI4MOhV13LfcBSZbU+WnLHV3t4/INGLwt2E=; b=0A3LF3hUVdUZcs8FpOFBAER36oYmB2+r+bz/hPsUog+2bhzkZAL1LKJKSsFLU4mQ8i TSbZA4t9GPzYP893aPfCjBe1sGkacplrccyP9FZ4gkADYGtwRV64OY8U8oovbikr+0Bp aCv6BavlA/elD7u+jTdm6a+02Bdu8292/orEtM+jsWxrd2Pz13Di0uwl0wOiNJcZzXjD Cd1PkosfVtjhThIiJTwomVXXRbNnqPKDrTdDeNZOtzbhk3lkKLJU9DLJ5NI4oGoKA9RP Uj534wXWUS31Xk5OtIZrs2IzlIfi0jFU4MA5QibYc32WA7PGPASmQQw5g0i3uAz8S42N lh6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=1a4cNdahVI4MOhV13LfcBSZbU+WnLHV3t4/INGLwt2E=; b=X+Q3u0YjZWgKFHJWtjxIy9gTUftYW2spmwI1iQLom9KzZcPsSmZwLU3SG1tvjq1M8j 8KCEuv3QpwxYih4z8oMkb7ufUWLEkBxNKi//31+QRXLXZgZJNFZivuKOVVGg0t7IoCGh rodYN/C/q2vd5okpkUULb7xKBHYebqRWEFBaEFcPI8QosVUhNgcH/8pWBJEcypUXOjal tHyJHNeLYDIrRhFD4ndYLql5xut1+jvwi/1LwKjnHb7dapTHLxL5DG+QV6+dIDFBjPma KbvoKGj7gYBl8PcgiAuSSKsshAWXQL3yxdi7yrKySCJzLAWaVHe6NzcZCzv3oxPIWhNJ nfMw== X-Gm-Message-State: ABUngvd59iYsSMTD04sb+S2XbdhC8bVS8329BaRDixBoI/vH1KiFQzoLoCVc5XDMwwP84oZI+JoDOD9hrnRktQ== X-Received: by 10.25.10.131 with SMTP id 125mr4324058lfk.172.1478953295022; Sat, 12 Nov 2016 04:21:35 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 12 Nov 2016 04:21:34 -0800 (PST) In-Reply-To: <20161112130305.GW31660@foo.stuge.se> References: <20161107031131.GG31660@foo.stuge.se> <36069894.ay4bUJqtHz@kdudka-nb> <20161111002358.GS31660@foo.stuge.se> <1885552.pEofN6nT8x@kdudka-nb> <20161112130305.GW31660@foo.stuge.se> From: Alexander Lamaison Date: Sat, 12 Nov 2016 12:21:34 +0000 X-Google-Sender-Auth: 5fz8tR1uk84IE0y4OlgU030GCpc Message-ID: Subject: Re: [PATCH] configure.ac: Add --with-crypto= instead of many different --with-$backend To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uACCLeBc032663 On 12 November 2016 at 13:03, Peter Stuge wrote: > Alexander Lamaison wrote: >> I've pushed the changes to master. Thanks Peter. And thanks Kamil >> for testing. > > Thanks I guess, but I wanted this to sit for a bit longer, and I've > found that it actually still needs work to cover all cases. I think we need to be bolder with merging patches than we have been in the past otherwise they sit and rot. > I'll try to post a follow-up patch as soon as possible. Thanks. -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 16 22:45:13 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAGLic0M026594; Wed, 16 Nov 2016 22:45:05 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAGLiZxa026563 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 16 Nov 2016 22:44:36 +0100 Received: (qmail 29879 invoked from network); 16 Nov 2016 22:29:28 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 16 Nov 2016 22:29:28 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: Fixup series for new --with-crypto option Date: Wed, 16 Nov 2016 22:44:19 +0100 Message-Id: <1479332663-22166-1-git-send-email-peter@stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAGLic0M026594 [PATCH] docs/HACKING.CRYPTO: Improve documentation for autoconf build [PATCH] acinclude.m4: Make saved variables in [PATCH] acinclude.m4: Add CPPFLAGS=-I$prefix-dir/include in [PATCH] acinclude.m4: The mbedtls crypto backend actually requires These changes go from documentation improvements over cosmetics to fixes for two severe problems in the case of the last patches. I've tested these to work correctly with OpenSSL, mbedTLS and libgcrypt in /usr and with OpenSSL and mbedTLS installed in prefix directories. //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 16 22:45:14 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAGLjDsA027216; Wed, 16 Nov 2016 22:45:14 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAGLibtf026568 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 16 Nov 2016 22:44:37 +0100 Received: (qmail 29882 invoked from network); 16 Nov 2016 22:29:31 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 16 Nov 2016 22:29:31 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: [PATCH] docs/HACKING.CRYPTO: Improve documentation for autoconf build system Date: Wed, 16 Nov 2016 22:44:20 +0100 Message-Id: <1479332663-22166-2-git-send-email-peter@stuge.se> In-Reply-To: <1479332663-22166-1-git-send-email-peter@stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAGLjDsA027216 --- docs/HACKING.CRYPTO | 37 +++++++++++++++++++++---------------- 1 file changed, 21 insertions(+), 16 deletions(-) diff --git a/docs/HACKING.CRYPTO b/docs/HACKING.CRYPTO index 381b2a9..91e91e0 100644 --- a/docs/HACKING.CRYPTO +++ b/docs/HACKING.CRYPTO @@ -15,29 +15,34 @@ indicates the libssh2 core modules never use the function result. 0) Build system. -Add a new crypto backend to the autotools build system (./configure) as such: +Adding a crypto backend to the autotools build system (./configure) is easy: -* Add one new line to configure.ac: +0.1) Add one new line in configure.ac m4_set_add([crypto_backends], [newname]) -This automatically creates a new --with-crypto=newname option which users can -specify when invoking configure at compile-time to select the new backend. +This automatically creates a --with-crypto=newname option. -* Add a new m4_case stanza to acinclude.m4 within LIBSSH2_CRYPTO_CHECK, - with checks for library availability. A successful check should set - library linking variables. The LIBSSH2_LIB_HAVE_LINKFLAGS macro creates - such a variable automatically if the checked library can be found. +0.2) Add an m4_case stanza to LIBSSH2_CRYPTO_CHECK in acinclude.m4 -* Add a Makefile.newname.inc in the top-level directory which sets - CRYPTO_CSOURCES and CRYPTO_HHEADERS to the new backend source files, - and CRYPTO_LTLIBS to the libtool linking parameters for the library, set - e.g. by a LIBSSH2_LIB_HAVE_LINKFLAGS call in LIBSSH2_CRYPTO_CHECK. +This must check for all required libraries, and if found set and AC_SUBST a +variable with the library linking flags. The recommended method is to use +LIBSSH2_LIB_HAVE_LINKFLAGS from LIBSSH2_CRYPTO_CHECK, which automatically +creates and handles a --with-$newname-prefix option and sets an +LTLIBNEWNAME variable on success. -* Add a new block to src/Makefile.am: - if NEWNAME - include ../Makefile.newname.inc - endif +0.3) Create Makefile.newname.inc in the top-level directory + +This must set CRYPTO_CSOURCES, CRYPTO_HHEADERS and CRYPTO_LTLIBS. +Set CRYPTO_CSOURCES and CRYPTO_HHEADERS to the new backend source files +and set CRYPTO_LTLIBS to the required library linking parameters, e.g. +$(LTLIBNEWNAME) as generated by by LIBSSH2_LIB_HAVE_LINKFLAGS. + +0.4) Add a new block in src/Makefile.am + +if NEWNAME +include ../Makefile.newname.inc +endif 1) Crypto library initialization/termination. -- _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 16 22:45:15 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAGLjEjG027251; Wed, 16 Nov 2016 22:45:14 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAGLicBr026570 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 16 Nov 2016 22:44:38 +0100 Received: (qmail 29885 invoked from network); 16 Nov 2016 22:29:32 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 16 Nov 2016 22:29:32 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: [PATCH] acinclude.m4: Make saved variables in LIBSSH2_LIB_HAVE_LINKFLAGS uniform Date: Wed, 16 Nov 2016 22:44:21 +0100 Message-Id: <1479332663-22166-3-git-send-email-peter@stuge.se> In-Reply-To: <1479332663-22166-1-git-send-email-peter@stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAGLjEjG027251 --- acinclude.m4 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index b6eb7eb..81efa06 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -393,14 +393,14 @@ dnl dnl For conveniece, $4 is expanded if [lib]$1 is found. AC_DEFUN([LIBSSH2_LIB_HAVE_LINKFLAGS], [ - libssh2_lib_have_linkflags_LDFLAGS="$LDFLAGS" + libssh2_save_LDFLAGS="$LDFLAGS" test "${with_lib$1_prefix+set}" = set && LDFLAGS="$LDFLAGS${LDFLAGS:+ }-L${with_lib$1_prefix}/lib" AC_LIB_HAVE_LINKFLAGS([$1], [$2], [$3]) - LDFLAGS="$libssh2_lib_have_linkflags_LDFLAGS" + LDFLAGS="$libssh2_save_LDFLAGS" if test "$ac_cv_lib$1" = "yes"; then : $4 @@ -416,10 +416,10 @@ m4_case([$1], LIBSREQUIRED="$LIBSREQUIRED${LIBSREQUIRED:+ }libssl libcrypto" # Not all OpenSSL have AES-CTR functions. - save_LIBS="${LIBS}" + libssh2_save_LIBS="$LIBS" LIBS="$LIBS $LIBSSL" AC_CHECK_FUNCS(EVP_aes_128_ctr) - LIBS="${save_LIBS}" + LIBS="$libssh2_save_LIBS" found_crypto="$1" found_crypto_str="OpenSSL (AES-CTR: ${ac_cv_func_EVP_aes_128_ctr:-N/A})" -- _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 16 22:45:16 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAGLjFpP027283; Wed, 16 Nov 2016 22:45:16 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAGLidEA026574 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 16 Nov 2016 22:44:39 +0100 Received: (qmail 29888 invoked from network); 16 Nov 2016 22:29:33 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 16 Nov 2016 22:29:33 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: [PATCH] acinclude.m4: Add CPPFLAGS=-I$prefix-dir/include in LIBSSH2_LIB_HAVE_LINKFLAGS Date: Wed, 16 Nov 2016 22:44:22 +0100 Message-Id: <1479332663-22166-4-git-send-email-peter@stuge.se> In-Reply-To: <1479332663-22166-1-git-send-email-peter@stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAGLjFpP027283 This is absolutely neccessary for header files to be found when AC_LIB_HAVE_LINKFLAGS searches for libraries. --- acinclude.m4 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/acinclude.m4 b/acinclude.m4 index 81efa06..8a2ea6d 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -393,10 +393,13 @@ dnl dnl For conveniece, $4 is expanded if [lib]$1 is found. AC_DEFUN([LIBSSH2_LIB_HAVE_LINKFLAGS], [ + libssh2_save_CPPFLAGS="$CPPFLAGS" libssh2_save_LDFLAGS="$LDFLAGS" - test "${with_lib$1_prefix+set}" = set && + if test "${with_lib$1_prefix+set}" = set; then + CPPFLAGS="$CPPFLAGS${CPPFLAGS:+ }-I${with_lib$1_prefix}/include" LDFLAGS="$LDFLAGS${LDFLAGS:+ }-L${with_lib$1_prefix}/lib" + fi AC_LIB_HAVE_LINKFLAGS([$1], [$2], [$3]) @@ -404,6 +407,8 @@ AC_DEFUN([LIBSSH2_LIB_HAVE_LINKFLAGS], [ if test "$ac_cv_lib$1" = "yes"; then : $4 + else + CPPFLAGS="$libssh2_save_CPPFLAGS" fi ]) -- _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 16 22:45:18 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAGLjGdL027330; Wed, 16 Nov 2016 22:45:17 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAGLidV4026577 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 16 Nov 2016 22:44:40 +0100 Received: (qmail 29891 invoked from network); 16 Nov 2016 22:29:33 -0000 Received: from localhost (HELO stuge.se) (127.0.0.1) by localhost with SMTP; 16 Nov 2016 22:29:33 -0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: [PATCH] acinclude.m4: The mbedtls crypto backend actually requires libmbedcrypto Date: Wed, 16 Nov 2016 22:44:23 +0100 Message-Id: <1479332663-22166-5-git-send-email-peter@stuge.se> In-Reply-To: <1479332663-22166-1-git-send-email-peter@stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAGLjGdL027330 Examples can't be linked with libmbedtls but need libmbedcrypto, and any users of libssh2 which use libtool and libssh2.la would encounter the same problem. This changes the mbedtls detection to search for libmbedcrypto, which is the actual dependency for the backend. --- Makefile.mbedTLS.inc | 2 +- acinclude.m4 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.mbedTLS.inc b/Makefile.mbedTLS.inc index c22e51a..b9f19fc 100644 --- a/Makefile.mbedTLS.inc +++ b/Makefile.mbedTLS.inc @@ -1,3 +1,3 @@ CRYPTO_CSOURCES = mbedtls.c CRYPTO_HHEADERS = mbedtls.h -CRYPTO_LTLIBS = $(LTLIBMBEDTLS) +CRYPTO_LTLIBS = $(LTLIBMBEDCRYPTO) diff --git a/acinclude.m4 b/acinclude.m4 index 8a2ea6d..c0e89a1 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -439,7 +439,7 @@ m4_case([$1], ], [mbedtls], [ - LIBSSH2_LIB_HAVE_LINKFLAGS([mbedtls], [], [#include ], [ + LIBSSH2_LIB_HAVE_LINKFLAGS([mbedcrypto], [], [#include ], [ AC_DEFINE(LIBSSH2_MBEDTLS, 1, [Use $1]) found_crypto="$1" support_clear_memory=yes -- _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 19 17:09:39 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAJG918q027413; Sat, 19 Nov 2016 17:09:33 +0100 Received: from mail-wm0-x232.google.com (mail-wm0-x232.google.com [IPv6:2a00:1450:400c:c09:0:0:0:232]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAJG8xsu027186 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sat, 19 Nov 2016 17:08:59 +0100 Received: by mail-wm0-x232.google.com with SMTP id f82so80568842wmf.1 for ; Sat, 19 Nov 2016 08:09:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=PGQqBievdnLOTUFncRLarSonRAP7YOebT2n4a4VVkr0=; b=JXDjEyN5gDIArBmp24N3ausCra7CbDPZAu+Pp1YWo6ziq/IkQ6iH6QtsHI/VMz/1o7 YrGft0tEiqLQBCqBj/gpApv1l0nzx9ybS5BmSkZj+xyMZ/DTva4rtyFOWpGuwKB2TjLD sYXpyObM6MNnzWbTeb0fPSsyT/h7Bw4m7WKsQj+jt5TEBThsDDfuyaaNQHXTj32/b1RR 3NGC6Opk9nXpZacN92fKWkwXzwGUdsohp5VqNs6vJQNzHe55cfafzZkxvJ6+S02mcTUD lD0lfcFWGhgRQYqFz6oaA8p1KkdYztbma6gwHRzVgdi/fCo8AbydC4cl7YJn3Hc71HRw oNbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=PGQqBievdnLOTUFncRLarSonRAP7YOebT2n4a4VVkr0=; b=GuaP3vxwbDl3DWC/Dd/Z/mAMYH2Vr1fFc9xOMHAVirxsy/A4pPRGiZIPeF+tlwbiHA Cx2oDn62sVCY9KFAHiH7N8P97n7D4YCTDZ07cSruOhzl5fkMDRiGFSjVj8Y+Q51E8gq9 Jlges1jpcKPz8T3dpftmGYQgW3QDNsJdMdTHRH4hwI4D0tLIjuiFe00TNKmtcMHb5rHt aAKQ1tlyORrz8g2OFheqfttZP2a5Yhwq0fFbeVjs6BCzH5CFoWKUH0XDKa5PBm5/Hd+i dI6r6xFtWI8OD1CPFhDNtR7k1ZoafQX9OtYsvoTxRrGRt+eVJZs0JClQ8mfsl3XzzoD1 FfmQ== X-Gm-Message-State: AKaTC02h2ZS+mqUVp1mB5zIt1kcXm0+kANWsDNbK7WWy/vR5l9PdZGkxEaadKDii/Pfu0NJRFxIj5TInmF9Gig== X-Received: by 10.46.5.149 with SMTP id 143mr2828380ljf.73.1479571734668; Sat, 19 Nov 2016 08:08:54 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sat, 19 Nov 2016 08:08:54 -0800 (PST) In-Reply-To: <1479332663-22166-1-git-send-email-peter@stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> From: Alexander Lamaison Date: Sat, 19 Nov 2016 16:08:54 +0000 X-Google-Sender-Auth: SCQCUOJa8XoZ4agpGvRe1svdRZA Message-ID: Subject: Re: Fixup series for new --with-crypto option To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAJG918q027413 On 16 November 2016 at 21:44, Peter Stuge wrote: > [PATCH] docs/HACKING.CRYPTO: Improve documentation for autoconf build > [PATCH] acinclude.m4: Make saved variables in > [PATCH] acinclude.m4: Add CPPFLAGS=-I$prefix-dir/include in > [PATCH] acinclude.m4: The mbedtls crypto backend actually requires > > These changes go from documentation improvements over cosmetics to > fixes for two severe problems in the case of the last patches. > > I've tested these to work correctly with OpenSSL, mbedTLS and libgcrypt > in /usr and with OpenSSL and mbedTLS installed in prefix directories. Could you push these to your repo? Makes it a little easier to merge. Thanks, Alex -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sat Nov 19 18:03:44 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAJH3Uje018828; Sat, 19 Nov 2016 18:03:40 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAJH3SUc018677 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sat, 19 Nov 2016 18:03:29 +0100 Received: (qmail 5602 invoked by uid 1000); 19 Nov 2016 17:48:10 -0000 Date: Sat, 19 Nov 2016 17:48:10 +0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: Re: Fixup series for new --with-crypto option Message-ID: <20161119174810.GE21523@foo.stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAJH3Uje018828 Alexander Lamaison wrote: > > These changes go from documentation improvements over cosmetics to > > fixes for two severe problems in the case of the last patches. > > > > I've tested these to work correctly with OpenSSL, mbedTLS and libgcrypt > > in /usr and with OpenSSL and mbedTLS installed in prefix directories. > > Could you push these to your repo? Makes it a little easier to merge. Yes of course - now in the withcrypto branch. Thanks! //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Sun Nov 27 19:38:07 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uARIao2i023381; Sun, 27 Nov 2016 19:38:01 +0100 Received: from mail-lf0-x232.google.com (mail-lf0-x232.google.com [IPv6:2a00:1450:4010:c07:0:0:0:232]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uARIanUJ023349 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Sun, 27 Nov 2016 19:36:49 +0100 Received: by mail-lf0-x232.google.com with SMTP id c13so81417348lfg.0 for ; Sun, 27 Nov 2016 10:36:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=ksLuLgtj9o5CQZ9Xk2EUqTWrNq3gmVNkTXeqBRkz6nU=; b=hxEVReNJXFIqanTaDrYLN+Sd9CRTZzmlcXkQTQY8Czdvk7kkJBiYHMpzQtFu9/O/wn HOO4dgRrMtT4l0e6bDBQCysLmRk0CCCyB5gmJ4pWCln1/YFSAR1VzrN8xjPYzNEuLGwD Q5cmbLj6FdaMhewOvs83XMuus/ozMqWbx+1N2qjCvVx7I1/osEReRHCeUtUtzfVjqtl2 F7/I9vsBLzmkUgGq3t7fszXs8ZCALdKKb2dkMxYrphinDKqmtGaPaMDC2CWhQJD6RLPs fb4XBS0Zwepd5Q5dTJGFXiuDgJ/e6Qo+1helmMWT4A8aDkUIj7LQsNNGYDVxg3kwt/Tm zt9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=ksLuLgtj9o5CQZ9Xk2EUqTWrNq3gmVNkTXeqBRkz6nU=; b=Q8msLIrum42w3vW4F6RyqvaMFUAvrStWoR2lz1YQeHklGFWF3M8JJuXniypo14iVnx 3bREdL3KURE+e7e8Br+jZkUN1w25e3pw2SPRlZmPNHrPWzHyofQb4/woIVlC8WasvBnt ZnVFNkH0z4k5oeftjan7SVju4ZZCZxPlTJJnOOLnhNvCJXgkMRX5/WWL37s/ZIzxVjva AMqb9ypdp7V+KyGv0u6bZpJ16XEN+oSTbCuL5UgKSqoXQcZ76kiVpACgyq5pe22Dh7lu 11h/FCsD6xMBG4xOaIUEGeE2vk8Hv/eWWruSlwMZYw/ywTlSku5yPv6I15zk8xURtEPe 6uQw== X-Gm-Message-State: AKaTC02LyGIZeDL3HYfsfA5LvHS3HFz0Ht6Jw1FkIjFSKepQd+dWVd3eU4VNxfia8SSO7p5HsMu+mGKdZNoJ3Q== X-Received: by 10.25.10.131 with SMTP id 125mr7060897lfk.172.1480271804963; Sun, 27 Nov 2016 10:36:44 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.5.9 with HTTP; Sun, 27 Nov 2016 10:36:44 -0800 (PST) In-Reply-To: <20161119174810.GE21523@foo.stuge.se> References: <1479332663-22166-1-git-send-email-peter@stuge.se> <20161119174810.GE21523@foo.stuge.se> From: Alexander Lamaison Date: Sun, 27 Nov 2016 18:36:44 +0000 X-Google-Sender-Auth: DacPg0V_GTefrdy9tuK_FtY_vEg Message-ID: Subject: Re: Fixup series for new --with-crypto option To: libssh2 development X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uARIao2i023381 On 19 November 2016 at 17:48, Peter Stuge wrote: > Alexander Lamaison wrote: >> > These changes go from documentation improvements over cosmetics to >> > fixes for two severe problems in the case of the last patches. >> > >> > I've tested these to work correctly with OpenSSL, mbedTLS and libgcrypt >> > in /usr and with OpenSSL and mbedTLS installed in prefix directories. >> >> Could you push these to your repo? Makes it a little easier to merge. > > Yes of course - now in the withcrypto branch. Thanks! Merged. Thanks. -- Swish - Easy SFTP for Windows Explorer (http://www.swish-sftp.org) _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Mon Nov 28 01:38:25 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAS0c0wh000352; Mon, 28 Nov 2016 01:38:20 +0100 Received: from homiemail-a3.g.dreamhost.com (homie.mail.dreamhost.com [208.97.132.208]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAS0bv1g000347 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Mon, 28 Nov 2016 01:37:59 +0100 Received: from homiemail-a3.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a3.g.dreamhost.com (Postfix) with ESMTP id 30F6E28406E for ; Sun, 27 Nov 2016 16:37:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=eschatologist.net; h=from :content-type:content-transfer-encoding:mime-version:subject :message-id:date:to; s=eschatologist.net; bh=/1qNENwpvOAJ4DhUfhW g2+Obo2o=; b=Ex4T8rLM/tDLjlg4bJ8JCJgWf6Ov6Q2LEuTUnIqnaQetaDMTsQi LePgZJ6ywCy9fjU9oSLh+v9t8x35gmIfk+4NdeGIKd0QKPeNP+bcjhoxDHH3ChRP MvyIUeQA99+RnSlV2yyEpgawS1qPqjmWox/2GtMC/20wOqkJz+MjnQpE= Received: from [10.0.1.205] (c-73-189-131-221.hsd1.ca.comcast.net [73.189.131.221]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: cmhanson@eschatologist.net) by homiemail-a3.g.dreamhost.com (Postfix) with ESMTPSA id 2175E28406A for ; Sun, 27 Nov 2016 16:37:58 -0800 (PST) From: Chris Hanson Mime-Version: 1.0 (Mac OS X Mail 10.2 \(3259\)) Subject: libssh2 crypto back-ends: need for bignum access Message-Id: Date: Sun, 27 Nov 2016 16:37:56 -0800 To: libssh2-devel@cool.haxx.se X-Mailer: Apple Mail (2.3259) X-MIME-Autoconverted: from quoted-printable to 8bit by giant.haxx.se id uAS0bv1g000347 X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAS0c0wh000352 I was wondering if someone who has an understanding of libssh2 crypto back-end implementation could describe why it needs access to the crypto system’s bignum implementation. What I’d like to know specifically is whether this just an implementation artifact (i.e. just how libssh2 happened to be written) or whether this is actually necessary to implement the SSHv2 protocol correctly/securely. What am I really trying to do? Right now there’s no back-end that can use CommonCrypto on Darwin-based platforms without using internals, because CommonCrypto doesn’t expose its bignum implementation as public API. If there’s a real need to expose this for a correct implementation, I’d like to file a bug with Apple that contains a detailed justification. If there’s not a real need for it, then I might look into what’s needed to wire CommonCrypto up without using its bignum implementation. -- Chris _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Mon Nov 28 02:07:46 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAS17YY4016444; Mon, 28 Nov 2016 02:07:43 +0100 Received: from foo.stuge.se (foo.stuge.se [212.116.89.98]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAS17TZ4016380 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 28 Nov 2016 02:07:30 +0100 Received: (qmail 3993 invoked by uid 1000); 28 Nov 2016 01:51:38 -0000 Date: Mon, 28 Nov 2016 01:51:38 +0000 From: Peter Stuge To: libssh2-devel@cool.haxx.se Subject: Re: libssh2 crypto back-ends: need for bignum access Message-ID: <20161128015138.GA21523@foo.stuge.se> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAS17YY4016444 Chris Hanson wrote: > I was wondering if someone who has an understanding of libssh2 > crypto back-end implementation could describe why it needs access > to the crypto system’s bignum implementation. The SSH 2 protocol sends "mpint" values in various messages. See RFC 4251 5. on bottom of page 8 for the wire format. The ssh-dss public key format is REQUIRED, and ssh-rsa is RECOMMENDED, by RFC 4253 6.6. on pages 13-14. Finally, RFC 4253 8. also uses mpint in the DH key exchange. Search for SSH_MSG_KEXDH_INIT and SSH_MSG_KEXDH_REPLY. > whether this is actually necessary to implement the SSHv2 protocol > correctly/securely. Yes. > If there’s a real need to expose this for a correct implementation, > I’d like to file a bug with Apple that contains a detailed > justification. Cool. RFC 4251 and 4253 are good references. See also RFC 4419. //Peter _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 30 03:38:53 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAU2cKQW025064; Wed, 30 Nov 2016 03:38:45 +0100 Received: from mail-qk0-x22e.google.com (mail-qk0-x22e.google.com [IPv6:2607:f8b0:400d:c09:0:0:0:22e]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAU2cIVs025012 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Wed, 30 Nov 2016 03:38:19 +0100 Received: by mail-qk0-x22e.google.com with SMTP id n21so196054887qka.3 for ; Tue, 29 Nov 2016 18:38:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmgsystemsinc-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=eqJs534ZfnBBdXvf8ud0zbiav25f1q/O9MIDE2G0brY=; b=l41enbg5a3TMa++YW+C+htR4H6NYAO/BMRLrMfbTC/a/5WCwWO51tPMY3bDHDMU90p Ca14a476Li1UaZ5UDFHcVFeyJdFJ8qyvM2uNOsGuLaEDy3lBRvOC/BSQmTFZCBi4XDoI EJJVm8vv4/y8EbxZ0TpV5OSOUi/aAlahyKQmhq5GDjGIxKUxw8UJCX5gJRgB17Y3t7dl 89tCiWnxYd/Dw+9qdXs7N2FHfF0s1xnT7esLvTtHkV7+PrHJEJfHk8xn235rhNffVWZ1 K0bzqAenCx3M2snHH4XVE+oWT4hEIYDbcIl+5arVZtW3Hml4EAfg9tmTdqtJCe7PAnqh jIbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=eqJs534ZfnBBdXvf8ud0zbiav25f1q/O9MIDE2G0brY=; b=jwdYQ8K4bmcxWpzTL9/a9vaFUnFbV7aHNwcJRGol+pQoOymwHiNs9wydqi6nQi6PwO FElsU3LZnXI95FC8+Lj5xG2ZQDVYw+PF5F36rNjrEy0i7tfoE3d7y3BGLpEQj0DO2iZ3 0wjOign3JrLlRuPQIKzOhh8fi/lvAuOjsybc6+OojK9HfJOP78BiiIHdiI/CqDelVa3y SF6QQ/ljqeqN78+BA5xAcJN7JIesvZQhk/fBaw1cZyRlEBP9EROqt8x6Rwt28892jxZA q1eseBTDNgi5VwnmR6Kl6vfe3804N4b6waFYl7itX2mLNzCUJgRc/uT7tCASh9vIJ021 O9Xg== X-Gm-Message-State: AKaTC00AyFpdolJEsf8mGQ7vU380vjDDVGloySo5rNKfMou+1k6x2R7nUIcZTOdyVAadVg== X-Received: by 10.233.235.67 with SMTP id b64mr29946735qkg.156.1480473495065; Tue, 29 Nov 2016 18:38:15 -0800 (PST) Received: from [192.168.215.86] (pool-96-241-49-88.washdc.fios.verizon.net. [96.241.49.88]) by smtp.googlemail.com with ESMTPSA id 1sm32488874qte.46.2016.11.29.18.38.14 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Nov 2016 18:38:14 -0800 (PST) Subject: libssh2 1.8.0 Code Analysis results. To: libssh2-devel@cool.haxx.se References: From: "George M. Garner Jr." Message-ID: <355b75ff-cc5e-60cc-83f3-93cb255568fa@gmgsystemsinc.com> Date: Tue, 29 Nov 2016 21:38:14 -0500 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:45.0) Gecko/20100101 Thunderbird/45.5.0 MIME-Version: 1.0 In-Reply-To: X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8"; Format="flowed" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAU2cKQW025064 The following are the code analysis results compiling using Visual Studio 2015 with wincng. Note in particular the two possible stack-based buffer overruns. Running Code Analysis for C/C++... Generating Code... Creating library .\libssh2-2.1.8.0\win32\v140\Win32\WinCNG DLL Debug\libssh2.lib and object .\libssh2-2.1.8.0\win32\v140\Win32\WinCNG DLL Debug\libssh2.exp libssh2.vcxproj -> .\libssh2-2.1.8.0\win32\v140\Win32\WinCNG DLL Debug\libssh2.dll libssh2.vcxproj -> .\libssh2-2.1.8.0\win32\v140\Win32\WinCNG DLL Debug\libssh2.pdb (Full PDB) .\libssh2-2.1.8.0\src\kex.c(270): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\kex.c(299): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\kex.c(894): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\kex.c(923): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1088): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1091): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1094): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1097): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1110): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1113): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1116): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\knownhost.c(1119): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\misc.c(362): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\misc.c(367): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\misc.c(373): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\misc.c(466): warning C6386: Buffer overrun while writing to 'buffer+msglen': the writable size is '1536' bytes, but '1537' bytes might be written. .\libssh2-2.1.8.0\src\scp.c(297): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\scp.c(839): warning C6031: Return value ignored: 'snprintf'. .\libssh2-2.1.8.0\src\transport.c(90): warning C6386: Buffer overrun while writing to 'buffer': the writable size is '256' bytes, but 'used++' bytes might be written. _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel From libssh2-devel-bounces@cool.haxx.se Wed Nov 30 20:35:52 2016 Return-Path: Received: from www.haxx.se (localhost.localdomain [127.0.0.1]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTP id uAUJZOqr022997; Wed, 30 Nov 2016 20:35:45 +0100 Received: from homiemail-a37.g.dreamhost.com (homie.mail.dreamhost.com [208.97.132.208]) by giant.haxx.se (8.15.2/8.15.2/Debian-4) with ESMTPS id uAUJZKBk021788 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Wed, 30 Nov 2016 20:35:22 +0100 Received: from homiemail-a37.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a37.g.dreamhost.com (Postfix) with ESMTP id 8D5ED20806C for ; Wed, 30 Nov 2016 11:35:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=eschatologist.net; h=from :content-type:content-transfer-encoding:mime-version:subject :date:references:to:in-reply-to:message-id; s=eschatologist.net; bh=1logLcqUNBnwbvp/q/TS/i6QLVU=; b=Or56mNm+x5YMm0ruqGBPGpIT0NaC ruY5AYx3UX7PkPRlZO3vNJDPQwFj4Z/Hr1yFaVqCVLJDQtZKudnuyHI+Q9GMnkHu MtFt/jmcC7axaLkLvPGylizNwnWZn7gCO+94ghog85nGpZF/har5SzcyCxBAIAve WyF/VelV77aXCO4= Received: from [10.0.1.205] (c-73-189-131-221.hsd1.ca.comcast.net [73.189.131.221]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: cmhanson@eschatologist.net) by homiemail-a37.g.dreamhost.com (Postfix) with ESMTPSA id 6ED00208063 for ; Wed, 30 Nov 2016 11:35:20 -0800 (PST) From: Chris Hanson Mime-Version: 1.0 (Mac OS X Mail 10.2 \(3259\)) Subject: Re: libssh2 crypto back-ends: need for bignum access Date: Wed, 30 Nov 2016 11:35:19 -0800 References: <20161128015138.GA21523@foo.stuge.se> To: libssh2 development In-Reply-To: <20161128015138.GA21523@foo.stuge.se> Message-Id: <0642DE7F-679A-45C8-A106-6151BB6A4096@eschatologist.net> X-Mailer: Apple Mail (2.3259) X-MIME-Autoconverted: from quoted-printable to 8bit by giant.haxx.se id uAUJZKBk021788 X-BeenThere: libssh2-devel@cool.haxx.se X-Mailman-Version: 2.1.22 Precedence: list List-Id: libssh2 development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: libssh2 development Content-Type: text/plain; charset="utf-8" Errors-To: libssh2-devel-bounces@cool.haxx.se Sender: "libssh2-devel" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by giant.haxx.se id uAUJZOqr022997 On Nov 27, 2016, at 5:51 PM, Peter Stuge wrote: > > Cool. RFC 4251 and 4253 are good references. See also RFC 4419. Thanks for the details, they’ll be very useful! -- Chris _______________________________________________ libssh2-devel https://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel