aboutsummaryrefslogtreecommitdiffstats
path: root/smime/lib/e-asn1-object.h
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2003-12-04 04:48:05 +0800
committerChris Toshok <toshok@src.gnome.org>2003-12-04 04:48:05 +0800
commit2831ada5a5554a4a3c1920d73b43343d618f0e02 (patch)
tree718b56037a2e87c36f6c1fa9c9cdb8a62cf825d3 /smime/lib/e-asn1-object.h
parentd5cf06d5c681e540a545ccc11dfb9f1413ee02d6 (diff)
downloadgsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar.gz
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar.bz2
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar.lz
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar.xz
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.tar.zst
gsoc2013-evolution-2831ada5a5554a4a3c1920d73b43343d618f0e02.zip
add e-asn1-object.[ch]
2003-12-03 Chris Toshok <toshok@ximian.com> * lib/Makefile.am (libessmime_la_SOURCES): add e-asn1-object.[ch] * gui/smime-ui.glade: rename the ca trust dialog, and give it a proper id. * gui/certificate-manager.c (yourcerts_selection_changed): just use @selection. (contactcerts_selection_changed): same. (authoritycerts_selection_changed): same. * gui/certificate-viewer.c (free_data): free the cert chain. (fill_in_general): move all the general tab stuff here. (hierarchy_selection_changed): new function. not finished. (fields_selection_changed): new function, unimplemented. (fill_in_details): new function, fill in the heirarchy and hook up signals and stuff. (certificate_viewer_show): call fill_in_general/fill_in_details. * lib/e-cert.c (e_cert_get_chain): new function. * lib/e-cert.h: add prototype for e_cert_get_chain. svn path=/trunk/; revision=23622
Diffstat (limited to 'smime/lib/e-asn1-object.h')
-rw-r--r--smime/lib/e-asn1-object.h81
1 files changed, 81 insertions, 0 deletions
diff --git a/smime/lib/e-asn1-object.h b/smime/lib/e-asn1-object.h
new file mode 100644
index 0000000000..ebdb7de15e
--- /dev/null
+++ b/smime/lib/e-asn1-object.h
@@ -0,0 +1,81 @@
+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
+/*
+ * Authors: Chris Toshok <toshok@ximian.com>
+ *
+ * Copyright (C) 2003 Ximian, Inc. (www.ximian.com)
+ *
+ * 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., 59 Temple Street #330, Boston, MA 02111-1307, USA.
+ *
+ */
+
+#ifndef _E_ASN1_OBJECT_H_
+#define _E_ASN1_OBJECT_H_
+
+#include <glib-object.h>
+
+#include "e-cert.h"
+
+#include <nspr.h>
+
+#define E_TYPE_ASN1_OBJECT (e_asn1_object_get_type ())
+#define E_ASN1_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_ASN1_OBJECT, EASN1Object))
+#define E_ASN1_OBJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), E_TYPE_ASN1_OBJECT, EASN1ObjectClass))
+#define E_IS_ASN1_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_ASN1_OBJECT))
+#define E_IS_ASN1_OBJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_ASN1_OBJECT))
+#define E_ASN1_OBJECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), E_TYPE_ASN1_OBJECT, EASN1ObjectClass))
+
+typedef struct _EASN1Object EASN1Object;
+typedef struct _EASN1ObjectClass EASN1ObjectClass;
+typedef struct _EASN1ObjectPrivate EASN1ObjectPrivate;
+
+enum {
+ E_ASN1_OBJECT_TYPE_APPLICATION,
+ E_ASN1_OBJECT_TYPE_CONTEXT_SPECIFIC,
+ E_ASN1_OBJECT_TYPE_PRIVATE
+};
+
+struct _EASN1Object {
+ GObject parent;
+
+ EASN1ObjectPrivate *priv;
+};
+
+struct _EASN1ObjectClass {
+ GObjectClass parent_class;
+
+ /* Padding for future expansion */
+ void (*_ecert_reserved0) (void);
+ void (*_ecert_reserved1) (void);
+ void (*_ecert_reserved2) (void);
+ void (*_ecert_reserved3) (void);
+ void (*_ecert_reserved4) (void);
+};
+
+EASN1Object *e_asn1_object_new_from_cert (ECert *cert);
+EASN1Object *e_asn1_object_new_from_der (char *data, guint32 len);
+EASN1Object *e_asn1_object_new (void);
+
+gboolean e_asn1_object_is_valid_container (EASN1Object *obj);
+PRUint32 e_asn1_object_get_asn1_type (EASN1Object *obj);
+PRUint32 e_asn1_object_get_asn1_tag (EASN1Object *obj);
+GList *e_asn1_object_get_children (EASN1Object *obj);
+const char *e_asn1_object_get_display_name (EASN1Object *obj);
+const char *e_asn1_object_get_display_value (EASN1Object *obj);
+
+void e_asn1_object_get_data (EASN1Object *obj, char **data, guint32 *len);
+
+GType e_asn1_object_get_type (void);
+
+#endif /* _E_ASN1_OBJECT_H_ */