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

Re: [PATCH 1/7] pack-protocol.txt: Add warning about protocol inaccuracies

From
Dave Borowitz <dborowitz@google.com>
Date
Jul 1, 2015, 19:56 UTC
Message-ID
<CAD0k6qTtvfKgJX1LyaO3i6as1Av9T=cZrwput-1HnTJuek5HoA@mail.gmail.com>
In-Reply-To
<20150701193949.GC4865@google.com>
On Wed, Jul 1, 2015 at 12:39 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 31 quoted lines
> Hi,
>
> Dave Borowitz wrote:
>
>> --- a/Documentation/technical/pack-protocol.txt
>> +++ b/Documentation/technical/pack-protocol.txt
>> @@ -14,6 +14,17 @@ data.  The protocol functions to have a server tell a client what is
>>  currently on the server, then for the two to negotiate the smallest amount
>>  of data to send in order to fully update one or the other.
>>
>> +Notes to Implementors
>> +---------------------
>> +
>> +WARNING: This document is a work in progress. Some of the protocol
>> +specifications below may be incomplete or inaccurate. When in doubt,
>> +refer to the C code.
>
> If we include this warning, can it also say to contact
> git@vger.kernel.org for inaccuracies?
>
> Otherwise it is easy to misread as "Some of this document may be
> inaccurate, and we're working on fixing that.  Don't bug me --- I
> already know about the problems --- just be patient!"
>
> I would rather that it would say something like
>
>         Caveat
>         ------
>         This document contains some inaccuracies.  Do not forget to also
>         check against the C code, and please contact git@vger.kernel.org
>         if you run into any unclear or inaccurate passages in this spec.
Agreed with your rationale and suggested wording, thanks.
Show 13 quoted lines
>> +
>> +One particular example is that many of the LFs referenced in the
>> +specifications are optional, but may (yet) not be marked as such. If not
>> +explicitly marked one way or the other, double-check with the C code.
>
> The 'Reference Discovery' section says:
>
>         Server SHOULD terminate each non-flush line using LF ("\n") terminator;
>         client MUST NOT complain if there is no terminator.
>
> Unfortunately that's not explained in a section with broader scope.
>
> Isn't that actually the rule everywhere except for in push certs?

It's certainly the rule in more places. I personally have partially audited send-pack.c, but there are many places that are not yet audited. I don't feel comfortable making a broader claim without having done so, and I do not have the time to do so at the moment.

> The documentation will be easier to use if it says so instead of
> asking implementers to check the source of all implementations
> (since interoperability with only one isn't enough).

Unfortunately, the trust I have in this document at this point is less than zero. A handful of spot fixes, while useful, does not serve as any sort of assurance that we've gotten all or even most of the problems. Until such time as this document is actually reliable, implementors must check the source of all implementations if they want to be accurate. That sucks for implementors (believe me, I know), but it's the truth.

> Thanks,
> Jonathan
Previous: Junio C HamanoNext: Dave Borowitz
Message 5 of 50 in “Clarify signed push protocol documentation”
  1. 0/7 Clarify signed push protocol documentationDave Borowitz, Jul 1, 2015
  2. 1/7 pack-protocol.txt: Add warning about protocol inaccuraciesDave Borowitz, Jul 1, 2015
  3. Jonathan NiederJul 1, 2015
  4. Junio C HamanoJul 1, 2015
  5. Dave BorowitzJul 1, 2015
  6. 2/7 pack-protocol.txt: Mark LF in command-list as optionalDave Borowitz, Jul 1, 2015
  7. Stefan BellerJul 1, 2015
  8. Dave BorowitzJul 1, 2015
  9. 3/7 pack-protocol.txt: Mark all LFs in push-cert as requiredDave Borowitz, Jul 1, 2015
  10. Junio C HamanoJul 1, 2015
  11. Dave BorowitzJul 1, 2015
  12. Junio C HamanoJul 1, 2015
  13. Dave BorowitzJul 6, 2015
  14. Dave BorowitzJul 6, 2015
  15. Dave BorowitzJul 6, 2015
  16. Dave BorowitzJul 6, 2015
  17. Dave BorowitzJul 6, 2015
  18. Junio C HamanoJul 6, 2015
  19. Shawn PearceJul 6, 2015
  20. Junio C HamanoJul 6, 2015
  21. Junio C HamanoJul 6, 2015
  22. Dave BorowitzJul 6, 2015
  23. Junio C HamanoJul 6, 2015
  24. Dave BorowitzJul 6, 2015
  25. Dave BorowitzJul 6, 2015
  26. Junio C HamanoJul 6, 2015
  27. Dave BorowitzJul 6, 2015
  28. Junio C HamanoJul 6, 2015
  29. Dave BorowitzJul 6, 2015
  30. Junio C HamanoJul 6, 2015
  31. Junio C HamanoJul 6, 2015
  32. Dave BorowitzJul 6, 2015
  33. Junio C HamanoJul 6, 2015
  34. Junio C HamanoJul 1, 2015
  35. Junio C HamanoJul 1, 2015
  36. Jeff KingJul 2, 2015
  37. Junio C HamanoJul 3, 2015
  38. Jeff KingJul 3, 2015
  39. Shawn PearceJul 3, 2015
  40. Jeff KingJul 3, 2015
  41. 4/7 pack-protocol.txt: Elaborate on pusher identityDave Borowitz, Jul 1, 2015
  42. Junio C HamanoJul 1, 2015
  43. 5/7 pack-protocol.txt: Be more precise about pusher-key relationshipDave Borowitz, Jul 1, 2015
  44. 6/7 pack-protocol.txt: Mark pushee field as optionalDave Borowitz, Jul 1, 2015
  45. Junio C HamanoJul 1, 2015
  46. Dave BorowitzJul 1, 2015
  47. Junio C HamanoJul 1, 2015
  48. Junio C HamanoJul 1, 2015
  49. Dave BorowitzJul 1, 2015
  50. 7/7 send-pack.c: Die if the nonce is emptyDave Borowitz, Jul 1, 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.