Closed bencord0 closed 4 years ago
Both signature keys are trivially extractable from the published apk, but I expect they want you to use your own if you are building the app yourself.
Note you can't use the exposure notification APIs unless your app is blessed by Google so we are pretty limited in what we can do with the app source anyway.
Config repo does appear to be out of sync though.
@paulchambers Any idea how I could generate by own qrcodes keys? Do you have a link to some instructions for this?
I'll settle for not necessarily having a drop-in / side-loaded replacement for the nhs distributed app etc. My immediate goal is to get an APK built and local tests passing.
@bencord0 you need to generate a EC256 key pair. The app needs the PEM representation of the public key embedding and you use the private key to sign the JWT that goes in the QR code. See https://wiki.openssl.org/index.php/Command_Line_Elliptic_Curve_Operations for a guide to generating the key pair and https://jwt.io for JWT details.
If you use apktool on the production apk the key is in smali_classes3/uk/nhs/covid19/config/CommonKt.smali
You can see where it ends up being used in https://github.com/nhsx/covid-19-app-android-ag-public/blob/master/app/src/main/java/uk/nhs/nhsx/covid19/android/app/qrcode/QrCodeParser.kt
@nhs-covid19 any update on this one? The config repo is from mid august and the app doesn't compile at the moment.
Hi. Thanks for your patience. I hope to be able to publish a valid configuration repo and package in the next day or two. Apologies for this oversight.
The configuration source code has been updated which should now work with the android source code here. As mentioned in the README in that repo, we had a technical issue that prevented us from publishing the packages. It is our intention to sort this out, however, there is a work-around in the README that will allow the code to be compiled correctly.
Describe the bug The current latest commit in this repository refers to
configuration_version = "1.0.23-SNAPSHOT"
. https://github.com/nhsx/covid-19-app-android-ag-public/blob/01f790a0ebefe20ba6ff7925e56dfd88911741bf/app/build.gradle#L148But the current latest public commit on the configuration repo is set to
version = "1.0.15-SNAPSHOT"
.https://github.com/nhsx/covid-19-app-configuration-public/blob/59f08d62c4070496cd279de8d5a8d93c8387f3f6/build.gradle#L15-L37
Are these two repositories out of sync? I am getting the following "Unresolved reference" error during a
./gradlew
run of this repository.Has the
qrCodesSignatureKey
been published? Is the configuration repository https://github.com/nhsx/covid-19-app-configuration-public out of date?To Reproduce Steps to reproduce the behavior:
This is the patch that I'm using. It disables the remote check, as I will only be using the local maven cache to get the build working locally.
This is a workaround because the current packages are not published. https://github.com/nhsx/covid-19-app-configuration-public/packages <- this is empty.
./gradlew
Expected behaviour The application should build.
Actual behaviour
Unresolved reference: qrCodesSignatureKey
This line imports code which is not available publically. https://github.com/nhsx/covid-19-app-android-ag-public/blob/01f790a0ebefe20ba6ff7925e56dfd88911741bf/app/src/main/java/uk/nhs/nhsx/covid19/android/app/ExposureApplication.kt#L19
Desktop: