)]}'
{
  "commit": "e857d97defa5ce47aed9f85c871bc68d082c2f95",
  "tree": "b5c14c7067113f95fa317445bae75b12d94d518a",
  "parents": [
    "fc8cd4e1b4d53f6cde6eced21d60f4dc6ad60f73"
  ],
  "author": {
    "name": "David Ostrovsky",
    "email": "david@ostrovsky.org",
    "time": "Thu Oct 01 09:26:13 2026 +0200"
  },
  "committer": {
    "name": "Matthias Sohn",
    "email": "matthias.sohn@sap.com",
    "time": "Wed Nov 04 14:00:58 2026 +0100"
  },
  "message": "Validate expanded fetch destinations against ref name rules\n\nOn fetch, a wildcard refspec copies the matched part of a remote-\nadvertised ref name verbatim into the local destination. JGit did not\nvalidate that destination, so a hostile remote could advertise a name\nwith path-traversal components (for example\nrefs/tags/../../../../ESCAPED) pointing at a reachable object. With the\nfile ref backend the loose-ref write builds a path from the name\n(RefDirectory.fileFor), so the destination escaped the repository and\nwrote a ref file outside it.\n\nDrop an invalid expanded destination in FetchProcess.want(), before it\nbecomes a ref update, an object request, or a FETCH_HEAD entry, and log\na warning so the drop is visible. A valid destination must live under\nrefs/ and satisfy isValidRefName(). This mirrors native git\u0027s\nget_fetch_map(), which drops a mapping whose local name fails\ncheck_refname_format() (\"Ignoring funny ref ... locally\"), and matches\nthe validation JGit already applies on the push/receive path.\n\nAdd a file-backed regression test, exercised over protocol v0 and v2,\nthat advertises a traversal ref name and verifies the fetch writes no\nfile outside the client repository and no invalid name into packed-refs,\nand that a funny ref advertised next to valid refs is dropped while the\nvalid refs are still fetched.\n\nBug: https://gitlab.eclipse.org/security/vulnerability-reports/-/work_items/775\nChange-Id: If44f82ed926d17b7dc2d754bb30acfd80733639a\n",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "1d7bdab35a30642c84d5bf83575eb995409c8b49",
      "new_mode": 33188,
      "new_path": "org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/FetchMaliciousRefNameTest.java"
    },
    {
      "type": "modify",
      "old_id": "640a6294ed3db775c78bb55fea078d8b33bcb398",
      "old_mode": 33188,
      "old_path": "org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties",
      "new_id": "2c30292504b073498fbfd95e9b5589b0dd9a19de",
      "new_mode": 33188,
      "new_path": "org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties"
    },
    {
      "type": "modify",
      "old_id": "5bab3537482cb82e9f0d8abb830dd1613eec2dd9",
      "old_mode": 33188,
      "old_path": "org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java",
      "new_id": "307d176d17df5c4ad9f730c1771429efd5d8e2ac",
      "new_mode": 33188,
      "new_path": "org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java"
    },
    {
      "type": "modify",
      "old_id": "e4304426f03d30405cab4634f95d36f0189c111e",
      "old_mode": 33188,
      "old_path": "org.eclipse.jgit/src/org/eclipse/jgit/transport/FetchProcess.java",
      "new_id": "83a8506d6aeb365fbe2a34094c1ea5fe39e70601",
      "new_mode": 33188,
      "new_path": "org.eclipse.jgit/src/org/eclipse/jgit/transport/FetchProcess.java"
    }
  ]
}
