aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-cipher-context.h
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2003-12-10 13:25:24 +0800
committerMichael Zucci <zucchi@src.gnome.org>2003-12-10 13:25:24 +0800
commitd940c0dad4a4dd5e9b4c5014893c111ebf28e9e7 (patch)
tree887d349d4b1c0a1a25068ec2d8dd41a688ae1449 /camel/camel-cipher-context.h
parentad454163140688485032c256a447fde8089b7e6b (diff)
downloadgsoc2013-evolution-d940c0dad4a4dd5e9b4c5014893c111ebf28e9e7.tar.gz
gsoc2013-evolution-d940c0dad4a4dd5e9b4c5014893c111ebf28e9e7.tar.zst
gsoc2013-evolution-d940c0dad4a4dd5e9b4c5014893c111ebf28e9e7.zip
put the camel-smime-context.[ch] back in here, remove it from EXTRA_DIST,
2003-12-10 Not Zed <NotZed@Ximian.com> * Makefile.am (libcamel_la_SOURCES): put the camel-smime-context.[ch] back in here, remove it from EXTRA_DIST, and make it compile optinally the same way camel-tcp-stream-ssl.c does (#ifdef ...). * camel-smime-context.c (sm_verify_cmsg): add signer info to certvalidity. * camel-cipher-context.c (CamelCipherValidity): Added certinfo to validity for signing and encrypting, so we can find the keys later for a gui. (camel_cipher_validity_add_certinfo): add signer or encrypter info to the validity. (camel_cipher_validity_envelope): add sign/encrypt keys. svn path=/trunk/; revision=23904
Diffstat (limited to 'camel/camel-cipher-context.h')
-rw-r--r--camel/camel-cipher-context.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/camel/camel-cipher-context.h b/camel/camel-cipher-context.h
index 1a7387ac2c..4b5dbaed42 100644
--- a/camel/camel-cipher-context.h
+++ b/camel/camel-cipher-context.h
@@ -43,6 +43,7 @@ extern "C" {
#define CAMEL_IS_CIPHER_CONTEXT(o) (CAMEL_CHECK_TYPE((o), CAMEL_CIPHER_CONTEXT_TYPE))
typedef struct _CamelCipherValidity CamelCipherValidity;
+typedef struct _CamelCipherCertInfo CamelCipherCertInfo;
typedef enum {
CAMEL_CIPHER_HASH_DEFAULT,
@@ -68,6 +69,19 @@ enum _camel_cipher_validity_encrypt_t {
CAMEL_CIPHER_VALIDITY_ENCRYPT_STRONG,
};
+enum _camel_cipher_validity_mode_t {
+ CAMEL_CIPHER_VALIDITY_SIGN,
+ CAMEL_CIPHER_VALIDITY_ENCRYPT,
+};
+
+struct _CamelCipherCertInfo {
+ struct _CamelCipherCertInfo *next;
+ struct _CamelCipherCertInfo *prev;
+
+ char *name; /* common name */
+ char *email;
+};
+
struct _CamelCipherValidity {
struct _CamelCipherValidity *next;
struct _CamelCipherValidity *prev;
@@ -76,10 +90,12 @@ struct _CamelCipherValidity {
struct {
enum _camel_cipher_validity_sign_t status;
char *description;
+ EDList signers; /* CamelCipherCertInfo's */
} sign;
struct {
enum _camel_cipher_validity_encrypt_t status;
char *description;
+ EDList encrypters; /* CamelCipherCertInfo's */
} encrypt;
};
@@ -161,6 +177,7 @@ char *camel_cipher_validity_get_description (CamelCipherValidity
void camel_cipher_validity_set_description (CamelCipherValidity *validity, const char *description);
void camel_cipher_validity_clear (CamelCipherValidity *validity);
CamelCipherValidity *camel_cipher_validity_clone(CamelCipherValidity *vin);
+void camel_cipher_validity_add_certinfo(CamelCipherValidity *vin, enum _camel_cipher_validity_mode_t mode, const char *name, const char *email);
void camel_cipher_validity_envelope(CamelCipherValidity *valid, CamelCipherValidity *outer);
void camel_cipher_validity_free (CamelCipherValidity *validity);