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

[coepi-backend-aws]: Implement unified back-end supporting TCN Reports and Apple/Google keys #32

Open
ramnanib2 opened this issue May 6, 2020 · 4 comments
Assignees

Comments

@ramnanib2
Copy link
Collaborator

Reference Doc

https://docs.google.com/document/d/1l6ajoKs4En_STtaROlZdHtWI9VZE6c5HLpmBwEqWcXo/edit#

Development Branch

https://github.com/Co-Epi/coepi-backend-aws/tree/unified_backend

API Definition

https://github.com/Co-Epi/coepi-backend-aws/blob/unified_backend/api_definition/coepi_api_0.5.0.yml

Apple/Google Diagnosis Server Reference Implementation:

https://github.com/bhushanRamnani/apple-google-diagnosis-server-aws

Tasks:

  1. Implement TCN endpoint with lambda front-end
  2. Implement TCN endpoint with ktor front-end
  3. Add report and signature validation to TCN endpoint ([coepi-backend-aws][v4]: Do report signature validation on the server side before persisting the data #9)
  4. Implement Apple/Google endpoint with lambda front-end
  5. Implement Apple / Google endpoint with ktor front-end
@ramnanib2 ramnanib2 self-assigned this May 6, 2020
@jmccance
Copy link

jmccance commented May 7, 2020

Are we keeping the old /v4/tcnreport endpoints, or can those go away?

@jmccance
Copy link

jmccance commented May 7, 2020

Given that we're introducing a new report type that seems to be handled completely separately from TCN reports, I'd propose we reorganize the packages in core:

  • org.coepi.api.tcn.* - Core code for TCN reports
  • org.coepi.api.agen.* - Core code for "Apple/Google Exposure Notification" reports. (I am very open to suggestions for a better name than agen.)

@ramnanib2
Copy link
Collaborator Author

Are we keeping the old /v4/tcnreport endpoints, or can those go away?

Yes, we'll be moving to new format

@ramnanib2
Copy link
Collaborator Author

ramnanib2 commented May 9, 2020

Given that we're introducing a new report type that seems to be handled completely separately from TCN reports, I'd propose we reorganize the packages in core:

  • org.coepi.api.tcn.* - Core code for TCN reports
  • org.coepi.api.agen.* - Core code for "Apple/Google Exposure Notification" reports. (I am very open to suggestions for a better name than agen.)

agen seems fine. Instead of organizing protocols under packages, I was thinking we could just have a separate package name where we keep the service classes since dao and frontends are gonna be common. We could use either abstract method design pattern or strategy design pattern to pull out share common functionality between the services.

Common Functionality:

  1. Parse Query parameters intervalNumber and intervalLength for get
  2. Is-It-Human verification for get and post
  3. Error translation to Http response

Service specific functionality:

  1. Validating report/key data on post
  2. Signature verification where required during post
  3. Query records from DDB and translate to response body

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants