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

Refuse weak DH groups #62

Open
2 tasks
KellerFuchs opened this issue Dec 15, 2016 · 4 comments
Open
2 tasks

Refuse weak DH groups #62

KellerFuchs opened this issue Dec 15, 2016 · 4 comments

Comments

@KellerFuchs
Copy link

There are at least two kinds of weak DH groups that lua-http silently accepts:

I'm not sure whether OpenSSL can check for those at all.

@daurnimator
Copy link
Owner

daurnimator commented Dec 15, 2016

I'm not sure how to check these... chromium/badssl.com#40 indicates that I should check the DH parameters.

I can't see in the OpenSSL API how to get the DH params (I'd preferably want them as an EVP_PKEY*) out of an SSL*; anyone able to jump in here?

@daurnimator
Copy link
Owner

daurnimator commented Oct 29, 2017

I can't see in the OpenSSL API how to get the DH params (I'd preferably want them as an EVP_PKEY*) out of an SSL*; anyone able to jump in here?

SSL_get_server_tmp_key is the function I was looking for. Introduced in 1.0.2.

Thanks to http://openssl.6102.n7.nabble.com/How-to-enforce-DH-field-size-in-the-client-td60442.html

I'll note that openssl seems to have some built in checks for DH keys available. grep for SSL_R_DH_KEY_TOO_SMALL.

@daurnimator
Copy link
Owner

luaossl now has ssl:getServerTemporaryKey()

@daurnimator
Copy link
Owner

I think this also needs wahern/luaossl#135

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants