I have to authenticate users against a remote authentication API. In the API's response there are several user properties, some of them mappable to a Drupal User some of them not.
Because of legal constraints I don't want to store the users' data in the Drupal DB. I need "free floating" users. I checked some modules (externalauth, ldap), and as far as I understand every module does in fact use the DB to store user data.
I'd very much like to write an AuthenticationProvider that returns an entity which exists just for this single request. But I have a feeling that this approach is way too simple.
What would be the correct way of doing this (if it is actually possible)?