Add DhtID::toBuffer to dump ids
Add some unit tests