Salvatore Bonaccorso pushed to branch master at Debian Security Tracker / security-tracker
Commits: d2132454 by Salvatore Bonaccorso at 2024-05-15T17:12:04+02:00 tracker_service: Simplify DSA URL excluding date Now that DSA pages on https://www.debian.org/security redirect to the DSA announce in the mailinglist archive there is as well support to redirect the respective DSA without needing the year. Both https://www.debian.org/security/${year}/${dsa} and https://www.debian.org/security/${dsa} get redirected to the DSA announce. So we can simplify the url building to just replace the correct DSA identifier. Link: https://lists.debian.org/debian-security/2024/01/msg00001.html Signed-off-by: Salvatore Bonaccorso <car...@debian.org> - - - - - cb7c4988 by Salvatore Bonaccorso at 2024-05-15T17:20:55+02:00 tracker_service: Simplify DLA URL excluding date Now that DLA pages on https://www.debian.org/lts/security redirect to the DLA announce in the mailinglist archive there is as well support to redirect the respective DLA without needing the year. Both https://www.debian.org/lts/security/${year}/${dsa} and https://www.debian.org/lts/security/${dsa} get redirected to the DLA announce. So we can simplify the url building to just replace the correct DLA identifier. Link: https://lists.debian.org/debian-security/2024/01/msg00001.html Signed-off-by: Salvatore Bonaccorso <car...@debian.org> - - - - - 73aa615f by Salvatore Bonaccorso at 2024-05-15T15:31:33+00:00 Merge branch 'simplify-dsa-source-references' into 'master' Draft: Simplify dsa source references See merge request security-tracker-team/security-tracker!158 - - - - - 1 changed file: - bin/tracker_service.py Changes: ===================================== bin/tracker_service.py ===================================== @@ -1556,12 +1556,7 @@ Debian bug number.'''), link = "dsa-%d" % int(number) else: link = dsa.lower() - # We must determine the year because there is no generic URL. - for (date,) in self.db.cursor().execute( - "SELECT release_date FROM bugs WHERE name = ?", (dsa,)): - (y, m, d) = date.split('-') - return url.absolute("https://www.debian.org/security/%d/%s" - % (int(y), link)) + return url.absolute("https://www.debian.org/security/%s" % link) return None def url_dla(self, url, dla, re_dla=re.compile(r'^DLA-(\d+)(-\d+)?$')): @@ -1572,12 +1567,8 @@ Debian bug number.'''), link = "dla-%d" % int(number) else: link = dla.lower() - # We must determine the year because there is no generic URL. - for (date,) in self.db.cursor().execute( - "SELECT release_date FROM bugs WHERE name = ?", (dla,)): - (y, m, d) = date.split('-') - return url.absolute("https://www.debian.org/lts/security/%d/%s" - % (int(y), link)) + return url.absolute("https://www.debian.org/lts/security/%s" + % link) return None def url_debian_bug(self, url, debian): View it on GitLab: https://salsa.debian.org/security-tracker-team/security-tracker/-/compare/2af90a2aea68ad81cb62f2162b67e2c6153eb9f5...73aa615fe7cb30efb792a17c0f8663184e52773a -- View it on GitLab: https://salsa.debian.org/security-tracker-team/security-tracker/-/compare/2af90a2aea68ad81cb62f2162b67e2c6153eb9f5...73aa615fe7cb30efb792a17c0f8663184e52773a You're receiving this email because of your account on salsa.debian.org.
_______________________________________________ debian-security-tracker-commits mailing list debian-security-tracker-commits@alioth-lists.debian.net https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-security-tracker-commits