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

Missing Error Check in function SSL_new() #1004

Closed
lc3412 opened this issue Sep 19, 2018 · 1 comment
Closed

Missing Error Check in function SSL_new() #1004

lc3412 opened this issue Sep 19, 2018 · 1 comment

Comments

@lc3412
Copy link

lc3412 commented Sep 19, 2018

Hi,
Function SSL_new() returns a pointer to an SSL object on success or NULL on error. However, the function SSL_new() in keepalived/genhash/ssl.c didn't check the return value is NULL or not, before passing the return value as an argument to both the function SSL_set0_rbio() and SSL_set0_wbio(). See the following details.

screenshot from 2018-09-19 16-33-43

Chi Li, Zuxing Gu, Jiecheng Wu

pqarmitage added a commit to pqarmitage/keepalived that referenced this issue Sep 19, 2018
Issue acassen#1004 identified that genhash didn't check the return value
of SSL_new(). This commit makes genhash check the return value of
SSL_new() and also BIO_new_socket(), and also fixes the same
problem in keepalived check_ssl.c/ssl_commect().

Signed-off-by: Quentin Armitage <quentin@armitage.org.uk>
@pqarmitage
Copy link
Collaborator

Commit 31b0644 now makes genhash check the return value of SSL_new() and also BIO_new_socket(). It also applies similar updates to keepalived/check_ssl.c.

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