Do not consider two versions with differing SHA256 to be the same
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
apt (Ubuntu) |
Fix Released
|
Undecided
|
Julian Andres Klode | ||
Jammy |
Fix Released
|
Undecided
|
Julian Andres Klode | ||
Lunar |
Fix Released
|
Undecided
|
Julian Andres Klode | ||
Mantic |
Fix Released
|
Undecided
|
Julian Andres Klode |
Bug Description
[Impact]
APT sometimes deduplicates two debs into the same version object even if they have different SHA256 field values, causing download to fail later if one the sources also defines SHA512 (or MD5 or SHA1).
This is a problem for example, if you rebuild in a PPA because PPAs do not have SHA512 enabled but the priamary archive does.
Repositories are not required to have SHA256, so this does nothing if we do not have SHA256 for both .deb.
[Test plan]
An automated test is included in apt's extensive autopkgtest regression test suite. Successful pass of autopkgtest is the goal.
[Where problems could occur]
In terms of regressions it seems unlikely, because we compare the SHA256 only if we previously would have considered them the same version to reject them if they differ.
But of course there could be the usual unsafe memory bugs.
In a future this will bite us when we migrated to SHA3 and want to drop SHA256, just like we cannot seem to drop MD5 now.
Changed in apt (Ubuntu Lunar): | |
status: | New → Triaged |
Changed in apt (Ubuntu Jammy): | |
status: | New → Triaged |
Changed in apt (Ubuntu Lunar): | |
status: | Triaged → In Progress |
Changed in apt (Ubuntu Jammy): | |
status: | Triaged → In Progress |
tags: | removed: foundations-todo |
Merge request: https:/ /salsa. debian. org/apt- team/apt/ -/merge_ requests/ 305/diffs