Fixes#791
It was possible for two requests to have the same ID, causing a crash and loss of StreamProvider connection.
This new id generation strategy creates a random ID, and increments it for each request.
In case the id generator is included from two different processes, I'm initializing the counter at a random number, and rolling it over a large number when it gets too big.
Our gas price buffering logic had a bug, because bn.js has inconsistent behavior when using hex-prefixed output. The issue has been opened with them here:
https://github.com/indutny/bn.js/issues/151
We've corrected our usage in the mean time.
Now old vaults are recognized as an "Initialized" MetaMask instance.
Upon logging in, when fetching the initial password-derived key, if there is no new-style vault, but there is an old style vault, it is migrated to the new format before proceeding through the usual unlocking steps.
This contract hex does include the value `f4`, but it was compiled from a contract with no instance of `.delegatecall`. I believe `f4` in this case is part of some other value or contract address, and `ethBinToOps` has some error in how it skips pushed data.
@kumavis
Added new Qunit build process that will browserify the contents of `test/integration/lib` into the QUnit browser, allowing much more modular testing, including unit testing of our modules in our target browsers.
Made a basic unit test file of this form for the new encryptor module, which fails miserably because I've only just begun to work with it.
I've started with this blog post as a starting point, and will be adjusting it to our needs from there:
http://qnimate.com/passphrase-based-encryption-using-web-cryptography-api/