onfido-sdk-ui
onfido-sdk-ui copied to clipboard
Chrome for Android not prompted to enable camera or fallback to file upload when permission is denied
What was the expected behaviour?
When prompted for Camera access in Chrome for Android if the user ticks the box "Do not ask again" and clicks "deny" and returns to the site later they should be falling back to file upload when clicking the "Take Photo" button
What happened instead?
They are not shown any kind of message nor do they fallback to file upload if they return to try again.
In Firefox for Android it falls back to file upload as expected.
Version info:
- Onfido SDK - 5.8.0
- OS - Android 8.1.0
- Browser - Chrome 81.0.4044.138
- Device - Oneplus A6003
- Node
- Framework or relevant dependencies (if applicable)
Integration configuration:
{
"useModal": false,
"token": ...,
"steps": [
{
"type": "welcome",
"options": {
"title": "Submit identity document",
"descriptions": [
"To finish verifying your identity, we need an identity document.",
"Please follow these steps to upload a document."
]
}
},
"document",
{
"type": "complete",
"options": {
"message": "Upload complete!"
}
}
]
}
Steps to reproduce:
This is how I discovered it, there may be an easier entrypoint: Precondition: Chrome is set to prompt for camera access when requested, camera access to chrome is turned off at the android app permissions level
- Initialize onfido SDK on computer
- Select document
- Select "Continue on Phone"
- Go to generated link on Android device with Chrome
- Click the "Take Photo" button on onfidos page
- When prompted to "Allow Chrome to tkae pictures and record video?" tick the "Don't ask again" button and click "Deny"
- At this point I would expect to be directed to the file browser to upload a file. If I click Take photo again I would expect to be directed to the file browser to upload file.
- Close your session and repeat steps 1 - 5 again At this point I would also expect it to fallback to the file browser but it does not, you're just stuck on the "Take Photo" page.
Hi @j--w, thanks for reporting this issue. In general, we are trying prevent users from selecting an image from the gallery because we want to enforce live captures. This implementation explicitly requests live camera images, although we are aware that Firefox still allows the user to pick a file from the camera, and that's probably the reason why Firefox fallbacks on the gallery file input while Chrome does not. Having said that, I understand that the current experience on Chrome when the users denies the native camera permissions is not ideal. I will discuss this issue with the team and try to provide a better user experience to guide the user toward taking a live photo.
Are there any updates on this issue? We had a sudden influx of tickets after Chrome 85 was released from Android users who don't appear to have been given the option to allow (or deny) access to the camera — suggesting that they may have previously denied access.
We had to disable in-browser capture because the lack of tap-to-focus resulted in blurry photos and so are reliant on "basic capture".
Hello. We've fixed this issue over the years. Can't pinpoint exactly which version, but our latest LTS (6.15.6) has the feature for camera "recovery"
See the following screens (easily reproducible by testing in incognito mode).
-
Navigate to the camera screen
-
Click block
-
The following text explains how to reenable the camera