diff --git a/x11/gnome/keyring/Makefile b/x11/gnome/keyring/Makefile index 82d3ff37b5c..a64678af2f9 100644 --- a/x11/gnome/keyring/Makefile +++ b/x11/gnome/keyring/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.82 2012/10/02 15:58:02 ajacoutot Exp $ +# $OpenBSD: Makefile,v 1.83 2012/10/14 11:46:55 ajacoutot Exp $ SHARED_ONLY= Yes @@ -6,7 +6,7 @@ COMMENT= password agent for the GNOME project GNOME_PROJECT= gnome-keyring GNOME_VERSION= 3.6.0 -REVISION= 1 +REVISION= 2 HOMEPAGE= https://live.gnome.org/GnomeKeyring diff --git a/x11/gnome/keyring/patches/patch-pkcs11_rpc-layer_gkm-rpc-module_c b/x11/gnome/keyring/patches/patch-pkcs11_rpc-layer_gkm-rpc-module_c new file mode 100644 index 00000000000..91fb043076f --- /dev/null +++ b/x11/gnome/keyring/patches/patch-pkcs11_rpc-layer_gkm-rpc-module_c @@ -0,0 +1,23 @@ +$OpenBSD: patch-pkcs11_rpc-layer_gkm-rpc-module_c,v 1.1 2012/10/14 11:46:55 ajacoutot Exp $ + +From 0c71452290977332a0e86d9eb0d04b291cce2263 Mon Sep 17 00:00:00 2001 +From: Stef Walter +Date: Wed, 19 Sep 2012 07:12:39 +0000 +Subject: rpc-layer: Fix memory leak in call state pool + +--- pkcs11/rpc-layer/gkm-rpc-module.c.orig Tue Sep 25 13:57:30 2012 ++++ pkcs11/rpc-layer/gkm-rpc-module.c Sun Oct 14 12:29:37 2012 +@@ -1254,6 +1254,13 @@ rpc_C_Finalize (CK_VOID_PTR reserved) + warning (("finalizing the daemon returned an error: %d", ret)); + } + ++ /* Cleanup the call state pool */ ++ while (call_state_pool) { ++ cs = call_state_pool; ++ call_state_pool = cs->next; ++ call_destroy (cs); ++ } ++ + /* This should stop all other calls in */ + pkcs11_initialized = 0; + pkcs11_initialized_pid = 0; diff --git a/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-binary_c b/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-binary_c index be789942a9d..bb081b214e7 100644 --- a/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-binary_c +++ b/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-binary_c @@ -1,10 +1,15 @@ -$OpenBSD: patch-pkcs11_secret-store_gkm-secret-binary_c,v 1.2 2012/03/29 06:51:38 ajacoutot Exp $ +$OpenBSD: patch-pkcs11_secret-store_gkm-secret-binary_c,v 1.3 2012/10/14 11:46:55 ajacoutot Exp $ On OpenBSD, time_t is an int. https://bugzilla.gnome.org/show_bug.cgi?id=652565 ---- pkcs11/secret-store/gkm-secret-binary.c.orig Thu Mar 8 20:45:29 2012 -+++ pkcs11/secret-store/gkm-secret-binary.c Wed Mar 28 08:23:47 2012 +From b7648ca3864cf8d952468bae299806b0fcda5442 Mon Sep 17 00:00:00 2001 +From: Stef Walter +Date: Fri, 12 Oct 2012 15:39:53 +0000 +Subject: secret-store: Set the schema name correctly on loaded items + +--- pkcs11/secret-store/gkm-secret-binary.c.orig Wed Sep 19 10:59:27 2012 ++++ pkcs11/secret-store/gkm-secret-binary.c Sun Oct 14 12:31:39 2012 @@ -73,8 +73,8 @@ typedef struct { char *display_name; const guchar *ptr_secret; @@ -16,7 +21,29 @@ https://bugzilla.gnome.org/show_bug.cgi?id=652565 GHashTable *attributes; GList *acl; } ItemInfo; -@@ -851,7 +851,7 @@ gkm_secret_binary_read (GkmSecretCollection *collectio +@@ -738,15 +738,18 @@ static void + setup_item_from_info (GkmSecretItem *item, GkmSecretData *data, ItemInfo *info) + { + GkmSecretObject *obj = GKM_SECRET_OBJECT (item); ++ const gchar *schema_name; + GkmSecret *secret; +- const gchar *type; + + gkm_secret_object_set_label (obj, info->display_name); + gkm_secret_object_set_created (obj, info->ctime); + gkm_secret_object_set_modified (obj, info->mtime); + +- type = gkm_secret_compat_format_item_type (info->type); +- gkm_secret_item_set_schema (item, type); ++ schema_name = g_hash_table_lookup (info->attributes, GKM_SECRET_FIELD_SCHEMA); ++ if (schema_name == NULL) ++ schema_name = gkm_secret_compat_format_item_type (info->type); ++ gkm_secret_item_set_schema (item, schema_name); ++ + gkm_secret_item_set_fields (item, info->attributes); + + /* Collection is locked */ +@@ -851,7 +854,7 @@ gkm_secret_binary_read (GkmSecretCollection *collectio guchar major, minor, crypto, hash; guint32 flags; guint32 lock_timeout; diff --git a/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-textual_c b/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-textual_c new file mode 100644 index 00000000000..48aad6341c3 --- /dev/null +++ b/x11/gnome/keyring/patches/patch-pkcs11_secret-store_gkm-secret-textual_c @@ -0,0 +1,59 @@ +$OpenBSD: patch-pkcs11_secret-store_gkm-secret-textual_c,v 1.1 2012/10/14 11:46:55 ajacoutot Exp $ + +From b7648ca3864cf8d952468bae299806b0fcda5442 Mon Sep 17 00:00:00 2001 +From: Stef Walter +Date: Fri, 12 Oct 2012 15:39:53 +0000 +Subject: secret-store: Set the schema name correctly on loaded items + +--- pkcs11/secret-store/gkm-secret-textual.c.orig Wed Sep 19 06:54:58 2012 ++++ pkcs11/secret-store/gkm-secret-textual.c Sun Oct 14 12:30:20 2012 +@@ -122,7 +122,10 @@ generate_attributes (GKeyFile *file, GkmSecretItem *it + } + + static void +-parse_attributes (GKeyFile *file, GkmSecretItem *item, const gchar **groups) ++parse_attributes (GKeyFile *file, ++ GkmSecretItem *item, ++ const gchar **groups, ++ gint compat_type) + { + GHashTable *attributes; + const gchar *identifier; +@@ -130,6 +133,7 @@ parse_attributes (GKeyFile *file, GkmSecretItem *item, + gchar *prefix; + gchar *name, *type; + guint64 number; ++ const gchar *schema_name; + + /* Now do the attributes */ + +@@ -163,6 +167,12 @@ parse_attributes (GKeyFile *file, GkmSecretItem *item, + } + + gkm_secret_item_set_fields (item, attributes); ++ ++ schema_name = g_hash_table_lookup (attributes, GKM_SECRET_FIELD_SCHEMA); ++ if (schema_name == NULL) ++ schema_name = gkm_secret_compat_format_item_type (compat_type); ++ gkm_secret_item_set_schema (item, schema_name); ++ + g_hash_table_unref (attributes); + g_free (prefix); + } +@@ -331,7 +341,6 @@ parse_item (GKeyFile *file, GkmSecretItem *item, GkmSe + g_clear_error (&err); + type = 0; + } +- gkm_secret_item_set_schema (item, gkm_secret_compat_format_item_type (type)); + + val = g_key_file_get_string (file, identifier, "display-name", NULL); + gkm_secret_object_set_label (obj, val); +@@ -374,7 +383,7 @@ parse_item (GKeyFile *file, GkmSecretItem *item, GkmSe + gkm_secret_object_set_created (obj, num); + + /* Now the other stuff */ +- parse_attributes (file, item, groups); ++ parse_attributes (file, item, groups, type); + parse_acl (file, item, groups); + } +