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

infra: add vscode extension poc #10592

Merged
merged 12 commits into from
Aug 28, 2023
Merged

infra: add vscode extension poc #10592

merged 12 commits into from
Aug 28, 2023

Conversation

DavidKorczynski
Copy link
Collaborator

@DavidKorczynski DavidKorczynski commented Jun 25, 2023

Add initial layout or a vscode extension.

Several commands included in the extension, including commands for

  • oss-fuzz initialization
  • creating new project integrations
  • generating coverage reports
  • building projects from arbitrary locations in the filesystem
  • reproducing crashes easily
  • instant CIFuzz integration
  • creating fuzzing templates for rapid prototyping
  • ...

Many ideas can be put into the vscode extension, for example:

  • support some form of e.g. sync with introspector.oss-fuzz.com -- for example where the plugin will check "has progress been made relative to what is currently at oss-fuzz". We could extend helper.py with some form of command called "check_progress` which will run a small build pipeline + coverage and check if the coverage performs better than what is currently achieved. I think there's more to explore in this space.
  • connect to auto-fuzz: https://github.com/ossf/fuzz-introspector/tree/main/tools/auto-fuzz
  • in general improve the extension UI, as currently it's only based on commands.

Signed-off-by: David Korczynski <[email protected]>
@DavidKorczynski DavidKorczynski marked this pull request as draft June 26, 2023 09:29
Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
@DavidKorczynski DavidKorczynski marked this pull request as ready for review August 10, 2023 22:36
Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
Copy link
Collaborator

@oliverchang oliverchang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice! we'll also want some user documentation at some point.

tools/vscode-extension/package.json Outdated Show resolved Hide resolved
tools/vscode-extension/package.json Outdated Show resolved Hide resolved

let targetProject = 'N/A';
let targetFuzzer = 'N/A';
// Logic for passing the file. This is based off of clusterfuzz monorail reports,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where exactly is this file coming from? Can we make this a more machine readable format?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It comes from the Monorail bug page, e.g.: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=59747
Screenshot 2023-08-16 222314

The problem with making it machine readable is the user needs to access the URL and authenticate to get the details. At that point it's easy to copy paste.

That said, I think this functionality has a lot of potential to improve but requires the ability to get details about issues in a headless mode.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right. How is that extracted in the first place? That bit wasn't clear :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

copy the parts of the monorail report and place it in a .info file. I added documentation around the feature which should clarify things. Let me know if it helps!

we'll also want some user documentation at some point.

I agree on this, which will ultimately document these things more verbosely. But I prefer to do this in follow up PRs.

Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
Signed-off-by: David Korczynski <[email protected]>
@DavidKorczynski
Copy link
Collaborator Author

Is this ready for merge @oliverchang ?

Copy link
Collaborator

@oliverchang oliverchang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Just need the conflict resolved.

@DavidKorczynski DavidKorczynski merged commit 07b8039 into master Aug 28, 2023
15 checks passed
@DavidKorczynski DavidKorczynski deleted the vscode-extension branch August 28, 2023 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants