diff options
author | Emilio Pozuelo Monfort <pochu@debian.org> | 2018-12-04 16:22:01 +0100 |
---|---|---|
committer | Emilio Pozuelo Monfort <pochu@debian.org> | 2018-12-04 16:22:01 +0100 |
commit | 41482f862bcce63f22dc473a59d7600e63a1531d (patch) | |
tree | 09d9dd4bb793a868e9d3e23ae6a4d13a5a4f44ed /lib | |
parent | a7b27496409d51f845e99e180e2b769e47aa5ffb (diff) |
CVEExtendFile: treat TEMP-* entries as unique
Otherwise, they will get rehashed into a different temp
name, preventing one to add notes to TEMP entries in an
extend file.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/python/bugs.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/python/bugs.py b/lib/python/bugs.py index 700a9c0272..570a5f859c 100644 --- a/lib/python/bugs.py +++ b/lib/python/bugs.py @@ -789,6 +789,15 @@ class CVEExtendFile(CVEFile): is_extend = True + def isUniqueName(self, name): + # an extend file can have TEMP-* entries to refer to the temp values + # for e.g. CVE-2018-XXXX. Consider TEMP-* entries as unique, so they + # don't get re-hashed and their notes get added to the original entries + if name.startswith('TEMP-'): + return True + + return CVEFile.isUniqueName(self, name) + class DSAFile(FileBase): """A DSA file. |