Open dylanmcreynolds opened 1 year ago
How do you do access group mapping with only orcid? If you do a lookup on other systems to get the groups, maybe this system also has email info available?
But I am fine with making email non-mandatory.
Or you could proably leverage the ORCID API [1] (LBNL is a orcid member) to retrieve the email.
[1] https://github.com/ORCID/orcid-model/blob/master/src/main/resources/record_3.0/README.md
If you have a keycloak instance inbetween scicat and orcid, check https://github.com/eosc-kc/keycloak-orcid/
How do you do access group mapping with only orcid? If you do a lookup on other systems to get the groups, maybe this system also has email info available?
Yes, we do a lookup to our user office system to get groups.
ORCID is a very popular OIDC authentication service in the scientific community. We use ORCID to allow our users to authenticate to SciCat. This worked with the old version of the backend, but does not work out of the box with the new SciCat backend.
When configured to use ORCID, authenticating the user results in the following error:
The issue here is that ORCID does not provide a couple of fields that are now required. ORCID does not provide an email address. It also does not provide either of the fields that the OIDCStrategy looks for here
Additionally, the schemas for
User
andCreateUserDTO
require email. https://github.com/SciCatProject/scicat-backend-next/blob/0f827b08007faf87e8f8ec68a101760e5d998356/src/users/schemas/user.schema.ts#L32Again, this is a regression as ORCID authentication worked fine in the old version of the backend. How to deal with this?
I can think about creating a special ORCIDStrategy puts the user's ORCID into the username field. But ORCID will never provide an email. I would like to make this field not required.