add lifetime to session token
migrate metadata based and caching issuername registry code from 45