src/message_api.h
branchkeysync
changeset 939 ed7dfdae3031
parent 736 496905895282
child 952 986fd7b2eb8f
     1.1 --- a/src/message_api.h	Wed Jul 27 16:20:31 2016 +0200
     1.2 +++ b/src/message_api.h	Fri Jul 29 10:45:13 2016 +0200
     1.3 @@ -18,6 +18,12 @@
     1.4  void attach_own_key(PEP_SESSION session, message *msg);
     1.5  PEP_cryptotech determine_encryption_format(message *msg);
     1.6  
     1.7 +typedef enum _PEP_encrypt_flags {
     1.8 +    PEP_encrypt_flag_force_encryption = 0x1
     1.9 +} PEP_encrypt_flags; 
    1.10 +
    1.11 +typedef unsigned int PEP_encrypt_flags_t;
    1.12 +
    1.13  // encrypt_message() - encrypt message in memory
    1.14  //
    1.15  //  parameters:
    1.16 @@ -26,6 +32,7 @@
    1.17  //      extra (in)          extra keys for encryption
    1.18  //      dst (out)           pointer to new encrypted message or NULL on failure
    1.19  //      enc_format (in)     encrypted format
    1.20 +//      flags (in)          flags to set special encryption features
    1.21  //
    1.22  //  return value:
    1.23  //      PEP_STATUS_OK                   on success
    1.24 @@ -44,7 +51,8 @@
    1.25          message *src,
    1.26          stringlist_t *extra,
    1.27          message **dst,
    1.28 -        PEP_enc_format enc_format
    1.29 +        PEP_enc_format enc_format,
    1.30 +        PEP_encrypt_flags_t flags
    1.31      );
    1.32  
    1.33  
    1.34 @@ -72,7 +80,7 @@
    1.35      PEP_decrypt_flag_own_private_key = 0x1
    1.36  } PEP_decrypt_flags; 
    1.37  
    1.38 -typedef uint32_t PEP_decrypt_flags_t;
    1.39 +typedef unsigned int PEP_decrypt_flags_t;
    1.40  
    1.41  // decrypt_message() - decrypt message in memory
    1.42  //
    1.43 @@ -82,7 +90,7 @@
    1.44  //      dst (out)           pointer to new decrypted message or NULL on failure
    1.45  //      keylist (out)       stringlist with keyids
    1.46  //      color (out)         color for the message
    1.47 -//      flags (out)         flags to signal special message features
    1.48 +//      flags (out)         flags to signal special decryption features
    1.49  //
    1.50  //  return value:
    1.51  //      error status or PEP_STATUS_OK on success
    1.52 @@ -100,7 +108,7 @@
    1.53          message **dst,
    1.54          stringlist_t **keylist,
    1.55          PEP_color *color,
    1.56 -        PEP_decrypt_flags_t *flags 
    1.57 +        PEP_decrypt_flags_t *flags
    1.58  );
    1.59  
    1.60  // own_message_private_key_details() - details on own key in own message