From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#35739: Bad signature from GNU ELPA Date: Thu, 23 May 2019 07:52:46 +0300 Message-ID: <838sux7owx.fsf@gnu.org> References: <87mujog0ao.fsf@gmail.com> <835zqca15y.fsf@gnu.org> <83woir92vl.fsf@gnu.org> <83o93v83si.fsf@gnu.org> <83muje76wa.fsf@gnu.org> <83k1eh7rtj.fsf@gnu.org> Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="48090"; mail-complaints-to="usenet@blaine.gmane.org" Cc: rcopley@gmail.com, 35739@debbugs.gnu.org, npostavs@gmail.com To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu May 23 06:53:11 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 esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hTfj5-000CNQ-C2 for geb-bug-gnu-emacs@m.gmane.org; Thu, 23 May 2019 06:53:11 +0200 Original-Received: from localhost ([127.0.0.1]:57631 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hTfj3-0003HH-Pt for geb-bug-gnu-emacs@m.gmane.org; Thu, 23 May 2019 00:53:09 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:36881) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hTfiw-0003Gt-TQ for bug-gnu-emacs@gnu.org; Thu, 23 May 2019 00:53:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hTfiv-0007of-Su for bug-gnu-emacs@gnu.org; Thu, 23 May 2019 00:53:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58399) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hTfiv-0007oZ-PW for bug-gnu-emacs@gnu.org; Thu, 23 May 2019 00:53:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hTfiv-0003ua-LS for bug-gnu-emacs@gnu.org; Thu, 23 May 2019 00:53:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 23 May 2019 04:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35739 X-GNU-PR-Package: emacs Original-Received: via spool by 35739-submit@debbugs.gnu.org id=B35739.155858717215021 (code B ref 35739); Thu, 23 May 2019 04:53:01 +0000 Original-Received: (at 35739) by debbugs.gnu.org; 23 May 2019 04:52:52 +0000 Original-Received: from localhost ([127.0.0.1]:43710 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hTfim-0003uC-Bh for submit@debbugs.gnu.org; Thu, 23 May 2019 00:52:52 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:50691) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hTfik-0003tz-HQ for 35739@debbugs.gnu.org; Thu, 23 May 2019 00:52:50 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:53687) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hTfia-0007jA-Kg; Thu, 23 May 2019 00:52:42 -0400 Original-Received: from [176.228.60.248] (port=3830 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hTfiY-0003Qc-I6; Thu, 23 May 2019 00:52:39 -0400 In-reply-to: (message from Stefan Monnier on Thu, 23 May 2019 00:06:19 -0400) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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:159676 Archived-At: > From: Stefan Monnier > Cc: rcopley@gmail.com, 35739@debbugs.gnu.org, npostavs@gmail.com > Date: Thu, 23 May 2019 00:06:19 -0400 > > > Where is the decoding happening, then? According to what you write, > > URL should just save the files as is, and then decoding should happen > > when we access the resulting files after saving them. Is that what > > happens after the changes? > > That's right. > > > Sorry for the typo: I meant list-packages. Does that display come > > from the README files? > > It can come from various places, but the only case affected by my change > is when it comes from the remote archive in which case it's indeed the > *-readme.txt file that I do decode explicitly. > > > Other clients might need it in other ways. From what you explain, it > > sounds like package.el doesn't need to decode at all when it > > downloads, so it should disregard the 'charset' header and always > > treat the stuff it gets as a raw byte stream. Is that correct? > > That's right. Sounds good, thanks. > > If it is correct, then there's no need to make any changes in > > url*.el routines. > > There is, because the routine that extracts the "raw bytes" is url-insert > which (until my patch) also did the decoding according to the "charset" > specified in the HTTP headers returned by the server (if present). > IOW it didn't always return the raw bytes. Then how about an optional argument to disable 'charset' handling instead? That'd be backward-compatible. > Note that other clients will only be negatively affected by the change if: > - the HTTP server has returned a "charset" in its headers. > - they url-insert into a unibyte buffer. > - they need the text to be decoded. > The last two points should be mutually exclusive in sane situations, so > I think the change is pretty safe. Or to put it another way, I think > it's more likely to uncover or even fix a bug than to introduce one. I'd prefer a backward-compatible change, because that saves us from the need to be 100% right when estimating the collateral damage, something that we have failed in several cases in the past. Thanks.