Skip to content

x509cert: check for error of X509_set_serialNumber()#1031

Merged
rhenium merged 1 commit into
ruby:masterfrom
ndossche:clesss-6
Apr 20, 2026
Merged

x509cert: check for error of X509_set_serialNumber()#1031
rhenium merged 1 commit into
ruby:masterfrom
ndossche:clesss-6

Conversation

@ndossche
Copy link
Copy Markdown
Contributor

This function may return 0 on error [1].

[1] https://manpages.debian.org/stretch/libssl-doc/X509_set_serialNumber.3ssl.en.html

This was found by a hybrid static-dynamic analyser that looks for inconsistent handling of error checks in bindings.

Copy link
Copy Markdown
Member

@rhenium rhenium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This call seems to always succeed in the current implementation, but we should still check it. Thanks!

@rhenium rhenium merged commit 36dd37f into ruby:master Apr 20, 2026
47 checks passed
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.

2 participants