[keycloak-dev] Custom user federation after 2.5.x
Jorge M.
jm85martins at gmail.com
Thu Jan 26 06:32:46 EST 2017
Hi,
It seems that some of the internal SPI's that supported custom federation
development in previous versions are now deprecated.
I'm looking at the new examples (jpa and simple) but I'm struggling with
the registration method.
My problem is that to use a custom webservice or a jpa implementation, I
need to know the basic user information at that point in order to do the
registration on my federation (name, email, username, ...) as the schema or
WS as non nullable / mandatory fields.
Is there any way to get that managed data at that point? (In the past I
used a solution based on TxAwareLDAPUserModelDelegate)
>From the jpa example:
@Override
public UserModel addUser(RealmModel realm, String username) {
UserEntity entity = new UserEntity();
entity.setId(UUID.randomUUID().toString());
entity.setUsername(username);
*//GET first name, last name and email here!!*
em.persist(entity);
logger.info("added user: " + username);
return new UserAdapter(session, realm, model, entity);
}
Thank you.
JM
More information about the keycloak-dev
mailing list