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

Bugfix: Case-insensitive comparison of the Common Name to the GUN in x509 validation #1621

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

stefan-zh
Copy link

@stefan-zh stefan-zh commented Nov 23, 2021

At work I encountered a bug where the Common Name and the GUN differ only in their capitalization:
DEBU[0001] error leaf certificate CN: example.com/repository/LPF doesn't match the given GUN: example.com/repository/lpf

It turns out that capitalization shouldn't matter for CN and SANs in x509 certificates: https://security.stackexchange.com/a/150776
Therefore, I am proposing that Notary compares the two strings in a case-insensitive manner.

@stefan-zh stefan-zh force-pushed the bugfix/case-insensitive-comparison-common-name-gun branch from 618ff83 to 2c99de2 Compare November 23, 2021 16:06
…x509 certificate validation

Signed-off-by: Stefan Zhelyazkov <stefan.zhelyazkov@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant