From 73f5e7d0ba7353ed38423c054bc9e721f34e670f Mon Sep 17 00:00:00 2001 From: Stefan Thomas Date: Tue, 22 Jan 2013 20:38:09 +0100 Subject: [PATCH 1/4] Update SJCL. --- src/js/sjcl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/sjcl b/src/js/sjcl index d04d0bdcc..dbdef434e 160000 --- a/src/js/sjcl +++ b/src/js/sjcl @@ -1 +1 @@ -Subproject commit d04d0bdccd986e434b98fe393e1e01286c10fc36 +Subproject commit dbdef434e76c3f16835f3126a7ff1c717b1ce8af From 2de124d6c0933082e5c46dd2bef42c2388fe6c86 Mon Sep 17 00:00:00 2001 From: Stefan Thomas Date: Tue, 22 Jan 2013 20:38:44 +0100 Subject: [PATCH 2/4] Expose SJCL so the client doesn't have to include a second copy. --- src/js/index.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/js/index.js b/src/js/index.js index 2d6e65f71..563edb9c5 100644 --- a/src/js/index.js +++ b/src/js/index.js @@ -1,4 +1,13 @@ exports.Remote = require('./remote').Remote; exports.Amount = require('./amount').Amount; exports.UInt160 = require('./amount').UInt160; -exports.Seed = require('./amount').Seed; \ No newline at end of file +exports.Seed = require('./amount').Seed; + +// Important: We do not guarantee any specific version of SJCL or for any +// specific features to be included. The version and configuration may change at +// any time without warning. +// +// However, for programs that are tied to a specific version of ripple.js like +// the official client, it makes sense to expose the SJCL instance so we don't +// have to include it twice. +exports.sjcl = require('../../build/sjcl'); From a1ad884441a17bc8cf91f5702aa2cfaadb07cb52 Mon Sep 17 00:00:00 2001 From: Stefan Thomas Date: Tue, 22 Jan 2013 20:47:06 +0100 Subject: [PATCH 3/4] Enable symmetric encryption dependencies. These are needed by the client and will soon be needed by ripple.js for message encryption/decryption. --- grunt.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/grunt.js b/grunt.js index d1a8c46e9..0249b053c 100644 --- a/grunt.js +++ b/grunt.js @@ -14,7 +14,7 @@ module.exports = function(grunt) { sjcl: { src: [ "src/js/sjcl/core/sjcl.js", -// "src/js/sjcl/core/aes.js", + "src/js/sjcl/core/aes.js", "src/js/sjcl/core/bitArray.js", "src/js/sjcl/core/codecString.js", "src/js/sjcl/core/codecHex.js", @@ -22,11 +22,11 @@ module.exports = function(grunt) { "src/js/sjcl/core/codecBytes.js", "src/js/sjcl/core/sha256.js", "src/js/sjcl/core/sha1.js", -// "src/js/sjcl/core/ccm.js", + "src/js/sjcl/core/ccm.js", // "src/js/sjcl/core/cbc.js", // "src/js/sjcl/core/ocb2.js", -// "src/js/sjcl/core/hmac.js", -// "src/js/sjcl/core/pbkdf2.js", + "src/js/sjcl/core/hmac.js", + "src/js/sjcl/core/pbkdf2.js", "src/js/sjcl/core/random.js", "src/js/sjcl/core/convenience.js", "src/js/sjcl/core/bn.js", From db241c10094f935a9c18193de5ecc8c44111b8b6 Mon Sep 17 00:00:00 2001 From: Stefan Thomas Date: Tue, 22 Jan 2013 21:10:15 +0100 Subject: [PATCH 4/4] Add SHA512 to SJCL. --- grunt.js | 1 + 1 file changed, 1 insertion(+) diff --git a/grunt.js b/grunt.js index 0249b053c..152cef351 100644 --- a/grunt.js +++ b/grunt.js @@ -21,6 +21,7 @@ module.exports = function(grunt) { "src/js/sjcl/core/codecBase64.js", "src/js/sjcl/core/codecBytes.js", "src/js/sjcl/core/sha256.js", + "src/js/sjcl/core/sha512.js", "src/js/sjcl/core/sha1.js", "src/js/sjcl/core/ccm.js", // "src/js/sjcl/core/cbc.js",