From bbadbd77953236ce7f292c896c0c3c8306e78a9a Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sat, 21 Jun 2025 23:34:52 +0200 Subject: [PATCH] docs: mention that the netrc file works without port numbers Closes #17698 --- docs/cmdline-opts/netrc.md | 3 +++ docs/libcurl/opts/CURLOPT_NETRC.md | 3 +++ 2 files changed, 6 insertions(+) diff --git a/docs/cmdline-opts/netrc.md b/docs/cmdline-opts/netrc.md index 3e9fcb1963..261dc196d6 100644 --- a/docs/cmdline-opts/netrc.md +++ b/docs/cmdline-opts/netrc.md @@ -25,6 +25,9 @@ file format. curl does not complain if that file does not have the right permissions (it should be neither world- nor group-readable). The environment variable "HOME" is used to find the home directory. +The netrc file provides credentials for a hostname independent of which +protocol and port number that are used. + On Windows two filenames in the home directory are checked: *.netrc* and *_netrc*, preferring the former. Older versions on Windows checked for *_netrc* only. diff --git a/docs/libcurl/opts/CURLOPT_NETRC.md b/docs/libcurl/opts/CURLOPT_NETRC.md index 019d6ffaa1..fa41236873 100644 --- a/docs/libcurl/opts/CURLOPT_NETRC.md +++ b/docs/libcurl/opts/CURLOPT_NETRC.md @@ -46,6 +46,9 @@ the options controlled by this parameter. Only machine name, username and password are taken into account (init macros and similar things are not supported). +The netrc file provides credentials for a hostname independent of which +protocol and port number that are used. + libcurl does not verify that the file has the correct properties set (as the standard Unix ftp client does). It should only be readable by user. -- 2.47.2