-
Notifications
You must be signed in to change notification settings - Fork 500
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
✨ Pinned-Dependencies: no longer complain about CIFuzz #1319
Conversation
why can CIFuzz action not be pinned? They don't version or release it? |
In order to build projects, CIFuzz uses parts of the OSS-Fuzz repo that can be updated. |
Understood. What's the risk of using the action on push? Can project X's fuzzing integration affect a project Y's fuzzing targets? Does the action require write permissions to store fuzzing results? |
Push to the project?
No.
In CIFuzz no(t for now). In ClusterFuzzLite: yes. |
Sorry, I meant on push trigger in a workflow.
great. Is the reason the action cannot be pinned because the fuzz targets are defined on the OSS-Fuzz repo in https://github.com/google/oss-fuzz/tree/master/projects?
Great. I'm curious about ClusterFuzzLite: requires |
Exactly
So actually, I may have lied. ClusterFuzzLite uses github actions artifacts and writes to them. I don't think it requires specific permissions to do this though. |
would a proper fix be to have the list of projects in a separate
+1 |
FWIW CIFuzz seems to work just fine with just
and the "global" setting set to "restricted". |
I think the better alternative would be to move CIFuzz to another repo so that could be pinned and the OSS-Fuzz repo could be grabbed from HEAD.
|
CIFuzz and CFLite can't be pinned properly and it isn't clear how they should be versioned to let Dependabot update them automatically. Projects using them shouldn't be penalized. Related: #1305 google/oss-fuzz#6836
Yep, artifacts isn't affected by token permissions, so we only need read. @laurentsimon do you have any other concerns about excluding CIFuzz and CFLite from this check? (This PR would also need to get updated with CFLite as well). |
Done
The systemd project does that :-) |
Right, but the API for OSS-Fuzz forces you to have wrappers for those in the OSS-Fuzz repo, and those in theory can be modified. For systemd youre welcome to be disciplinned and pin since you know you wont modify them, but other projects certainly will. |
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.
Thanks
Integration tests success for |
I have mostly 2 concerns:
|
Valid points 👍 |
As part of our pubic meeting today ,we decided to change the score calculation to mitigate this problem. Instead of giving a score of 0 if a non-pinned action is found, we'll remove 1 point for each. We considered using a percentage for score (score = X if X% of actions are pinned). However this was deemed problematic for the following reason: if a repo has 100 actions and 80% are pinned, score would be 8. If a repo has 10 actions and 80% are pinned, score would be 8 as well. However, the risk for the former repo is higher since it effectively has 20 unpinned actions, whereas the latter only has 2 unpinned actions. Please feel free to comment on this change. |
I think I agree to some extent but it still seems a bit weird to me that projects using CIFuzz get lower scores than projects with no GHActions whatsoever. I think I complained somewhere that a project with no tests, no GHActions and so on got almost the same score as |
by |
Yes, I meant the aggregated score for the most part but some individual checks like More generally, I'm not sure what those scores are supposed to mean. If they are supposed to be used to "improve the security posture of open source projects" I don't think that complaining about CIFuzz is in line with that considering that the only way to address that is to remove CIFuzz :-) |
I see what you mean. Aggregated scores are something we added because some people wanted a single number. But they are not meaningful in themselves. We want to have more meaningful levels with tiered checks like branch protection https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection, and later have more structured output with levels/policies based on individual settings. We hope this will fix the problem.
Or improve CIFuzz :-) |
I agree they aren't but I'm pretty sure they will be used to compare projects. I'm not sure it's mentioned anywhere that it doesn't make much sense (in its current form at least)
Given that some checks are intertwined I'm not sure even tiered checks can always help. For example, unpinned actions like CIFuzz can in theory pwn repositories if they have write access but if they don't I think in practice it doesn't matter whether they are pinned or not. In this particular case the results of both checks should probably be combined somehow.
That would be CI-Tests as well. With #1335 applied the bcc projects gets 0 because there are no tests there according to the check but with #1293 (comment) it should increase to 8 |
thanks for the feedback. I think this is in line with what we're trying to do with the Does the above align with your thinking? Which other checks do you think should be re-arranged? cc @asraa who works no the dangerous workflow check.
|
On second thought, even though they can't use GITHUB_TOKEN to pwn repositories they still can steal other credentials that in turn can be used to pwn repositories indirectly in mysterious ways :-)
At first glance it does
I'm not sure. I haven't though carefully about it yet |
@jonathanmetzman looking at google/oss-fuzz#6957 I wonder if CIFuzz can be bumped when clang rolls. As far as I know the CodeQL action for example gets updated every time the "default CodeQL bundle" gets updated: systemd/systemd#21504. It's probably safe to assume that every clang roll is a new version in a way |
On second thought, for that to work all those Docker images with different clang versions would have to be kept somewhere. it's probably not worth it |
This is due to an OSS-Fuzz bug that I can't fix at this point. +10000 to what evgeny said here. Discouraging CIFuzz use does the opposite of what scorecards is trying to achieve. |
CIFuzz can't be pinned properly and it isn't clear how it should be
versioned to let Dependabot update it automatically. Projects using it
shouldn't be penalized.
Related:
#1305
google/oss-fuzz#6836