diff options
author | Azul <azul@leap.se> | 2012-07-02 12:09:30 +0200 |
---|---|---|
committer | Azul <azul@leap.se> | 2012-07-02 12:09:30 +0200 |
commit | d743601c17a650e189f9c4bf1cab926b94363e45 (patch) | |
tree | 9f905a6226d9fb802c7357665c48b34d95df2610 /javascript/srp.js | |
parent | 3c141bd046c7f36f4b2636302eff7cd0445c546d (diff) |
added integration test for login
* added a small hook in srp to set a, A and Astr for testing
* moved generic functions for tests to SpecHelper
Diffstat (limited to 'javascript/srp.js')
-rw-r--r-- | javascript/srp.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/javascript/srp.js b/javascript/srp.js index 7021bfa..9aa47b9 100644 --- a/javascript/srp.js +++ b/javascript/srp.js @@ -28,6 +28,16 @@ function SRP() // *** Accessor methods *** + // allows setting the random number A for testing + + this.calculateAndSetA = function(_a) + { + a = new BigInteger(_a, 16); + A = g.modPow(a, N); + Astr = A.toString(16); + return Astr; + }; + // Returns the user's identity this.getI = function() { |