Demonstrate adding findsecbugs to spotbugs. #137
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Demonstrate adding findsecbugs to spotbugs. This commit is a demonstration and is not intended to be merged as-is.
With no changes, findsecbugs reports several findings for this plugin. The MD5 warning is common in Jenkins and exists in core. In this case, it is used for tracking and not for security so it can be suppressed though even here it would be better to eventually upgrade to a better algorithm.
The PATH_TRAVERSAL_IN findings here are particularly interesting. These relate to CVE-2019-10320 from Jenkins Security Advisory 2019-05-21. At this time, these findings are only used for migrating old data and do not represent real vulnerabilities. As we approach a year since the release of the fix, we should consider removing the migration code to remove the suppression. If we had run findsecbugs on this plugin prior to 2019-05-21 it would have detected a valid security vulnerability.
My plan is to add findsecbugs at the plugin pom after sufficient testing and communication. At that point, it would make sense to add the suppressions, but not the pom file changes from this PR.