Fix token generation and enable wiping tokens