move dhash into utils
update to make local test work again, and use new sig encryption pattern