fix up revocation stuff
factor out common code