For use in short-lived objects with lifecycle not managed by us (e.g. a LoginModule).