-
Notifications
You must be signed in to change notification settings - Fork 547
feat(checker): Added Mozilla Thunderbird checker #2429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Poor buggy CI 😢 But yeah, in updating the underlying database to track sources of CVE data better and de-dupe better we had to break the CI until the cache could update (in theory I could force an update, but it wasn't working at the time that i tried). It looks like we broke at least one test that I wasn't anticipating, so Im working on resolving that today and hopefully we'll be able to get pull requests moving again for a few last things before I code freeze for 3.2. |
cve_bin_tool/checkers/thunderbird.py
Outdated
CONTAINS_PATTERNS: list[str] = [] | ||
FILENAME_PATTERNS: list[str] = [r"thunderbird"] | ||
VERSION_PATTERNS = [ | ||
r"ENCODER=Mozilla([0-9]+.[0-9]+(.[0-9]+)?)", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This pattern exists in Mozilla Firefox checker too. This could probably lead to false positives (we also might want to take out the pattern from Firefox if this pattern is present in Thunderbird)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess if the parent company is same then version tags for them will also be similar. Moreover this is the only valid debian version pattern that there is (I tried with many others but could not get any other patterns which make the tests pass).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue is with this pattern our tool will say the detected binary is Firefox if it scans Thunderbird (false positive). That's probably not what we want.
@BreadGenie This should probably do it. All tests are passing on my local in linux as well as on windows. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
The error is around update schema (which was recently adjusted to need the extra arguments). I'm going to try updating the branch to see if that resolves it. =========================== short test summary info ============================
FAILED test/test_cli.py::TestCLI::test_update_flags - TypeError: latest_schema() missing 2 required positional arguments: 'table_name' and 'table_schema'
FAILED test/test_cli.py::TestCLI::test_update - TypeError: latest_schema() missing 2 required positional arguments: 'table_name' and 'table_schema'
============ 2 failed, 18 passed, 2 skipped, 23 warnings in 48.64s ============= |
Codecov Report
@@ Coverage Diff @@
## main #2429 +/- ##
==========================================
+ Coverage 82.29% 82.95% +0.65%
==========================================
Files 577 579 +2
Lines 9656 9666 +10
Branches 1148 1148
==========================================
+ Hits 7946 8018 +72
+ Misses 1373 1322 -51
+ Partials 337 326 -11
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks ready to merge. I've filed a separate bug #2453 for improving the firefox pattern so that it doesn't give false positives on thunderbird; I think we'll definitely want to fix that.
Fixes #2056
Signed off by metabiswadeep