git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 0/1] Fix netrc usage with WebDAV-based HTTP protocol

From
brian m. carlson <sandals@crustytoothpaste.net>
Date
Feb 23, 2025, 01:53 UTC
Message-ID
<20250223015331.588161-1-sandals@crustytoothpaste.net>
In-Reply-To
<Z7UPYY24uk7lLzeP@tapette.crustytoothpaste.net>

For a long time, we've enabled the automatic usage of netrc if the user doesn't provide any credentials. Unfortunately, in 2.46, this broke for the WebDAV-based HTTP protocol, which this series fixes.

In looking at this issue, I discovered that we have (before this series) zero tests for the netrc functionality and zero documentation for it, which obviously is suboptimal. In this series, I am adding one test, which is for this particular bug.

However, I think we need to either decide that we're going to support this as a fully-fledged feature and add documentation and sufficient tests, or remove it, since it's not reasonable to have undocumented, untested features that people rely on. Our HTTP code is quite subtle and complex and we can't expect future developers not to break things in this state[0]. I will note, as an argument in favour of removal, that we have git-credential-netrc helper in contrib that users can enable if they want to retain this functionality, and we could even ship it by default without much difficulty. For those reasons, I am not planning to add more tests and documentation here, but of course I welcome interested parties to do so.

[0] Personally, I had some vague knowledge this feature existed and I feel like I'm reasonably familiar with the HTTP code, and I still accidentally introduced a bug, so that doesn't bode well for contributors who are less familiar with it.

brian m. carlson (1):
  http: allow using netrc for WebDAV-based HTTP protocol
 http.c                      |  3 +--
 t/t5540-http-push-webdav.sh | 10 ++++++++++
 2 files changed, 11 insertions(+), 2 deletions(-)
Previous: brian m. carlsonNext: brian m. carlson
Message 3 of 7 in “[Bug] git-http-push authentication fails using netrc-file since v2.46”
  1. Peter GeorgFeb 18, 2025
  2. brian m. carlsonFeb 18, 2025
  3. 0/1 Fix netrc usage with WebDAV-based HTTP protocolbrian m. carlson, Feb 23, 2025
  4. 1/1 http: allow using netrc for WebDAV-based HTTP protocolbrian m. carlson, Feb 23, 2025
  5. Junio C HamanoFeb 24, 2025
  6. brian m. carlsonFeb 24, 2025
  7. Peter GeorgFeb 26, 2025

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.