eu-federation-gateway-service / efgs-federation-gateway

The goal of this project is to develop the official European solution for the interoperability between national backend servers of decentralised contact tracing applications to combat COVID-19.
Apache License 2.0
59 stars 25 forks source link

Upload: if 1 key in the batch is older than 14 days, whole batch fails validation #233

Closed EvgeniiSkrebtcov closed 3 years ago

EvgeniiSkrebtcov commented 3 years ago

Describe the bug

According to the code, before EFGS persists uploaded keys, it executes some validation checks. In case such validation fails, HTTP response contains an "Invalid Signature" message. If an upload batch contains a key with a rolling start interval older that 14 days, the whole batch fails validation.

Expected behavior

EFGS accepts valid keys from the batch. Invalid keys are ignored.

Steps to reproduce the issue

Upload a batch that will contain keys wit rolling start interval number older than 14 days

Technical details

N/A

Possible Fix

EFGS returns a Multistatus HTTP response

Additional context

N/A

f11h commented 3 years ago

Hello @EvgeniiSkrebtcov ,

this is intended behaviour. Uploading just some keys would break the signature of the uploaded batch.