opensrp / opensrp-client-core

Core OpenSRP Android client library
http://smartregister.org/
Other
17 stars 41 forks source link

Proceeding with the Client whose previous contacts were done by different user has some issues. #924

Closed dodosi closed 9 months ago

dodosi commented 9 months ago

When the user tries to create contact 2 of the client whose information was fed by another user, it becomes difficult as it is not possible to view the Client's profile and previously fed information by a different user.

The issues are as follows when you try to work with information fed by other users.

  1. When you click to see the profile, the app crashes.
  2. When you click to start specific contact, previous fed data does not appear as it is expected App's Screenshot image The error logs image Code image

@dubdabasoduba @Naima-Bashir

hilpitome commented 9 months ago

@dodosi We do not have the Keycloak client secret and id. Would you please send it to me via email.

hilpitome commented 9 months ago

Also note that for security purposes we have new recommendations on the Keycloak clients used for authentication. This Applies to both OpenSRP v1 and OpenSRP v2.

  1. (IMPORTANT) please disable Service Account Roles incase it is enabled for the OAuth Client your production application uses.
  2. There should be 3separate OAuth clients corresponding to the separate OpenSRP clients (Android, Web, Data ETLs) OpenSRP Keycloak OAuth Client Setup Guideline
  3. Android client - enable Direct Access Grantonly - To fetch a token you will not need the client secret
  4. Web client - enable Client Authentication and enable Standard flow (Enable implicit flow only for local dev testing - can be configured for stage and maybe preview but NOT production)
  5. Data/Analytics client - enable Client Authenticationand enable Service Account Roles cc @dodosi
hilpitome commented 9 months ago

It looks like the population of the facts map is being done on the main thread. If I am correct, I will be moving the related functions into a background thread.

Naima-Bashir commented 9 months ago

This has been resolved and confirmed by 1000 Hills solutions. Closing this cc @hilpitome