From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Akib Azmain Turja via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs,gmane.emacs.erc.general Subject: bug#58985: 29.0.50; Have auth-source-pass behave more like other back ends Date: Mon, 14 Nov 2022 23:49:37 +0600 Message-ID: <87edu5toi6.fsf@disroot.org> References: <87wn8cb0ym.fsf@neverwas.me> <874jvdardn.fsf__3771.40490324877$1667692584$gmane$org@neverwas.me> <87pme09vis.fsf@gmx.de> <87a653z7dl.fsf@neverwas.me> <878rkjl1vd.fsf@disroot.org> <877d026uym.fsf@neverwas.me> <87tu35eehq.fsf@disroot.org> <87bkpcu74w.fsf@neverwas.me> <875yfkdwlm.fsf@disroot.org> <874jv3nwmc.fsf@disroot.org> <875yfiq3d8.fsf@neverwas.me> <87mt8uvxkp.fsf@disroot.org> <877czxlgd4.fsf@neverwas.me> Reply-To: Akib Azmain Turja Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13854"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Damien Cassou , =?UTF-8?Q?Bj=C3=B6rn?= Bidar , emacs-erc@gnu.org, Michael Albinus , 58985@debbugs.gnu.org To: "J.P." Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Nov 15 00:56:28 2022 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 1oujJT-0003On-6J for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 15 Nov 2022 00:56:27 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ouijd-0003uW-V7; Mon, 14 Nov 2022 18:19:26 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ouieU-0003YX-MJ for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2022 18:14:07 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oueBe-00019Y-84 for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2022 13:28:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oueBd-0001KS-S2 for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2022 13:28:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Akib Azmain Turja Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 14 Nov 2022 18:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58985 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 58985-submit@debbugs.gnu.org id=B58985.16684504695088 (code B ref 58985); Mon, 14 Nov 2022 18:28:01 +0000 Original-Received: (at 58985) by debbugs.gnu.org; 14 Nov 2022 18:27:49 +0000 Original-Received: from localhost ([127.0.0.1]:50858 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oueBQ-0001K0-Gn for submit@debbugs.gnu.org; Mon, 14 Nov 2022 13:27:48 -0500 Original-Received: from knopi.disroot.org ([178.21.23.139]:34572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oueBO-0001Jr-4U for 58985@debbugs.gnu.org; Mon, 14 Nov 2022 13:27:47 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id A20F84121E; Mon, 14 Nov 2022 19:27:44 +0100 (CET) X-Virus-Scanned: SPAM Filter at disroot.org Original-Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CeN0ERMqxdkB; Mon, 14 Nov 2022 19:27:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1668450463; bh=5HR2xGk1A2H+/uzbJdJSR9P5RvJ83OzBSRj5XRi+SFA=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=JfzTsuWl/Z+A6WI7A8MPpim2xHW4w5kiwD5AlvMQbkP/lkEF0f/+M6DI5v5/HkKg7 COuMcbEjCRcmmu43UPREgyUFsgfNnnU0yXEAhWO1NbLq6jCVxbmVi/X+dDAsVSGFhe kFzSCXkGdoGaYW5hAd3F5AolYQC0ZncxczZ+/1GKneepEp4BmabHyXNYJa4nu8u2b7 /yhKk3CCo6RoMXpuC7luzgGeoGhL84Pa+nFudf9NKMPphbmvoO0iRIK1N9gAaymSM2 vRT6Tvrrmhv+Aqh7GkOmLhTOjZIWPjNzhe1Buxq0ORFk+JGxLAF60SMbWNt1d/r/lX DjeZd9BVYN76Q== In-Reply-To: <877czxlgd4.fsf@neverwas.me> (J. P.'s message of "Mon, 14 Nov 2022 07:12:39 -0800") 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:247844 gmane.emacs.erc.general:1988 Archived-At: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable "J.P." writes: > Akib Azmain Turja writes: > >> "J.P." writes: >> >>> You mentioned previously some potentially surprising ambiguities >>> surrounding the trailing /user syntax. If any realistic scenarios >>> present themselves, perhaps we can try to improve the situation if it's >>> not too far out of scope (or just document the behavior, maybe in a unit >>> test). Thanks again. >> >> I think it's good enough to install on master. Then more people can >> test and report about it. >> >> However, observed some behavior of the new code, here are my findings: >> >> The new searching code seems to prefer "HOST/USER" over "USER@HOST". > > That's the effect, right. I think `directory-files-recursively' > basically determines the ordering in which the entries are considered. > >> I created the password store entry "foo.com/bar.org". Then I evaluated: >> (warning: manually typed with hands) >> >> (auth-source-search :host "bar.org") >> ;; =3D> nil >> >> (auth-source-search :host "foo.com") >> ;; =3D> ((:host "foo.com" :user "bar.org" :secret ...)) >> >> I created another entry "bar.org@foo.com". But it returns the password >> in "foo.com/bar.org". >> >> I deleted "foo.com/bar.org", now it return the password of >> "bar.org@foo.com". >> >> I created "foo.com/bar.org" again, and "foo.com/bar.org" is preferred >> again. >> >> I suggest to prefer the "@" syntax over "/user" syntax. > > I have tried tweaking things in that direction. But as far as > deprecating the /user form officially: that seems more like a group > decision. And then there's the question of how to express such a policy. > Should we emit a warning? At the very least, it would need to be > documented somewhere. No, I didn't say to deprecate that syntax, the syntax makes much sense. I'm suggesting to return "USER@HOST" if both "USER@HOST" and "HOST/USER" are present, because the former makes more sense. > > Anyway, this is useful analysis. Thanks again for all your help. > > > > When are you going to install this? It's definitely an improvement over the one in master, and doesn't have any problems to block it. Installing it will also expose it to more users to the change, so this will get even more testing. =2D-=20 Akib Azmain Turja, GPG key: 70018CE5819F17A3BBA666AFE74F0EFA922AE7F5 Fediverse: akib@hostux.social Codeberg: akib emailselfdefense.fsf.org | "Nothing can be secure without encryption." --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEyVTKmrtL6kNBe3FRVTX89U2IYWsFAmNyf7EACgkQVTX89U2I YWsJzRAApOKINyFhf1byr1qIOueTNcA5bBcHoJFVFQLmlJbXdpYOwHWwvcD36fsI X/tbft716CY6x262IXRmC0Yp2V7uiGsPVm+uy9eMTBVeLAYxbpcXY46StKzewORU PcSQLi4L8w9AqTcdoVSf6t50eYipDpY6zP9YgwdvdxKoiW4I2HvlgLtwxwsWLXPU TxZOjRAu9YUHPpf924Ckk/fpfy5phFgcl4ZLJLB9ksX0l8YJnL8NI5gsRqg98HV3 LwUPObuZpM7cwXxXaVa97Gvc3MfJhSZNFXxB4NzxyzGZELvizNssAFAlzrgeKEtj Dk1RfI5bqJKMiBkYoqiqdfNqtCgkf+jb0n29ITPvjGveJ1NP168I1RCtuMGO2FKa XJ0S7FBleACnwDrOPPQVdMwQH5livc9pdRYo20gKCc6WF4ZLSxwu0a4leAfDTFwv xMP4OIkg+WV4J1mrxDLpgnHdc1jl2Gx5mOD8m8oTWXuWjp433UNv0QeaEK9bmSrI BSbmmpg8c31wbl7J9bBp2KxYlKznz9Oej9bv0LQlDtRujSLEo1NK2oBTJLjzNKPG tvSIqUw2mBFixHCenh6NqrKupUp/61o10B5zNdM3tgLUtNTUbnzCh/s8hUGoSz1S 3WVKJ63zEEzLGT13hlw3FHt10wqJ3qeOWm/9MSLKZGyIRXwE/T4= =D88P -----END PGP SIGNATURE----- --=-=-=--