Hardwire format to PGP/MIME in the com server adapter, as discussed on outlook_mime_support
authorMarkus Schaber <markus@pep-security.net>
Thu, 01 Sep 2016 23:58:16 +0200
branchoutlook_mime_support
changeset 1568c9f8ce2c3a8
parent 155 0264d4b637a4
child 162 38cdf441c2cb
Hardwire format to PGP/MIME in the com server adapter, as discussed on
dev@.
CpEpEngine.cpp
CpEpEngine.h
pEpCOMServerAdapter.idl
     1.1 --- a/CpEpEngine.cpp	Thu Sep 01 19:09:52 2016 +0200
     1.2 +++ b/CpEpEngine.cpp	Thu Sep 01 23:58:16 2016 +0200
     1.3 @@ -1118,12 +1118,6 @@
     1.4  
     1.5  STDMETHODIMP CpEpEngine::encrypt_message(text_message * src, text_message * dst, SAFEARRAY * extra)
     1.6  {
     1.7 -	// this method is just a backwards compatibility wrapper
     1.8 -	return encrypt_message_ex(src, dst, extra, pEp_enc_pieces);
     1.9 -}
    1.10 -
    1.11 -STDMETHODIMP CpEpEngine::encrypt_message_ex(text_message * src, text_message * dst, SAFEARRAY * extra, pEp_enc_format enc_format)
    1.12 -{
    1.13      assert(src);
    1.14      assert(dst);
    1.15  
    1.16 @@ -1131,10 +1125,7 @@
    1.17      ::message *msg_dst;
    1.18      ::stringlist_t *_extra = new_stringlist(extra);
    1.19  
    1.20 -	// casting this value in a local variable allows for easier debugging.
    1.21 -	PEP_enc_format engine_enc_format = (PEP_enc_format)enc_format;
    1.22 -
    1.23 -    PEP_STATUS status = ::encrypt_message(get_session(), _src, _extra, &msg_dst, engine_enc_format);
    1.24 +    PEP_STATUS status = ::encrypt_message(get_session(), _src, _extra, &msg_dst, PEP_enc_PGP_MIME);
    1.25      ::free_stringlist(_extra);
    1.26  
    1.27      if (status == PEP_STATUS_OK)
     2.1 --- a/CpEpEngine.h	Thu Sep 01 19:09:52 2016 +0200
     2.2 +++ b/CpEpEngine.h	Thu Sep 01 23:58:16 2016 +0200
     2.3 @@ -218,8 +218,7 @@
     2.4      // Message API
     2.5  
     2.6      STDMETHOD(encrypt_message)(text_message * src, text_message * dst, SAFEARRAY * extra);
     2.7 -	STDMETHOD(encrypt_message_ex)(text_message * src, text_message * dst, SAFEARRAY * extra, pEp_enc_format enc_format);
     2.8 -	STDMETHOD(decrypt_message)(text_message * src, text_message * dst, SAFEARRAY ** keylist, pEp_color *rating);
     2.9 +    STDMETHOD(decrypt_message)(text_message * src, text_message * dst, SAFEARRAY ** keylist, pEp_color *rating);
    2.10      STDMETHOD(outgoing_message_color)(text_message *msg, pEp_color * pVal);
    2.11      STDMETHOD(identity_color)(pEp_identity_s * ident, pEp_color * pVal);
    2.12  
     3.1 --- a/pEpCOMServerAdapter.idl	Thu Sep 01 19:09:52 2016 +0200
     3.2 +++ b/pEpCOMServerAdapter.idl	Thu Sep 01 23:58:16 2016 +0200
     3.3 @@ -287,9 +287,6 @@
     3.4  	HRESULT register_callbacks([in] IpEpEngineCallbacks* new_callback);
     3.5  
     3.6  	HRESULT unregister_callbacks([in] IpEpEngineCallbacks* obsolete_callback);
     3.7 -
     3.8 -	// new members should be added to the end of this list...
     3.9 -	HRESULT encrypt_message_ex([in] struct text_message *src, [out] struct text_message * dst, [in] SAFEARRAY(BSTR) extra, [in] pEp_enc_format enc_format);
    3.10  };
    3.11  
    3.12  [