Issue with webauthn_verify_attestation_response Returning 401 in Android #2061
-
Hi Team, I'm testing the Flow API for registration on native Android. I’ve set up the Hanko server locally and exposed the backend port using ngrok. I also added the Android key hash under: yaml
The registration flow completes successfully until the final step, webauthn_verify_attestation_response, which consistently returns a 401 Unauthorized error. Request (cURL)
Response
Note: Any insights on why the passkey might be considered invalid? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Since you are running the Hanko backend on your local machine you should see an error in the backend logs. It should look something like this:
And under the |
Beta Was this translation helpful? Give feedback.
The issue is fixed, what i was missing is, the rp id was used to be a localhost, I have added ngrok provided domain like below
webauthn:
relying_party:
id:<<ngrok_domain>>
origins:
- "http://localhost:8888"
- "android:apk-key-hash:TyBHH9maupZHjVknwsim6o7SjRTAtqI5mZ-jTUc9-hE"