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
Bug: SrsHttpxConn SSL Key&Cert config problem. #4025
Comments
Nice work, your work clearly describe how this bug occurs. You are correct, it's really a bug for HTTPS API, the |
yes, I will try. |
Another problem of SSL Key&Cert config is that to config the key&cert for https://www.openssl.org/docs/manmaster/man3/SSL_use_certificate_file.html the srs/trunk/src/app/srs_app_conn.cpp Lines 743 to 754 in 5eb802d
In general, a SSL map to a tcp connection. So each tcp connection can custom its SSL certificate, that's what the SRS did. srs/trunk/src/app/srs_app_conn.cpp Lines 775 to 779 in 5eb802d
But it's overkill. the tcp connections shared same listen port at server side, have same SSL key&Cert, that's the usual case. |
Describe the bug
srs/trunk/src/app/srs_app_http_conn.cpp
Lines 382 to 387 in 427104f
SrsHttpxConn
can be used as HTTP API and HTTP Server, for both plain and SSL connection. For the SSL connection, we can config the SSL key & cert in this way.srs/trunk/conf/https.srs.conf
Lines 7 to 28 in 427104f
And
SrsConfig
has apis to get the key & cert.srs/trunk/src/app/srs_app_config.hpp
Lines 1052 to 1053 in 427104f
srs/trunk/src/app/srs_app_config.hpp
Lines 1074 to 1075 in 427104f
But
SrsHttpxConn
only callingget_https_stream_ssl_cert
&get_https_stream_ssl_key
even for theHttps API
connections.Version
All SRS version.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
http_api.https.key | cert should be loaded correctly.
Additional context
I found this bug when try to do #3701, found this bug and also #4024
The text was updated successfully, but these errors were encountered: