Apache Commons Codec tree identifier collision in GitIdentifiers
Apache Software Foundation Apache Commons Codec
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Apache Software Foundation Apache Commons Codec |
| No fix yet |
| Apache Software Foundation Apache Commons Codec |
| No fix yet |
Original description
The GitIdentifiers class in Apache Commons Codec did not reject NUL bytes in tree entry names. Because Git uses a NUL byte to mark the end of each entry name in a tree object, a crafted name could make one tree serialize to the same bytes as a different tree. Two different directory trees could then receive the same Git tree identifier or SWHID.