Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug in legal identifier logic #34

Open
rebeccabilbro opened this issue Jun 4, 2021 · 2 comments
Open

Bug in legal identifier logic #34

rebeccabilbro opened this issue Jun 4, 2021 · 2 comments
Labels
bug Something isn't working

Comments

@rebeccabilbro
Copy link
Collaborator

If the legal identifier is not LEI, the UI should prompt the user to enter a country but not a registration authority; it's currently swapped in the code. Here's the validation error that we got when we add a non-LEI ID with a country:

validation error: a legal person must not have a value for country and must have value for registration authority if identifier type is not LEIX

@rebeccabilbro rebeccabilbro added the bug Something isn't working label Jun 4, 2021
@bbengfort
Copy link
Collaborator

Update:

In v1.0-rc.5 we created a patch that checked for this error and simply ignores it because we were unable to submit a valid registration form. I reviewed the IVMS 101 standard which does say:

C9 CompleteNationalIdentifierLegalPerson: A LegalPerson must not have a value for countryOfIssue and (must have a value for the element RegistrationAuthority if the value for nationalIdentifierType is not LEIX and must not have a value for the element RegistrationAuthority if the value for nationalIdentifierType is LEIX).

C10 RegistrationAuthority The value used for the applicable element must be present on the GLEIF Registration Authorities List.

As far as I can tell, Registration Authority is something that only is applicable in the case of an LEIX identifier, so this constraint may have been typoed. I've reached out to the IVMS 101 working group for clarification.

Related to trisacrypto/trisa#53

@bbengfort
Copy link
Collaborator

Update from question sent to IVMS101 working group:

  1. Country of Issue must only be used for natural persons and
  2. If the National Identifier is an LEI, Registration Authority must be empty and
  3. If the National Identifier is not an LEI, Registration Authority is mandatory.

To help with this, we should probably create a select element for the GLEIF registration authorities list … though that will likely be a pain.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

2 participants