[network-manager-applet] editor: recognize PKCS#12 files exported from firefox (bgo #677881)
- From: JiÅÃ KlimeÅ <jklimes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet] editor: recognize PKCS#12 files exported from firefox (bgo #677881)
- Date: Mon, 16 Jul 2012 13:02:40 +0000 (UTC)
commit 13c6db880345b4123fb75d00905a5addbd046f92
Author: JiÅÃ KlimeÅ <jklimes redhat com>
Date: Mon Jul 16 14:43:52 2012 +0200
editor: recognize PKCS#12 files exported from firefox (bgo #677881)
We test PKCS#12 format using crypto function of libnm-util, namely
nm_utils_file_is_pkcs12().
src/wireless-security/eap-method.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/wireless-security/eap-method.c b/src/wireless-security/eap-method.c
index 0129ef6..8976b1e 100644
--- a/src/wireless-security/eap-method.c
+++ b/src/wireless-security/eap-method.c
@@ -18,7 +18,7 @@
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*
- * (C) Copyright 2007 - 2011 Red Hat, Inc.
+ * (C) Copyright 2007 - 2012 Red Hat, Inc.
*/
#include "config.h"
@@ -35,6 +35,7 @@
#include <nm-setting-connection.h>
#include <nm-setting-8021x.h>
#include "eap-method.h"
+#include "nm-utils.h"
GType
eap_method_get_g_type (void)
@@ -609,7 +610,8 @@ default_filter_privkey (const GtkFileFilterInfo *filter_info, gpointer user_data
if (!file_has_extension (filter_info->filename, extensions))
return FALSE;
- if (!file_is_der_or_pem (filter_info->filename, TRUE, &is_encrypted))
+ if ( !file_is_der_or_pem (filter_info->filename, TRUE, &is_encrypted)
+ && !nm_utils_file_is_pkcs12 (filter_info->filename))
return FALSE;
return require_encrypted ? is_encrypted : TRUE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]