]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
res/pjsip: Mark WSS transport as secure 82/1182/1
authorMartin Tomec <tomec.martin@gmail.com>
Fri, 4 Sep 2015 10:33:47 +0000 (12:33 +0200)
committerMartin Tomec <tomec.martin@gmail.com>
Fri, 4 Sep 2015 10:49:07 +0000 (05:49 -0500)
Pjsip is refusing to use unsecure transport with "sips" in url.
WSS should be considered as secure transport.

ASTERISK-24602 #comment Partially fixed by setting WSS as secure

Change-Id: Iddac406c6deba6240c41a603b8859dfefe1a5353

res/res_pjsip_transport_websocket.c

index f2c16a11809d4fb82f2ae72c58b79c5b7de6b7d7..a49eaded51548beef1f7672beee6f780b269008f 100644 (file)
@@ -419,7 +419,7 @@ static int load_module(void)
        CHECK_PJSIP_MODULE_LOADED();
 
        pjsip_transport_register_type(PJSIP_TRANSPORT_RELIABLE, "WS", 5060, &transport_type_ws);
-       pjsip_transport_register_type(PJSIP_TRANSPORT_RELIABLE, "WSS", 5060, &transport_type_wss);
+       pjsip_transport_register_type(PJSIP_TRANSPORT_RELIABLE | PJSIP_TRANSPORT_SECURE, "WSS", 5060, &transport_type_wss);
 
        if (ast_sip_register_service(&websocket_module) != PJ_SUCCESS) {
                return AST_MODULE_LOAD_DECLINE;