Hey,
I am currently working on putting the ECC Key Generator into a thread to make it possible to create long keys without blocking the GUI.
First thing I have done is finding out which is the computation intensive task, which from my findings should be
pub = curve.G.mult(sec)
on line 323 of ecc.js.
This part does not use any randomness, so it should be easy to move it into a thread.
Correct me if I am wrong,
otherwiseI will start doing this the next week and
hopefully I can give something back afterwards,
even though the current sjcl model is not really
supportive for adding thread support as no callbacks are used,
which will make it difficult to add it in the typical sjcl flow.
Even though maybe a function like generateKeyAsync(callback) should be possible.
Thoughts on this highly appreciated.
Regards,
Nils