finish implementing bitcoin rpc api

1. Finish implementing bitcoin rpc api, to add testcases.
2. fix rpc bitcoin_getaddressesbyaccount