Subject: bug#76159: closed (Re: bug#76159: [PATCH] Precision on Ange FTP parsing of .authinfo file)

From: [email-masked] (GNU bug Tracking System)
Date: Mon, 10 Feb 2025 15:45:02 +0000

Your bug report

#76159: [PATCH] Precision on Ange FTP parsing of .authinfo file

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
76159: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=76159
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#76159: [PATCH] Precision on Ange FTP parsing of .authinfo file
From: Michael Albinus <[email-masked]>
To: Manuel Giraud <[email-masked]>
Cc: [email-masked]
Date: Mon, 10 Feb 2025 16:44:20 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Manuel Giraud <[email-masked]> writes:

Hi Manuel,

> This misunderstanding leads me to read how Ange FTP parses netrc (or
> authinfo) entries.  But I'm not sure there is a need for a documentation
> fix then.

OK, let's be it as it is. I'm closing this bug.

Best regards, Michael.

Subject: [PATCH] Precision on Ange FTP parsing of .authinfo file
From: Manuel Giraud <[email-masked]>
To: [email-masked]
Cc: Michael Albinus <[email-masked]>
Date: Sun, 09 Feb 2025 16:36:48 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Tags: patch

Hi Michael,

I end up having to read the ange-ftp source code to understand this
issue.  So maybe it needs to be documented.  WDYT?

In GNU Emacs 31.0.50 (build 6, x86_64-unknown-openbsd7.6, X toolkit) of
 2025-02-09 built on computer
Repository revision: 35fa7126903a0ac6a28901d194f0753acf60928d
Repository branch: mgi/tramp-ange-docfix
Windowing system distributor 'The X.Org Foundation', version 11.0.12101015
System Description: OpenBSD computer 7.6 GENERIC.MP#534 amd64

Configured using:
 'configure CC=egcc CPPFLAGS=-I/usr/local/include
 LDFLAGS=-L/usr/local/lib MAKEINFO=gmakeinfo --prefix=/home/manuel/emacs
 --bindir=/home/manuel/bin --with-x-toolkit=lucid
 --with-toolkit-scroll-bars=no --without-cairo
 --without-compress-install'

>From b2dcfd3dcbdabb3539b240caf8ef4f6244d89c86 Mon Sep 17 00:00:00 2001
From: Manuel Giraud <[email-masked]>
Date: Sun, 9 Feb 2025 16:27:20 +0100
Subject: [PATCH] Precision on Ange FTP parsing of .authinfo file

* doc/misc/tramp.texi (Password handling): Document discrepancy
in Ange FTP parsing of .authinfo file.
---
 doc/misc/tramp.texi | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi
index 86ffba29744..7bab822a095 100644
--- a/doc/misc/tramp.texi
+++ b/doc/misc/tramp.texi
@@ -2223,6 +2223,17 @@ Password handling
 (customize-set-variable 'ange-ftp-netrc-filename "~/.authinfo.gpg")
 @end lisp
 
+If you do so, note that Ange FTP does not parse the @option{port} option
+in the @file{.authinfo} file.  So if you need to use different port, you
+should have an entry like this:
+
+@example
+machine @var{host}#@var{port} login @var{user} password secret
+@end example
+
+And then use it to open your remote files with
+@file{@trampfn{ftp,host#port,/path/to/file}}.
+
 In case you do not want to use an authentication file for
 @value{tramp} passwords, use connection-local variables
 @ifinfo
-- 
2.48.1

-- 
Manuel Giraud