enable since Mailvelope 1.0 available signing and sigature verification of encrypted messages

This commit is contained in:
Ralf Becker 2015-08-20 07:02:06 +00:00
parent 8cb0aade18
commit 00ccd37a24

View File

@ -4593,7 +4593,17 @@ app.classes.mail = AppJS.extend(
var container = iframe.parent()[0];
var container_selector = container.id ? '#'+container.id : 'div.mailDisplayContainer';
mailvelope.createDisplayContainer(container_selector, armored, _keyring).then(function()
options = {
showExternalContent: this.egw.preference('allowExternalIMGs') == 1 // "1", or "0", undefined --> true or false
};
// get sender address, so Mailvelope can check signature
var from_widget = this.et2.getWidgetById('FROM_0') || this.et2.getWidgetById('previewFromAddress');
if (from_widget && from_widget.value)
{
options.senderAddress = from_widget.value.replace(/^.*<([^<>]+)>$/, '$1');
}
mailvelope.createDisplayContainer(container_selector, armored, _keyring, options).then(function()
{
// hide our iframe to give space for mailvelope iframe with encrypted content
iframe.hide();
@ -4640,7 +4650,8 @@ app.classes.mail = AppJS.extend(
quotedMailHeader: options.predefinedText.slice(0, start_pgp).replace(/> /mg, '').trim()+"\n",
quotedMail: options.predefinedText.slice(start_pgp, end_pgp+this.end_pgp_message.length+1).replace(/> /mg, ''),
quotedMailIndent: start_pgp != 0,
predefinedText: options.predefinedText.slice(end_pgp+this.end_pgp_message.length+1).replace(/^> \s*/m,'')
predefinedText: options.predefinedText.slice(end_pgp+this.end_pgp_message.length+1).replace(/^> \s*/m,''),
signMsg: true // for now (no UI) always sign, when we encrypt
};
// set encrypted checkbox, if not already set
var composeToolbar = this.et2.getWidgetById('composeToolbar');
@ -4870,6 +4881,8 @@ app.classes.mail = AppJS.extend(
/**
* Revert back the icon after autoloading is finished
* @param {type} _id item id
* @param {type} _widget tree widget
* @returns {Boolean}
*/
folderMgmt_autoloadingEnd: function(_id, _widget)