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

Parameter confirmation of docker _registry scanning #2883

Closed
zhangzhenyu2 opened this issue May 20, 2024 · 1 comment
Closed

Parameter confirmation of docker _registry scanning #2883

zhangzhenyu2 opened this issue May 20, 2024 · 1 comment
Labels
question Further information is requested

Comments

@zhangzhenyu2
Copy link

src, _ := syft.GetSource(context.Background(), image, syft.DefaultGetSourceConfig().WithSources("registry"))
sbom, _ := syft.CreateSBOM(context.Background(), src, syft.DefaultCreateSBOMConfig())
_ = syftjson.NewFormatEncoder().Encode(os.Stdout, *sbom)

When syft's above code is scanned by docker, how to distinguish between http and https of the repository, and how to pass the account password of the mirror repository

@zhangzhenyu2 zhangzhenyu2 added the enhancement New feature or request label May 20, 2024
@kzantow
Copy link
Contributor

kzantow commented May 20, 2024

Hi @zhangzhenyu2 -- if you are referring to the OCI registry, you can use the syft.DefaultGetSourceConfig().WithRegistryOptions( image.RegistryOptions )

@kzantow kzantow added question Further information is requested and removed enhancement New feature or request labels May 20, 2024
@kzantow kzantow closed this as not planned Won't fix, can't repro, duplicate, stale May 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
Archived in project
Development

No branches or pull requests

2 participants