)]}'
{
  "commit": "0c2f0d27038f2aa98082d8af35c53b2ec7e9ad92",
  "tree": "2064f395a54ba9f5eb551d750bd5f265d1fdb369",
  "parents": [
    "2609043da00ea0db411c44179136b07bf210bf75"
  ],
  "author": {
    "name": "Brandon Williams",
    "email": "bmwill@google.com",
    "time": "Mon Oct 16 10:55:28 2017 -0700"
  },
  "committer": {
    "name": "Junio C Hamano",
    "email": "gitster@pobox.com",
    "time": "Tue Oct 17 10:51:29 2017 +0900"
  },
  "message": "connect: tell server that the client understands v1\n\nTeach the connection logic to tell a serve that it understands protocol\nv1.  This is done in 2 different ways for the builtin transports, both\nof which ultimately set \u0027GIT_PROTOCOL\u0027 to \u0027version\u003d1\u0027 on the server.\n\n1. git://\n   A normal request to git-daemon is structured as\n   \"command path/to/repo\\0host\u003d..\\0\" and due to a bug introduced in\n   49ba83fb6 (Add virtualization support to git-daemon, 2006-09-19) we\n   aren\u0027t able to place any extra arguments (separated by NULs) besides\n   the host otherwise the parsing of those arguments would enter an\n   infinite loop.  This bug was fixed in 73bb33a94 (daemon: Strictly\n   parse the \"extra arg\" part of the command, 2009-06-04) but a check\n   was put in place to disallow extra arguments so that new clients\n   wouldn\u0027t trigger this bug in older servers.\n\n   In order to get around this limitation git-daemon was taught to\n   recognize additional request arguments hidden behind a second\n   NUL byte.  Requests can then be structured like:\n   \"command path/to/repo\\0host\u003d..\\0\\0version\u003d1\\0key\u003dvalue\\0\".\n   git-daemon can then parse out the extra arguments and set\n   \u0027GIT_PROTOCOL\u0027 accordingly.\n\n   By placing these extra arguments behind a second NUL byte we can\n   skirt around both the infinite loop bug in 49ba83fb6 (Add\n   virtualization support to git-daemon, 2006-09-19) as well as the\n   explicit disallowing of extra arguments introduced in 73bb33a94\n   (daemon: Strictly parse the \"extra arg\" part of the command,\n   2009-06-04) because both of these versions of git-daemon check for a\n   single NUL byte after the host argument before terminating the\n   argument parsing.\n\n2. ssh://, file://\n   Set \u0027GIT_PROTOCOL\u0027 environment variable with the desired protocol\n   version.  With the file:// transport, \u0027GIT_PROTOCOL\u0027 can be set\n   explicitly in the locally running git-upload-pack or git-receive-pack\n   processes.  With the ssh:// transport and OpenSSH compliant ssh\n   programs, \u0027GIT_PROTOCOL\u0027 can be sent across ssh by using \u0027-o\n   SendEnv\u003dGIT_PROTOCOL\u0027 and having the server whitelist this\n   environment variable.\n\nSigned-off-by: Brandon Williams \u003cbmwill@google.com\u003e\nSigned-off-by: Junio C Hamano \u003cgitster@pobox.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "a5e708a618cd71b230437b5c172d8c78bfcfd3b1",
      "old_mode": 33188,
      "old_path": "connect.c",
      "new_id": "b8695a2fa28b5fd9eb9dc4b3e0291b481c57bd6a",
      "new_mode": 33188,
      "new_path": "connect.c"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "6551932da92667ab7fa1fbb37923f356eb331bbe",
      "new_mode": 33261,
      "new_path": "t/t5700-protocol-v1.sh"
    }
  ]
}
