COM-52: Expose Encrypt for Identity (Myself) function in COM api
authorMarkus Schaber <markus@pep-security.net>
Thu, 09 Mar 2017 22:51:25 +0100
changeset 1633e9258cb79cf3
parent 1621 1c8171f2196a
child 1634 6f26a1081b55
COM-52: Expose Encrypt for Identity (Myself) function in COM api
- Add the flags to encrypt_message_for_self to allow enigmail compatibility.
src/message_api.c
src/message_api.h
     1.1 --- a/src/message_api.c	Mon Mar 06 16:08:32 2017 +0100
     1.2 +++ b/src/message_api.c	Thu Mar 09 22:51:25 2017 +0100
     1.3 @@ -1248,7 +1248,8 @@
     1.4          pEp_identity* target_id,
     1.5          message *src,
     1.6          message **dst,
     1.7 -        PEP_enc_format enc_format
     1.8 +        PEP_enc_format enc_format,
     1.9 +        PEP_encrypt_flags_t flags
    1.10      )
    1.11  {
    1.12      PEP_STATUS status = PEP_STATUS_OK;
     2.1 --- a/src/message_api.h	Mon Mar 06 16:08:32 2017 +0100
     2.2 +++ b/src/message_api.h	Thu Mar 09 22:51:25 2017 +0100
     2.3 @@ -23,7 +23,11 @@
     2.4  void add_opt_field(message *msg, const char *name, const char *value);
     2.5  
     2.6  typedef enum _PEP_encrypt_flags {
     2.7 -    PEP_encrypt_flag_force_encryption = 0x1
     2.8 +    PEP_encrypt_flag_force_encryption = 0x1,
     2.9 +
    2.10 +    // This flag is for special use cases and should not be used
    2.11 +    // by normal pEp clients!
    2.12 +    PEP_encrypt_flag_force_unsigned = 0x2
    2.13  } PEP_encrypt_flags; 
    2.14  
    2.15  typedef unsigned int PEP_encrypt_flags_t;
    2.16 @@ -89,7 +93,8 @@
    2.17          pEp_identity* target_id,
    2.18          message *src,
    2.19          message **dst,
    2.20 -        PEP_enc_format enc_format
    2.21 +        PEP_enc_format enc_format,
    2.22 +        PEP_encrypt_flags_t flags
    2.23      );
    2.24  
    2.25  // MIME_encrypt_message() - encrypt a MIME message, with MIME output