src/message_api.h
branchsync_and_key_reset
changeset 2955 3b2500a15709
parent 2874 45531079b073
parent 2935 73845aff051b
child 3137 93877eafa715
     1.1 --- a/src/message_api.h	Sat Sep 15 17:40:17 2018 +0200
     1.2 +++ b/src/message_api.h	Thu Sep 27 17:34:45 2018 +0200
     1.3 @@ -40,12 +40,19 @@
     1.4      
     1.5      // This is mainly used by pEp clients to send private keys to 
     1.6      // their own PGP-only device
     1.7 -    PEP_encrypt_flag_force_version_1 = 0x16
     1.8 +    PEP_encrypt_flag_force_version_1 = 0x10,
     1.9 +    
    1.10 +    PEP_encrypt_flag_key_reset_only = 0x20
    1.11      
    1.12  } PEP_encrypt_flags; 
    1.13  
    1.14  typedef unsigned int PEP_encrypt_flags_t;
    1.15  
    1.16 +typedef enum _message_wrap_type {
    1.17 +    PEP_message_default,    // typical inner/outer message 2.0
    1.18 +    PEP_message_transport,  // e.g. for onion layers
    1.19 +    PEP_message_key_reset   // for wrapped key reset information
    1.20 +} message_wrap_type;
    1.21  
    1.22  // encrypt_message() - encrypt message in memory
    1.23  //
    1.24 @@ -434,6 +441,26 @@
    1.25      );
    1.26  
    1.27  
    1.28 +// outgoing_message_rating_preview() - get rating preview
    1.29 +//
    1.30 +//  parameters:
    1.31 +//      session (in)        session handle
    1.32 +//      msg (in)            message to get the rating for
    1.33 +//      rating (out)        rating preview for the message
    1.34 +//
    1.35 +//  return value:
    1.36 +//      error status or PEP_STATUS_OK on success
    1.37 +//
    1.38 +//  caveat:
    1.39 +//      msg->from must point to a valid pEp_identity
    1.40 +//      msg->dir must be PEP_dir_outgoing
    1.41 +//      the ownership of msg remains with the caller
    1.42 +DYNAMIC_API PEP_STATUS outgoing_message_rating_preview(
    1.43 +        PEP_SESSION session,
    1.44 +        message *msg,
    1.45 +        PEP_rating *rating
    1.46 +    );
    1.47 +
    1.48  // identity_rating() - get rating for a single identity
    1.49  //
    1.50  //  parameters: