Skip to content

[Usability issue] Notation login error message is confusing #637

@toddysm

Description

@toddysm

What is the areas you experience the issue in?

Notation CLI

What is not working as expected?

If somebody tries to sign in with invalid credentials, we are just passing through the registry error. This is not a very friendly experience.

notation login ghcr.io --username cloud-native-security --password ghp_EG6Dg2o6rHt1wdakjhfsfghiusdgfisdugfisfbv34hebrhwef
Error: GET "https://ghcr.io/v2/": GET "https://ghcr.io/token?scope=repository%3Auser%2Fimage%3Apull&service=ghcr.io": response status code 403: denied: denied

What did you expect to happen?

Provide a more friendly error message that removes the HTTP details.

How can we reproduce it?

Use the command above with wrong credentials.

Describe your environment

MacOS

What is the version of your Notation CLI or Notation Library?

notation version
Notation - a tool to sign and verify artifacts.

Version: 1.0.0-rc.4.230405
Go version: go1.20.2
Git commit: b008e79

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions