From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Michael Albinus via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#70301: 30.0.50; secrets-create-item mangles cyrillic passwords Date: Wed, 10 Apr 2024 18:10:00 +0200 Message-ID: <87bk6hryg7.fsf@gmx.de> References: <1712650236526.1662743497.3911072838@cdots.bg> <86o7aix3wq.fsf@gnu.org> <87jzl5s06c.fsf@gmx.de> <86o7ahusrg.fsf@gnu.org> Reply-To: Michael Albinus Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17658"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 70301@debbugs.gnu.org, k.ninev@cdots.bg To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Apr 10 18:12:22 2024 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 1ruaYg-0004OZ-JS for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Apr 2024 18:12:22 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ruaXe-0006hU-QY; Wed, 10 Apr 2024 12:11:20 -0400 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 1ruaXI-0006LE-N3 for bug-gnu-emacs@gnu.org; Wed, 10 Apr 2024 12:10:57 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ruaXI-0003ha-3w for bug-gnu-emacs@gnu.org; Wed, 10 Apr 2024 12:10:56 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ruaXQ-0001cl-7Z for bug-gnu-emacs@gnu.org; Wed, 10 Apr 2024 12:11:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 10 Apr 2024 16:11:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70301 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 70301-submit@debbugs.gnu.org id=B70301.17127654285858 (code B ref 70301); Wed, 10 Apr 2024 16:11:03 +0000 Original-Received: (at 70301) by debbugs.gnu.org; 10 Apr 2024 16:10:28 +0000 Original-Received: from localhost ([127.0.0.1]:54235 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ruaWp-0001WP-Ih for submit@debbugs.gnu.org; Wed, 10 Apr 2024 12:10:27 -0400 Original-Received: from mout.gmx.net ([212.227.17.22]:50217) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ruaWm-0001Vv-UD for 70301@debbugs.gnu.org; Wed, 10 Apr 2024 12:10:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.de; s=s31663417; t=1712765402; x=1713370202; i=michael.albinus@gmx.de; bh=/q4Ia6QX4HLyKBPggIGNUe3oZSi4Xl7x9pXy5pmKv0o=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References: Date; b=ZzN3huCFECH4EWdGWaBFC5FCzkvk5MgGOveuy7iLDGzLyioH0ONNPo/n/nFjQF0d /UpZxxst0t89WIa+GdvpW2oqgOuPil+GTe+1u3w5m7hfYOIiCNN+1gHz6ICieGwjA bbk00TK/6KyawNRwA00zFDt3ylHrrUCfiu8fBUrEYeQPy1fY381dgfJkM7LH4k0HX Z5f5NL1k+LwZaHHr7+tCPZ8r10YVq6LpJe++p6lJ//g+k5zbk7Io9lfwFy2XpAImy uHLDXJKBBVQO2CFANxy3kMIo41CXGYZQLjJIhyZI+ucnGRdivs4jXDxkSbmlW+yjv 0ZAs6JtjNXFakpmmLA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from gandalf.gmx.de ([185.89.39.16]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MF3HU-1s17y53oIi-00FPkr; Wed, 10 Apr 2024 18:10:01 +0200 In-Reply-To: <86o7ahusrg.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 10 Apr 2024 18:44:35 +0300") X-Provags-ID: V03:K1:1DOSdlMNW3qCDhZC8fJC143XGiPFlBOCfJ7m3lakto+Pn9hKekj OhF7y9czNPW7rEtqKRBN2K5NHa0P8RCZBflAH4JPclZ3LokyjLYPDi2RR67xurqVgQsUK7U w4DqHEGc6TFrFjMKMGNE/qz1Qhchc37PcWTJjAs0B+GQY+iVZ8SPP/dWc4ksUjp6rA2EZ97 mRYs7q+YuMvfc8/IdgIPg== UI-OutboundReport: notjunk:1;M01:P0:06O2wdFNSyU=;WHHrV4Mt1SwwP95Opxf5PssytxQ Rb3MznZ1X8Lm+3TsQ+Fjg7pjSneS2cAEVOczH9AUeckV1Na+yVzbCJrxr2mCnXiTp05UN9l73 x4CmTvUze5NRBoT4vq32+j89ShFEc7qBB1flp3RZ+MAPU3fHu6TWnmqTIa/LdyyuoJmoB9I2I Wtwo2/InHlc45H/RKL2RkDTCjX5Vs12zM72biyQ/ZbrqoZBJnywd81oETgtViwImc/58Vn03l rjvgNMokzNUPu/yZZ43arBh+0XDPH28X/rlokV3Zx5Wu4v3DyghsNv2zuOYEIqHZ7MoGuOfBq vlvaFnW6rPZBUib96trXl608+Sj9YSKKEah/+eq7D6PcomQNDwsGirrIFU5eHMfU4wsDPccvT H0daxFuaFzHKR/XcPIEU3+6x8A/2Y04b6eq+m1EtJlNyAJ7nhCCJG3r2dAhlxRWy+Tb3ZdUtT 3MCjfe7je5qh11c/fhBhwIgVG1j+5qCVzB7VOlnJQALe9uMyM4/z1wDDn1646tz3VQ+56hFYF IAf+tVm9hDYsQqesM5AFMhy4UezHDlMLwzN3t2iLgg04sMFCgOB2f5j1tIZhZkmwC1xLoKtcE DbRWaIR8BFaHFi31Qkvzb+3kbtHxJtO4dTIE/yZ9oj7nprFP9FOucSFceBgqcinalr/m2pHep Pf/7zMXhLDjnz/0pqg1kpciLo5NDaqX2FsiNj/RqWbzReMF2whWZRuHMEIfCHBDtJrHXMQ1ry SSjUIlrouDiOsOVWvENcgXfqFarzyh5SsIwWhwXcXV3HvqsAff3wrBO2LyJ8CDWF1YScXgKp 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:283055 Archived-At: Eli Zaretskii writes: Hi Eli, >> Thanks for the patch. However, I believe we shouldn't fix it in >> secrets.el, but in dbus.el. > > Then we ought to update the doc string of dbus-string-to-byte-array, > which currently says the argument should be a UTF-8 encoded string. Yep. >> > Michael, I think we have a similar problem in >> > dbus-byte-array-to-string: when MULTIBYTE is non-nil, the function >> > should call decode-coding-string on the unibyte string it produces >> > instead of converting each byte to multibyte. Because the bytes in >> > the argument BYTE-ARRAY are not characters, they are raw bytes of the >> > UTF-8 sequence, so calling 'string' on them is not TRT. >> >> Yes. The following patch works for me. WDYT? > > If you are okay with changing the behavior of > dbus-byte-array-to-string in backward-incompatible ways, I don't mind. > But maybe this should be called out in NEWS. I'm aware of this incompatibility. Well, I've played several hours today with this. Since we have no information from D-Bus about the underlying byte array, we must assume a given context. A sequence of raw 8-bit bytes, unibyte, representing an UTF-8 encoded string seems to be aapropriate. If people want another conversion for a D-Bus byte array, it is still possible. But they shouldn't use dbus-byte-array-to-string and dbus-string-to-byte-array then. I'll puzzle everything together by tomorrow. Best regards, <