Fixed error in AES due to "use strict" directive

This commit is contained in:
Giulio Cesare Solaroli 2015-08-18 17:30:06 +02:00
parent a2f3ee038e
commit a0bd079b51
2 changed files with 5 additions and 3 deletions

View File

@ -824,7 +824,8 @@ MochiKit.Base.update(Clipperz.Crypto.AES, {
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
'deferredDecrypt': function(aKey, someData) { 'deferredDecrypt': function(aKey, someData) {
var deferredResult var deferredResult;
var executionContext;
var nonce; var nonce;
var message; var message;
var key; var key;

View File

@ -21,6 +21,7 @@ refer to http://www.clipperz.com.
*/ */
"use strict";
if (typeof(Clipperz) == 'undefined') { Clipperz = {}; } if (typeof(Clipperz) == 'undefined') { Clipperz = {}; }
if (typeof(Clipperz.PM) == 'undefined') { Clipperz.PM = {}; } if (typeof(Clipperz.PM) == 'undefined') { Clipperz.PM = {}; }
if (typeof(Clipperz.PM.Crypto) == 'undefined') { Clipperz.PM.Crypto = {}; } if (typeof(Clipperz.PM.Crypto) == 'undefined') { Clipperz.PM.Crypto = {}; }
@ -320,7 +321,7 @@ MochiKit.Base.update(Clipperz.PM.Crypto, {
deferredResult.addCallback(MochiKit.Async.wait, 0.1); deferredResult.addCallback(MochiKit.Async.wait, 0.1);
deferredResult.addCallback(Clipperz.Base.evalJSON); deferredResult.addCallback(Clipperz.Base.evalJSON);
deferredResult.addErrback(function(anError) { deferredResult.addErrback(function(anError) {
Clipperz.logError("Error while decrypting data [4]"); Clipperz.logError("Error while decrypting data [3]");
throw Clipperz.Crypto.Base.exception.CorruptedMessage; throw Clipperz.Crypto.Base.exception.CorruptedMessage;
}) })
} else { } else {