Implement Address.encode and Address.getRandom