Domain verification state: example.com: 1024

I was working on adding a deeplinks to android app. Using quite good guide from Google I was able to add assetlinks.json file to my domain and setup manifest.

Using adb shell I could start my app without any issues:

adb shell am start -a android.intent.action.VIEW \
    -c android.intent.category.BROWSABLE \
    -d "http://domain.name:optional_port"

but when I tried to click on the link, app was ignored and Android opened the browser. Fortunately there is a way to validate the domain verification state:

adb shell pm verify-app-links --re-verify PACKAGE_NAME

and there it was, the error 1024:

com.example.pkg:
    ID: 01234567-89ab-cdef-0123-456789abcdef
    Signatures: [***]
    Domain verification state:
      example.org: 1024

Error code of 1024 or greater means “Custom error code that’s specific to the device’s verifier.” but that is not very heplful.

There is a way to validate the assetlinks.json file in browser by loading this url:

https://digitalassetlinks.googleapis.com/v1/statements:list?
   source.web.site=**https://domain.name:optional_port**&
   relation=delegate_permission/common.handle_all_urls

output was very useful!

Error: invalid_argument: Invalid android app asset descriptor (malformed cert fingerprint):

Malformed??? The cert fingerprint was copied from the Firebase Authentication, which is working, so what could be wrong?

I looked into other examples of assetlinks.json and noticed that every other app we made had the cert fingerprints in ALL_CAPS (the hex part) but this one had them in lowercase. I changed them to uppercase and voila! The app started to open the links correctly. For some reason the lowercase hex was not accepted by the verifier. Every time we created the asset links we used the ./gradlew signingReport to get the fingerprints and they were always in ALLCAPS. But this time I copied them from the Firebase console and they were in lowercase, so be careful with that.