Note that gnutls is picky in regard to what it accepts as the server name - it
MUST be a domain name. IP addresses are not supported according to the
documentation.
Hence, filter out IP addresses and hope that whatever is not recognized as
such an address is actually a domain name. This will probably fail for more
exotic addresses (especially in IPv6 realm), but wiring up a full-blown parser
is too much effort and SSL plugins are not part of purple-3 anyway.
Fixes #17300
/**
* @file gtkprefs.c GTK+ Preferences
* @ingroup pidgin
*/
/* pidgin
*
* Pidgin is the legal property of its developers, whose names are too numerous
* to list here. Please refer to the COPYRIGHT file distributed with this
* source distribution.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
*
*/
#include"internal.h"
#include"pidgin.h"
#include"debug.h"
#include"nat-pmp.h"
#include"notify.h"
#include"prefs.h"
#include"proxy.h"
#include"prpl.h"
#include"request.h"
#include"savedstatuses.h"
#include"sound.h"
#include"sound-theme.h"
#include"stun.h"
#include"theme-manager.h"
#include"upnp.h"
#include"util.h"
#include"network.h"
#include"gtkblist.h"
#include"gtkconv.h"
#include"gtkdebug.h"
#include"gtkdialogs.h"
#include"gtkimhtml.h"
#include"gtkimhtmltoolbar.h"
#include"gtkprefs.h"
#include"gtksavedstatuses.h"
#include"gtksound.h"
#include"gtkstatus-icon-theme.h"
#include"gtkthemes.h"
#include"gtkutils.h"
#include"pidginstock.h"
#ifdef USE_VV
#include"media-gst.h"
#if GST_CHECK_VERSION(1,0,0)
#include<gst/video/videooverlay.h>
#elif GST_CHECK_VERSION(0,10,31)
#include<gst/interfaces/xoverlay.h>
#endif
#ifdef GDK_WINDOWING_WIN32
#include<gdk/gdkwin32.h>
#endif
#ifdef GDK_WINDOWING_X11
#include<gdk/gdkx.h>
#endif
#ifdef GDK_WINDOWING_QUARTZ
#include<gdk/gdkquartz.h>
#endif
#endif
#define PROXYHOST 0
#define PROXYPORT 1
#define PROXYUSER 2
#define PROXYPASS 3
#define PREFS_OPTIMAL_ICON_SIZE 32
structtheme_info{
gchar*type;
gchar*extension;
gchar*original_name;
};
/* Main dialog */
staticGtkWidget*prefs=NULL;
/* Notebook */
staticGtkWidget*prefsnotebook=NULL;
staticintnotebook_page=0;
/* Conversations page */
staticGtkWidget*sample_imhtml=NULL;
/* Themes page */
staticGtkWidget*prefs_sound_themes_combo_box;
staticGtkWidget*prefs_blist_themes_combo_box;
staticGtkWidget*prefs_status_themes_combo_box;
staticGtkWidget*prefs_smiley_themes_combo_box;
/* Sound theme specific */
staticGtkWidget*sound_entry=NULL;
staticintsound_row_sel=0;
staticgbooleanprefs_sound_themes_loading;
/* These exist outside the lifetime of the prefs dialog */