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

Validate x.509 cert value is a valid certificate before inlining contents into signature #251

Open
msetina opened this issue Mar 21, 2024 · 3 comments

Comments

@msetina
Copy link
Contributor

msetina commented Mar 21, 2024

If you set cert parameter of sign call to empty string, signature will produce an empty ds:X509Data/ in KeyInfo and even ignore public key data. Removing cert parameter form sign call will produce problem #250

@kislyuk
Copy link
Member

kislyuk commented Mar 23, 2024

Can you provide a specific example of what application you need to interoperate with that requires the X.509 certificate to be absent?

@kislyuk kislyuk changed the title Empty <ds:X509Data/> is added if cert is set to empty string in call to sign. Validate x.509 cert value is a valid certificate before inlining contents into signature Mar 23, 2024
@msetina
Copy link
Contributor Author

msetina commented Mar 23, 2024

My code was faulty and produced empty string for ca chain. The cert parameter was no cecked, so the undesired result. Will provide the example....

@kislyuk
Copy link
Member

kislyuk commented Mar 24, 2024

I see, thanks. Yes, we need some validation here to ensure the certificate string to be inserted is an actual X.509 certificate.

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

No branches or pull requests

2 participants