ready for bj
2nd merge of ready-for-bj
Refactor prep/sign pages and javascript

* Correct displayed BTC address to be actual address and not
  EC pubkey in base58check.
* Display RSA pubkey as well, and remove the oracle RSA key.
* Change text on prep page to include encoding of all displayed
  keys.
* Remove notes section on prep page and display all key info in
  one list.
* Group key creation, logging and webpage display javascript.
* Rename JS variables for consistency and signifying their encoding.
* Remove placeholder dummy privkey on signing page.
Add decryption of the double encryption and T3 signing

* Change cashout2 page layout and add more Crypto-JS script
  sources as well as using the rollups instead of components ones.
* Cleanup source code of prep and sign pages to have more consistent
  style and variable namings.
* Add base64 encoding of the oracle RSA privkey sent out for T3.
* Add RSA decryption of the encrypted event key
  (with giver/taker key) to get AES key for further decryption.
* Add AES decryption code using Crypto-JS to get to the second
  encryption
* Add base64 encoding of the oracle RSA key to avoid PEM newline
  issues in JS.
* Change RSA encryption padding from PKCS#1 to OAEP.
* Change EC test key generation in Mw to generate uncompressed
  mainnet keys in WIF format.
* Add T3 signatures submit requests to cashout2 page which is
  called after successful decryption of the encrypted event key.
Merge branch 'gustav/t3_signing'

* gustav/t3_signing:
  Add decryption of the double encryption and T3 signing
Add AES passphrase encryption of giver/taker EC/RSA privkeys

* Add AES passphrase entry to prep page, which after key generation
  encrypts the privkeys with the given passphrase.
* Change sign and cashout2 pages to request the passphrase instead of
  pasted privkeys.
* Extend Mw accordingly; adding the two encrypted privkeys (EC and RSA)
  for giver/taker to enter-contract API and then return these in
  subsequent pages so they are available in the pages when submitting
  T2 and T3 signatures.
Merge branch 'gustav/passphrase_encryption'

* gustav/passphrase_encryption:
  Add AES passphrase encryption of giver/taker EC/RSA privkeys
Update first curl example in README and Use jiffy for JSON encoding
Add server host config and postgres stuff
Merge branch 'gustav/prod_integration'

* gustav/prod_integration:
  Add server host config and postgres stuff
c-beams glitter in the dark near the Tanhauser Gate
Upgrade bitcoinjs from 0.1.3 to 1.0.2

* Upgrade bitcoin protocol code in prep, sign and cashout2 pages to
  bitcoinjs 1.0.2.
* Keep bitcoinjs 0.1.3 for jsbn files used for e.g. BigInteger.
* Include version in bitcoinjs folders to easily separate them
* Add bitcoinjs_1.0.2.js.
* Add bs58check.min.js.
* Remove debug values on web page as they are in JS console logging.
* Remove some encoding loggins in prep and sign pages.
Merge remote-tracking branch 'origin/gustav/prod_integration2' into HEAD

* origin/gustav/prod_integration2:
  Upgrade bitcoinjs from 0.1.3 to 1.0.2
Correct bitcoinjs signature encoding and Bj call params
partial readme update
Replace JSON-RPC calls to Bj with mw_btc module

* Add parsing of raw bitcoind blockchain files
* Add open output retrieval using blockchain parsing
* Add tx and tx sighash creation code for T2 and T3
* Add code for tx signing and adding signatures to T2 / T3
* Add broadcast of T2 / T3 using bitcoind JSON-RPC API
* Add new test key for giver with proper compression
Merge remote-tracking branch 'origin/gustav/erlang_btc_integration'

* origin/gustav/erlang_btc_integration:
  Replace JSON-RPC calls to Bj with mw_btc module
Add new Mw API for android integration

* Add new JSON endpoint on port 8082 for the new API
* Add new doc with curl examples of API usage and link to apiary
* Tested up to get_contract_state, which returns T2 for signing
Correct blade runner pictures in new android API doc
Integrate website flow with new mempool / blockchain querying.

* Add address UTXO mempool query of bitcoind
* Integrate mempool query with website flow and fallback to
  parsing bitcoind blockchain files if needed OO is not in mempool
* Make website more minimal by removing texts, links etc in preparation
  for major overhaul of style and flow
* Rip out lot's of unneeded / outdated code