From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Robert Pluim Newsgroups: gmane.emacs.bugs Subject: bug#33780: network-stream.el: network-stream-certificate always returns nil Date: Mon, 14 Jan 2019 17:25:55 +0100 Message-ID: References: <36f7918ec93135504092dc856a4490c846f6e947.camel@dracon.is> <97b430dc5524473a7ed3af1b903644880db057ff.camel@dracon.is> <83o98mf7sv.fsf@gnu.org> <83imyrdyae.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1547483806 12071 195.159.176.226 (14 Jan 2019 16:36:46 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 14 Jan 2019 16:36:46 +0000 (UTC) Cc: darael@dracon.is, tzz@lifelogs.com, 33780@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Jan 14 17:36:41 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gj5E8-0002yQ-Cn for geb-bug-gnu-emacs@m.gmane.org; Mon, 14 Jan 2019 17:36:40 +0100 Original-Received: from localhost ([127.0.0.1]:41523 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gj5GF-0005Ft-8y for geb-bug-gnu-emacs@m.gmane.org; Mon, 14 Jan 2019 11:38:51 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:57846) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gj54r-0004D1-8A for bug-gnu-emacs@gnu.org; Mon, 14 Jan 2019 11:27:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gj54p-0005aW-EW for bug-gnu-emacs@gnu.org; Mon, 14 Jan 2019 11:27:05 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:59962) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gj54o-0005Zn-GR for bug-gnu-emacs@gnu.org; Mon, 14 Jan 2019 11:27:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gj54o-0008Ov-6B for bug-gnu-emacs@gnu.org; Mon, 14 Jan 2019 11:27:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Robert Pluim Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 14 Jan 2019 16:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33780 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 33780-submit@debbugs.gnu.org id=B33780.154748316632228 (code B ref 33780); Mon, 14 Jan 2019 16:27:02 +0000 Original-Received: (at 33780) by debbugs.gnu.org; 14 Jan 2019 16:26:06 +0000 Original-Received: from localhost ([127.0.0.1]:59243 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gj53t-0008Nj-R1 for submit@debbugs.gnu.org; Mon, 14 Jan 2019 11:26:06 -0500 Original-Received: from mail-wr1-f51.google.com ([209.85.221.51]:44530) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gj53q-0008N2-VE for 33780@debbugs.gnu.org; Mon, 14 Jan 2019 11:26:04 -0500 Original-Received: by mail-wr1-f51.google.com with SMTP id z5so23569292wrt.11 for <33780@debbugs.gnu.org>; Mon, 14 Jan 2019 08:26:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :mime-version:content-transfer-encoding; bh=EYREG0vxQwFp6YZUoqf/68lNSm9L1DKimfyfPaaroo4=; b=CdFrU2jYgfyICOzwqzcJnIolpPYLqkHvDuaJDtZXxze0RfPtDbBx3dxI+HxyEN4owG WzWPsHo+e87cJtWcOZog4WNUtL4mr1c3SiGV6LLm9suzjWjHdCW0ZPoa+wJyVW7laxSu xZzQ4kp18+NpDuzGCkPn7DrQ5x4+hn1MyCxjxBAdhFaldjt9GNg6c5hjeQucO9CBlk8O kckzf/BffE/xLzE8IV9aOuVH537iN7ra11Qc1pHOXfq5hOee7Y+7dL/NvSVAF/SKlaVw rOYDMkNSREizv1rSpslmFAZwtrEAb9GyqldcUvwWJuvFIQSmfEaOu0wIZkRquX1gEIm2 Z75w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-transfer-encoding; bh=EYREG0vxQwFp6YZUoqf/68lNSm9L1DKimfyfPaaroo4=; b=q/xYtu+MCplI/yhVa0ofK8lGhWVzEACca3e99yyagKqAFneV93BPeSjcyn7J2SRPvT VSzOVazqjnSpCD0noCuiCc3eOkxZl94G0jMxqA5p82oRhNHusCXLjyXEHxPsCGKxG15u HKPA9FsjrcZlgPrX4dXcAtCUe0+kD1SILBmeOJFHCSaej7mRYXBp0oNKTqNA5sYUS5az LGRORtiRRWPrtPRQ8mPACYLltE5tVyfyqr12pi/iAYDFJBGh3CTVsID+HptxeZrRtdvc pCKmdgDcS5AdXvbDouZL8RrgGSgqc+pjrub8MVhoWlcfXuuETC/06SjmN6dvfXF6dX/R SXIw== X-Gm-Message-State: AJcUukdLUHCyC+ZTKLE2hX4XczFKY0v2iP1S2yOb8C1nY09cx4lZAXoN ObwA/CWjAKQYpQrjdY1XY8ZUqlI8 X-Google-Smtp-Source: ALg8bN6U1Z8Do3885HtdXaPagNMKOX6FIZq6cbpA93XibtB9QhWlQvgvun5WrrAhGIZ9zq01Mzui7A== X-Received: by 2002:adf:f401:: with SMTP id g1mr25782446wro.103.1547483156773; Mon, 14 Jan 2019 08:25:56 -0800 (PST) Original-Received: from rpluim-mac ([149.5.228.1]) by smtp.gmail.com with ESMTPSA id s5sm20244095wmh.37.2019.01.14.08.25.55 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 14 Jan 2019 08:25:55 -0800 (PST) In-Reply-To: <83imyrdyae.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 14 Jan 2019 18:00:41 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:154434 Archived-At: Eli Zaretskii writes: >> From: Robert Pluim >> Cc: darael@dracon.is, tzz@lifelogs.com, 33780@debbugs.gnu.org >> Date: Mon, 14 Jan 2019 14:27:15 +0100 >>=20 >> Fixed. I was about to push, then got paranoid, so I wrote a few tests >> for 'open-network-stream', which gave me a few suprises. I had to add >> the following in network-stream-tests.el: >>=20 >> +(require 'network-stream) >> +; The require above is needed for 'open-network-stream', but it pulls >> +; in nsm, which then makes the :nowait tests fail unless we disable >> +; the nsm. >> +(setq network-security-level 'low) >>=20 >> otherwise both the old and my new ':nowait t' tests failed. Is that >> expected? > > Not sure. Did you understand why it failed? IOW, what does nsm have > to do with the failures? When I ran the equivalent 'open-network-stream' code to the tests manually in 'emacs -Q', I get a prompt from nsm asking me whether to accept the certificate of the server I=CA=BCm connecting to. When running the test suite, we=CA=BCre in batch mode, so there=CA=BCs no w= ay to answer that question, as far as I know, so turning off the nsm is the only way to go. This only fails for the existing tests with ':nowait t', since then I suspect nsm gets called automatically, whilst in the ':nowait nil' case nsm never gets called (the existing tests all use 'make-network-process' directly, rather than 'open-network-stream', so they bypass nsm). This could be seen as a bug in nsm, I suppose, since na=C3=AFvely you wouldn't expect loading it to change the behaviour of 'make-network-process'. Robert