replace base58 implementation