Aligning type naming with bitcoind and fixed pubkeyhash bug