syft
syft copied to clipboard
fix Windows file paths in local go mod cache
Previously, the file resolver was created from incorrect calls (path.Join instead of filepath.Join) which resulted Go license searches always missing on Windows. Use filepath.* functions when initializing the Go config, and when the unindexed file resolver is being created.
Fixed #2615.
TODOs:
- [ ] unit tests
- [ ] audit other configs and go license paths for incorrect path.Join use where filepath is needed
- [ ] Add Windows CI runner to prevent introduction of this sort of bug in the future (probably separate PRs :) )