[Scan][Auth] It doesn't block scanning when using incorrect credential #320
Replies: 4 comments 1 reply
-
|
The registry you're using is a public one. All the registry libraries use authentication only when it's actually needed. In this case, your wrong credentials are never used. You should repeat the test using a registry that has authentication turned on. Also, the title of this discussion is "It doesn't block scanning when using incorrect cert" but it's wrong. This is about the credentials (username/password) used to authenticate. TLS certificates are nowhere involved. |
Beta Was this translation helpful? Give feedback.
-
|
Hi @flavio , |
Beta Was this translation helpful? Give feedback.
-
|
Hi @xingzhang-suse , I think we can NOT directly use the Registry Secret created by Storage/Secrets page for testing scan. You could refer to my steps. After creating Registry Secret created by Storage/Secrets page, it will show in backend like: If we decode that ${token} and we will find its format is like: However, according to https://github.com/kubewarden/sbomscanner/blob/main/docs/user-guide/private-registries.md , So, if I use the format of registry secret created by Storage/Secrets page and do the scan testing below.
I can say that the above result doesn't recognize the secret so it's like scanning without secret... And, if I manually create the format of registry secret (followed by the backend's doc above) and do the scan testing below.
The above result makes sense. (It can recognize the secret and scan with the secret) Could you kindly check and let me know? Thanks. Hi @flavio, |
Beta Was this translation helpful? Give feedback.
-
|
The problem is with the contents of the secret created by the UI For some reason which baffles me, Docker HUB wants to be addressed with the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Steps:
Expected behavior:
It should show error message and block the scanning when using incorrect cert.
Beta Was this translation helpful? Give feedback.
All reactions