Mercurial > pidgin.yaz
changeset 32077:8b434ffd4efc
Add support for using TCP relaying with TURN
author | Marcus Lundblad <ml@update.uu.se> |
---|---|
date | Mon, 06 Jun 2011 20:13:30 +0000 |
parents | 4cc9c1ea0019 |
children | a47a82a009bf |
files | ChangeLog libpurple/media/backend-fs2.c libpurple/network.c pidgin/gtkprefs.c |
diffstat | 4 files changed, 15 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Mon Jun 06 16:25:21 2011 +0000 +++ b/ChangeLog Mon Jun 06 20:13:30 2011 +0000 @@ -40,6 +40,8 @@ * proxy: Add new "Tor/Privacy" proxy type that can be used to restrict operations that could leak potentially sensitive data (e.g. DNS queries). (#11110, #13928) + * media: Add support for using TCP relaying with TURN (will only work with + libnice 0.1.0 and later). AIM: * Fix setting icons with dimensions greater than 64x64 pixels by scaling
--- a/libpurple/media/backend-fs2.c Mon Jun 06 16:25:21 2011 +0000 +++ b/libpurple/media/backend-fs2.c Mon Jun 06 20:13:30 2011 +0000 @@ -1818,9 +1818,16 @@ relay_info = append_relay_info(relay_info, turn_ip, port, username, password, "udp"); } + + /* TCP */ + port = purple_prefs_get_int("/purple/network/turn_port_tcp"); + if (port > 0) { + relay_info = append_relay_info(relay_info, turn_ip, port, username, + password, "udp"); + } - /* should add TCP and perhaps TLS relaying options when these are - supported by libnice using non-google mode */ + /* TURN over SSL is only supported by libnice for Google's "psuedo" SSL mode + at this time */ purple_debug_info("backend-fs2", "Setting relay-info on new stream\n");
--- a/libpurple/network.c Mon Jun 06 16:25:21 2011 +0000 +++ b/libpurple/network.c Mon Jun 06 20:13:30 2011 +0000 @@ -1149,6 +1149,7 @@ purple_prefs_add_string("/purple/network/stun_server", ""); purple_prefs_add_string("/purple/network/turn_server", ""); purple_prefs_add_int ("/purple/network/turn_port", 3478); + purple_prefs_add_int ("/purple/network/turn_port_tcp", 3478); purple_prefs_add_string("/purple/network/turn_username", ""); purple_prefs_add_string("/purple/network/turn_password", ""); purple_prefs_add_bool ("/purple/network/auto_ip", TRUE);
--- a/pidgin/gtkprefs.c Mon Jun 06 16:25:21 2011 +0000 +++ b/pidgin/gtkprefs.c Mon Jun 06 20:13:30 2011 +0000 @@ -1794,6 +1794,9 @@ pidgin_prefs_labeled_spin_button(hbox, _("_UDP Port:"), "/purple/network/turn_port", 0, 65535, NULL); + pidgin_prefs_labeled_spin_button(hbox, _("T_CP Port:"), + "/purple/network/turn_port_tcp", 0, 65535, NULL); + hbox = pidgin_prefs_labeled_entry(vbox, _("Use_rname:"), "/purple/network/turn_username", sg); pidgin_prefs_labeled_password(hbox, _("Pass_word:"),