提交 f0aa0fc1 authored 作者: Anthony Minessale's avatar Anthony Minessale

seek chain cert from wss.pem just cat together the cert, the key and the chain cert into wss.pem

上级 77bddb9f
Tue May 20 20:29:10 CDT 2014
Tue May 20 23:17:55 CDT 2014
......@@ -361,11 +361,17 @@ static int tport_ws_init_primary_secure(tport_primary_t *pri,
if (path) {
key = su_sprintf(autohome, "%s/%s", path, "wss.key");
if (access(key, R_OK) != 0) key = NULL;
cert = su_sprintf(autohome, "%s/%s", path, "wss.crt");
if (access(cert, R_OK) != 0) cert = NULL;
chain = su_sprintf(autohome, "%s/%s", path, "ca-bundle.crt");
if (access(chain, R_OK) != 0) chain = NULL;
if (access(cert, R_OK) != 0) cert = NULL;
if ( !key ) key = su_sprintf(autohome, "%s/%s", path, "wss.pem");
if ( !cert ) cert = su_sprintf(autohome, "%s/%s", path, "wss.pem");
if ( !chain ) chain = su_sprintf(autohome, "%s/%s", path, "wss.pem");
if (access(key, R_OK) != 0) key = NULL;
if (access(cert, R_OK) != 0) cert = NULL;
if (access(chain, R_OK) != 0) chain = NULL;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论