---- datatemplateentry project ---- template : projects:display_template title : CovPass-Scanner: a dedicated solution for COVID-19 certificate scanning shorttitle : CovPass-Scanner participants_ : [[people:raphael_wimmer|Raphael Wimmer]], [[people:thomas_fischer|Thomas Fischer]], [[people:vitus_maierhoefer|Vitus Maierhöfer]] keywords_ : computer vision, raspberry pi, COVID-19 tags : digital_university status_ : finished start : 2021 end : 2022 photo_img : projects:covpass-scanner:first_proto_success.jpg shortdescription : Dedicated solution for COVID-19 certificate scanning. abstract : Dedicated solution for COVID-19 certificate scanning. ---- ==== Goals ==== Developing a standalone hardware prototype that can quickly verify digital COVID-19 vaccination certificates. ==== Background ==== Along with the europe-wide vaccination campaigns against COVID-19, the EU commission introduced a digital vaccination certificate. Information about a person and their vaccinations is digitally signed by a state agency or other trustworthy entity. This certificate is then encapsulated in a QR code that their owner can print out or import into a digital wallet. Whenever the vaccination status needs to be verified, the owner shows the QR code and their passport or ID card. In 2021, many venues and countries required proof of vaccination against COVID-19 before entry. Verifying certificates at scale is rather tedious when using one of the the commonly recommended mobile apps (e.g., //CovPassCheck//) for this task. Dedicated personnel placed at the entrance to events or establishments need to manually scan in the QR code and verify the identity of patrons. Processing certificate QR-codes this way, takes longer than needed, since the smartphone camera's position and orientation needs to be adjusted by the operator, each time a new person shows them their certificate. On top of that, the auto-focus of the smartphone camera needs to adjust for each scan as well, adding additional delay until the QR code can actually be scanned. We figured that using a stationary device with a dedicated area to place the QR code and fixed-focus camera might significantly reduce the time need ed per scan and thus improve overall throughput and satisfaction. ==== Status ==== We developed two proof-of-concept prototypes for verifying certificate authenticity and validity. The second prototype also compares the person's name in the certificate to their ID card. In late 2021, proof of vaccination was no longer required at most venues in Germany or at borders to neighboring countries. Therefore, we did no longer pursue this idea. The [[https://github.com/PDA-UR/CovPass-Scanner|open-source code on GitHub]] may be of use to others who intend to automatically verify cryptographically signed data in a QR code. ==== Hardware ==== === Prototype I === For the initial prototype, we used a regular Raspberry Pi 4 with a PiCam module and 3.2" display for our hardware. We printed a plastic case to house it and mounted it on an aluminum framework. It was designed to only read QR codes display, whether the certificate is valid or not. {{:projects:covpass-scanner:first_proto_demo.mp4?640x360| Demo video of the first Prototype}} [{{:projects:covpass-scanner:first_proto_front.jpg?400|**Figure 1.** First prototype from the front.}}] [{{:projects:covpass-scanner:first_proto_success.jpg?400|**Figure 2.** Successful scan.}}] [{{:projects:covpass-scanner:first_proto_side.jpg?400|**Figure 3.** Side of the first prototype (ID for scale).}}] === Prototype II === For the second prototype, we changed the previous camera and small display for a bigger, high resolution display with integrated camera and flipped the design upside-down. This change allows it to be mounted e.g. behind transparent room separators. This version also now featured the ability to compare the personal information contained in the digital certificate with that of a personal German ID. The prototype would now only return a valid status, if the certificate is valid and matches the personal information on the person's ID. As we use slightly frosted glass for the scan area, any object farther away from the glass surface than a few millimeters appears blurred in the camera image. Only when the passport is put directly on the glass, the text on it can be read. This serves two purposes. First, privacy of passers-by is ensured, as the camera's focus depth is physically constrained to a very small distance range. Second, analyzing the sharpness of the image is fast and allows for robustly detecting whether a document is put on the glass or not. More computationally expensive processing steps - such as text recognition - are only triggered when necessary. This allows for low latency even on rather slow hardware. [{{:projects:covpass-scanner:second_proto_step1.jpg?400|**Figure 4.** Second prototype, scan QR code in Step 1.}}] [{{:projects:covpass-scanner:second_proto_step2.jpg?400|**Figure 5.** Certificate valid, scan ID in Step 2.}}] [{{:projects:covpass-scanner:second_proto_success.jpg?400|**Figure 6.** Personal information matches, vaccination status valid.}}] ==== Software ==== The program code for the prototype is written in Python3 and uses OpenCV for image processing as well as Tesseract for text recognition. The source code is available on [[https://github.com/PDA-UR/CovPass-Scanner|GitHub]].