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

Re: [PATCH v2 1/3] connect.c: allow ssh://user@[2001:db8::1]/repo.git

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 22, 2015, 19:37 UTC
Message-ID
<xmqqwq39vit7.fsf@gitster.dls.corp.google.com>
In-Reply-To
<54E8A9D0.30108@web.de>
Torsten Bögershausen <tboegi@web.de> writes:
> The ssh:// syntax was added in 2386d65822c91, it accepted
> ssh://user@2001:db8::1/repo.git, which is now legacy.

Please do not quote just a raw object name, but annotate it so that we can more easily tell what the change was about and how far back in the history it was done without having to run "git show -s" on it.

Show 6 quoted lines
> Over the years the parser was improved to support [] and port numbers,
> but the combination of ssh://user@[2001:db8::1]:222/repo.git did
> never work.
>
> The only only way to use a user name, a literall IPV6 address and a port
> number was ssh://[user@2001:db8::1]:222/repo.git
Let me double check if I understand Brian and the above correctly:
 * The original 2386d658 (Add first cut at "git protocol" connect
   logic., 2005-07-13) did not even care that the IPv6 syntax was
   valid or not, and worse yet, it did not correctly handle literal
   addresses in brackets;
 * Later we started supporting literal addresses in brackets, but
   "user@[literal]:port" form did not work.  Instead, a bug in the
   parser allowed "[user@literal]:port" (which is not a valid way to
   spell such things) to work as if it were "user@[literal]:port",
   which is what users would expect.
 * This three-patch series is an attempt to allow that kosher
   syntax, "user@[literal]:port", to work.
 * It does not terribly matter if we broke the invalid syntax
   "user@literal:port" without brackets, and it might even be
   beneficial if we declared such addresses invalid and deprecated
   for the sake of uniformity with other protocols.  Making that
   judgement, however, is outside the scope of this series.
   "user@literal:port" will continue to behave as it did before.
Is that what is going on?
If that is the case, I think it addresses Brian's concern well.
Thanks.
(I haven't checked the patch text itself yet, though).
Previous: Torsten BögershausenNext: brian m. carlson
Message 3 of 4 in “connect.c: allow ssh://user@[2001:db8::1]/repo.git”
  1. 1/3 connect.c: allow ssh://user@[2001:db8::1]/repo.gitTorsten Bögershausen, Feb 21, 2015
  2. Torsten BögershausenFeb 22, 2015
  3. Junio C HamanoFeb 22, 2015
  4. brian m. carlsonFeb 23, 2015

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.