Skip to content
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

[JENKINS-68415] Skip archives, jar-files and executables from fingerprinting #1003

Merged
merged 2 commits into from
Jan 17, 2024

Conversation

uhafner
Copy link
Member

@uhafner uhafner commented Jan 12, 2024

For files with extension "o", "exe", "dll", "so", "a", "lib", "jar", "war", "zip", "7z", "gz", "bz2" it does not make sense to compute a fingerprint.

See JENKINS-68415

@uhafner uhafner added the enhancement Enhancement of existing functionality label Jan 12, 2024
Copy link

☀️ Quality Monitor

  • 🚦 Tests: 1271 tests passed
  • 👣 Code Coverage: 92% coverage achieved
  • ⚠️ Style: No warnings found
  • 🐛 Bugs: 6 warnings found (0 error, 0 high, 0 normal, 6 low)

More details are available in the GitHub Checks Result.

@uhafner uhafner changed the title Skip archives, jar-files and executables from fingerprinting [JENKINS-68415] Skip archives, jar-files and executables from fingerprinting Jan 12, 2024
Copy link

☀️ Quality Monitor

  • 🚦 Tests: 1272 tests passed
  • 👣 Code Coverage: 92% coverage achieved
  • ⚠️ Style: No warnings found
  • 🐛 Bugs: 6 warnings found (0 error, 0 high, 0 normal, 6 low)

More details are available in the GitHub Checks Result.

Copy link

codecov bot commented Jan 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (0a5a2c8) 93.14% compared to head (217d5c3) 93.14%.

Additional details and impacted files
@@            Coverage Diff            @@
##               main    #1003   +/-   ##
=========================================
  Coverage     93.14%   93.14%           
- Complexity     2409     2413    +4     
=========================================
  Files           353      353           
  Lines          6637     6640    +3     
  Branches        691      692    +1     
=========================================
+ Hits           6182     6185    +3     
  Misses          255      255           
  Partials        200      200           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@uhafner uhafner merged commit 68a8d40 into main Jan 17, 2024
29 checks passed
@uhafner uhafner deleted the skip-archives branch January 17, 2024 08:05
@KalleOlaviNiemitalo
Copy link

Alongside each exe or dll file, we typically have a binary pdb (program database) file for debug information such as names of local variables. But I suppose these pdb files typically have no warnings reported for them and then won't be fingerprinted anyway. Also, chemists apparently use the same pdb extension for text-format Protein Data Bank files and might want to fingerprint those.

@KalleOlaviNiemitalo
Copy link

A heuristic might work here: read a kilobyte or so from the start of the file and check whether that contains any null bytes. Although this would need to make an exception if the charset is declared as UTF-16.

@uhafner
Copy link
Member Author

uhafner commented Jan 17, 2024

Yes, I think people can add more extensions easily if they found such problems now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancement of existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants