[gcr] ui: Add support for EC keys to key renderer



commit d1c8b8772f202e867e1416b99d6b2cae7ad2822b
Author: Stef Walter <stefw redhat com>
Date:   Thu Apr 17 07:16:51 2014 +0200

    ui: Add support for EC keys to key renderer

 ui/gcr-key-renderer.c |    4 +++-
 ui/gcr-key-widget.c   |    4 ++--
 2 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/ui/gcr-key-renderer.c b/ui/gcr-key-renderer.c
index 0ed0bc0..e2a8c4c 100644
--- a/ui/gcr-key-renderer.c
+++ b/ui/gcr-key-renderer.c
@@ -355,6 +355,8 @@ gcr_key_renderer_real_render (GcrRenderer *renderer, GcrViewer *viewer)
                        text = _("Private RSA Key");
                else if (key_type == CKK_DSA)
                        text = _("Private DSA Key");
+               else if (key_type == CKK_EC)
+                       text = _("Private Elliptic Curve Key");
                else
                        text = _("Private Key");
        } else if (klass == CKO_PUBLIC_KEY) {
@@ -446,7 +448,7 @@ gcr_key_renderer_new (const gchar *label, GckAttributes *attrs)
  * @attrs: (allow-none): the attributes to display
  *
  * Get the attributes displayed in the renderer. The attributes should represent
- * either an RSA or DSA key in PKCS\#11 style.
+ * either an RSA, DSA, or EC key in PKCS\#11 style.
  */
 void
 gcr_key_renderer_set_attributes (GcrKeyRenderer *self, GckAttributes *attrs)
diff --git a/ui/gcr-key-widget.c b/ui/gcr-key-widget.c
index 5f25501..a685b32 100644
--- a/ui/gcr-key-widget.c
+++ b/ui/gcr-key-widget.c
@@ -32,7 +32,7 @@
  * @title: GcrKeyWidget
  * @short_description: Key widget and renderer
  *
- * A #GcrKeyWidget can be used to display a RSA or DSA key. The widget
+ * A #GcrKeyWidget can be used to display a RSA, DSA or EC key. The widget
  * is normally in a collapsed state showing only details, but can be expanded
  * by the user.
  *
@@ -197,7 +197,7 @@ gcr_key_widget_new (GckAttributes *attrs)
  * @attrs: (allow-none): the attributes to display
  *
  * Get the attributes displayed in the widget. The attributes should represent
- * either an RSA or DSA key in PKCS\#11 style.
+ * either an RSA, DSA or EC key in PKCS\#11 style.
  */
 void
 gcr_key_widget_set_attributes (GcrKeyWidget *self, GckAttributes *attrs)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]