-
Notifications
You must be signed in to change notification settings - Fork 49
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
Version control details not strongly associated with results #248
Comments
@lgolding, scenario is that we've enlisted in multiple repositories for a single scan run. solution here might be to create some linkage between version control details and uri base ids. |
Proposed design:
Example: Suppose the
Now suppose the consumer has the following
To find out where this file came from in source control, the consumer proceeds as follows:
Update 2018/11/13 @lgolding: The requirement that |
@michaelcfanning FYI. |
I would prefer to just base locating provenance on the location, not BaseUriId as this puts less of a burden on the producer.
I think @kupsch means that he would prefer to map a And by "less of a burden on the producer," I think he means that my design requires a separate top-level
All of these resolve to the same provenance:
To determine if a file is within a version controlled directory, the following algorithm or equivalent will be used:
|
I had an action item from TC #26 to confirm that my proposed design works with submodules. It does. Here's an example. I have two GitHub repos, The directory tree looks like this:
The SARIF might look like this:
Note that the SARIF does not include a separate
Cloning the root repo with the appropriate command line arguments "just works":
You would not want an automated system to do that, and then go ahead a separately clone the submodule's repo. |
I've now taken a careful look at Jim's proposed alternative (and interspersed some commentary in it, because I had to carefully work through his example to understand his fairly abstract description :-)), and I agree his design is better. I'll write the change draft from his design. |
@lgolding this issue does not describe the change that you intend to make. can you please recap the design that you and jim prefer? i am most interested in verifying that we have not overly complicated the simple case (no git sub-modules) in order to accommodate the uncommon case (sub-modules). |
@michaelcfanning As we've just discussed, Jim's comment above, in which I interspersed my commentary, is the final design and is what the change draft contains. Also as we've just discussed: Jim's design works simply even in the single-repo case. It does not introduce complication purely for the sake of the less common multi-repo or submodule cases. I'm leaving this comment just so that other readers of this issue know that we didn't leave your last comment unaddressed. |
The version control details object tells us about the VS server, revision, etc., but doesn't contain an enlistment root location. As a result, we can't use this information to do things like rewrite URLs to point to hosted content.
The text was updated successfully, but these errors were encountered: