Skip to content

Clarify the Certificate is not trusted Error.#286

Open
dopry wants to merge 1 commit intodigitalbazaar:mainfrom
dopry:Certificate_Not_Trusted_Error_Msg
Open

Clarify the Certificate is not trusted Error.#286
dopry wants to merge 1 commit intodigitalbazaar:mainfrom
dopry:Certificate_Not_Trusted_Error_Msg

Conversation

@dopry
Copy link
Copy Markdown

@dopry dopry commented Aug 9, 2015

I was working with the library and ran into the 'Certificate is not trusted Error'.There was a CN mismatch, but not being familiar with the library I was unsure what this error message meant or why the certificate was not trusted. After some debugging I discovered it was a subject mismatch and a matching certificate was not found in the caStore.

This PR modified the error message to identify the possible issues to a consumer.

I'm not very satisfied with the error message. It represents two possible error cases and is much longer than the other error conditions. It would be nice to separate DER validation from the caStore.hasCertificate method, so this error messaged could be more concise.

I cannot pursue refactoring hasCertificate at the moment, so I am proposing just updating the error message for now. If the changes would be welcome open an issue and assign it to me. I'll try to get around to it when time allows.

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.

1 participant