From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#41960: nntp.el: Switch back to CAPABILITIES command? Date: Sun, 19 Jul 2020 02:32:57 +0200 Message-ID: <87mu3wibt2.fsf@gnus.org> References: <87sgeqbh56.fsf@kyleam.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22414"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 41960@debbugs.gnu.org To: Kyle Meyer Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Jul 19 02:34:11 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jwxHP-0005ih-Fp for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Jul 2020 02:34:11 +0200 Original-Received: from localhost ([::1]:43496 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jwxHN-0004dW-Uc for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Jul 2020 20:34:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41722) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jwxHG-0004dP-Qv for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 20:34:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:47961) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jwxHG-0004PD-He for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 20:34:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jwxHG-0005w1-Ef for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 20:34:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Jul 2020 00:34:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41960 X-GNU-PR-Package: emacs Original-Received: via spool by 41960-submit@debbugs.gnu.org id=B41960.159511879222757 (code B ref 41960); Sun, 19 Jul 2020 00:34:02 +0000 Original-Received: (at 41960) by debbugs.gnu.org; 19 Jul 2020 00:33:12 +0000 Original-Received: from localhost ([127.0.0.1]:59507 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jwxGR-0005ux-Oc for submit@debbugs.gnu.org; Sat, 18 Jul 2020 20:33:11 -0400 Original-Received: from quimby.gnus.org ([95.216.78.240]:54950) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jwxGP-0005uk-Dt for 41960@debbugs.gnu.org; Sat, 18 Jul 2020 20:33:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=DU6z85qc/xLjl01093m4kJ9vfFFMhfXJlLM3miDeLAQ=; b=JnHN9yWw9/O/J3bZq8MVaIqV2g c5Mk6ECXtmfjxTJjHI+F07zg8SFuFaalkP5xFzXa+nO0eZKeJayTVu926mhJpMVKZM7KQ8khye75u Cs+6vXLh08jHhyY/CIgX8RRuNe9wwFFyY7tIHRGFcVbuQXK8sEmzGXr1gH0ndi8G5f0w=; Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jwxGE-00073x-9b; Sun, 19 Jul 2020 02:33:01 +0200 In-Reply-To: <87sgeqbh56.fsf@kyleam.com> (Kyle Meyer's message of "Sat, 20 Jun 2020 02:33:25 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:183184 Archived-At: Kyle Meyer writes: > A specific case where using HELP instead of CAPABILITIES causes an issue > is with public-inbox's [2] NNTP service, such as the one hosted at > . public-inbox doesn't include a list of > commands in its HELP output. That is, it's not following the > convention, but it is still following the specification. Because > nntp-open-connection tries to detect capabilities with HELP, it doesn't > catch the properly advertised STARTTLS capability and fails to upgrade > to a TLS connection. > > I'm guessing that the server from bug#12763 didn't recognize > CAPABILITIES because it was based on RFC 977. However, given RFC 3977 > supersedes 977 and is from 2006, does it make sense at this point to > assume CAPABILITIES is supported? Yeah, nntp.el should really use CAPABILITIES here, but working around buggy NNTP software (i.e., Typhoon) would also be nice... because NNTP servers don't exactly get updated a lot these days. Hm... I think I see a way to do both here: `open-network-stream' today only takes a string as a capability command, so we can't send different commands based on the server software. But we could easily extend that function to allow taking a function, and use the greeting as the input parameter, and then do HELP for Typhoon and CAPABILITIES for everything else. I'll give that a whirl and see how it goes... -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no