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

Re: Git-aware HTTP transport

From
Shawn O. Pearce <spearce@spearce.org>
Date
Aug 28, 2008, 17:43 UTC
Message-ID
<20080828174334.GF21072@spearce.org>
In-Reply-To
<alpine.DEB.1.10.0808281033070.2713@asgard.lang.hm>
david@lang.hm wrote:
Show 11 quoted lines
> On Thu, 28 Aug 2008, Shawn O. Pearce wrote:
>> david@lang.hm wrote:
>>> On Thu, 28 Aug 2008, Shawn O. Pearce wrote:
>>>>> "Shawn O. Pearce" <spearce@spearce.org> writes:
>>>>
>>>> Yes, I really did mean for this part of the protocol to be in binary.
>>>
>>> except that HTTP cannot transport binary data, if you feed it binary data
>>> it then encodes it into 7-bit safe forms for transport.
>>
>> So then how does it transport a GIF file to my browser?  uuencoded?
...
> I could be wrong, but I'm pretty sure I'm not. to test this yourself find 
> a webserver with an image file and retrieve it via telnet (telnet 
> hostname 80<enter>GET /path/to/file HTTP/1.0<enter><enter>) and what will 
> come back will be text.
  $ telnet www.google.com 80
  Trying 74.125.19.104...
  Connected to www.google.com (74.125.19.104).
  Escape character is '^]'.
  GET /intl/en_ALL/images/logo.gif HTTP/1.0
  
  HTTP/1.0 200 OK
  Content-Type: image/gif
  Last-Modified: Wed, 07 Jun 2006 19:38:24 GMT
  Expires: Sun, 17 Jan 2038 19:14:07 GMT
  Cache-Control: public
  Date: Thu, 28 Aug 2008 17:40:44 GMT
  Server: gws
  Content-Length: 8558
  X-Google-Backends: /bns/pq/borg/pq/bns/gws-prod/staticweb.staticfrontend.gws/16:9836,dauf30:80
  X-Google-Service: static
  X-Google-GFE-Request-Trace: dauf30:80,/bns/pq/borg/pq/bns/gws-prod/staticweb.staticfrontend.gws/16:9836,dauf30:80
  Connection: Close
  
  GIF89a	n���������������έ	���E�I�4�<���������ƾ����M������������セ�����$c!Y�����QΜ�������e֮c��1e�J}<�������s�����9q�k

Very funny. It trashed my tty. Even reset won't restore the settings. Anyway.

I chose the Google logo on the Google homepage because I know we try really hard to conform to standards, so we can have the biggest possible user base. Micro$oft or Yahoo! probably would have come out the same way. Or some image on kernel.org.

Anyway, I didn't send any browser data, so the server had to assume the dumbest f'ing browser on the planet, and I got back binary data.

-- 
Shawn.
Previous: Daniel StenbergNext: H. Peter Anvin
Message 29 of 57 in “Git-aware HTTP transport”
  1. Shawn O. PearceAug 26, 2008
  2. H. Peter AnvinAug 26, 2008
  3. Shawn O. PearceAug 26, 2008
  4. david@lang.hmAug 26, 2008
  5. H. Peter AnvinAug 26, 2008
  6. david@lang.hmAug 26, 2008
  7. H. Peter AnvinAug 26, 2008
  8. Imran M YousufAug 26, 2008
  9. Nicolas PitreAug 26, 2008
  10. Shawn O. PearceAug 26, 2008
  11. H. Peter AnvinAug 26, 2008
  12. Shawn O. PearceAug 26, 2008
  13. Shawn O. PearceAug 26, 2008
  14. H. Peter AnvinAug 26, 2008
  15. Shawn O. PearceAug 26, 2008
  16. H. Peter AnvinAug 26, 2008
  17. Imran M YousufAug 27, 2008
  18. Shawn O. PearceAug 28, 2008
  19. H. Peter AnvinAug 28, 2008
  20. Shawn O. PearceAug 28, 2008
  21. H. Peter AnvinAug 28, 2008
  22. Imran M YousufAug 28, 2008
  23. Junio C HamanoAug 28, 2008
  24. Shawn O. PearceAug 28, 2008
  25. david@lang.hmAug 28, 2008
  26. Shawn O. PearceAug 28, 2008
  27. david@lang.hmAug 28, 2008
  28. Daniel StenbergAug 28, 2008
  29. Shawn O. PearceAug 28, 2008
  30. H. Peter AnvinAug 28, 2008
  31. Mike HommeyAug 28, 2008
  32. H. Peter AnvinAug 28, 2008
  33. david@lang.hmAug 28, 2008
  34. H. Peter AnvinAug 28, 2008
  35. david@lang.hmAug 28, 2008
  36. Junio C HamanoAug 29, 2008
  37. H. Peter AnvinAug 29, 2008
  38. Junio C HamanoAug 29, 2008
  39. Shawn O. PearceAug 29, 2008
  40. Nicolas PitreAug 29, 2008
  41. TarmiganSep 1, 2008
  42. TarmiganSep 1, 2008
  43. Shawn O. PearceSep 2, 2008
  44. H. Peter AnvinSep 2, 2008
  45. Shawn O. PearceSep 2, 2008
  46. TarmiganSep 2, 2008
  47. H. Peter AnvinAug 28, 2008
  48. Shawn O. PearceAug 28, 2008
  49. H. Peter AnvinAug 28, 2008
  50. Shawn O. PearceAug 28, 2008
  51. H. Peter AnvinAug 28, 2008
  52. Shawn O. PearceAug 28, 2008
  53. Nicolas PitreAug 28, 2008
  54. H. Peter AnvinAug 28, 2008
  55. H. Peter AnvinFeb 13, 2013
  56. Scott ChaconFeb 13, 2013
  57. Junio C HamanoFeb 13, 2013

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.