I think it should be possible, but should be very obvious to the user when an app is doing this (and should require extra permission to be granted).
Consider that I might want to record an encounter with law enforcement on the sly, and also want to keep my phone locked to make it harder to tamper with if it's seized.
Regardless, an app like Firefox should not be doing this, or even offer it as an option. There are certainly legitimate use cases even for Firefox, but I think with a web browser there's too much possibility for abuse and security/privacy issues to make it worth it.
> I think it should be possible, but should be very obvious to the user when an app is doing this (and should require extra permission to be granted).
I disagree with the permission part, I hate how everyone's solution to any problem is to just add a toggle or another level of complexity to the app.
But the solution to the first part is easy and something that already exists all over Android. Simply have a persistent notification saying "The camera is currently active" which can't be dismissed until the camera is turned off. This is used in newer version of Android for any background task doing non-trivial work, really.
Consider that I might want to record an encounter with law enforcement on the sly, and also want to keep my phone locked to make it harder to tamper with if it's seized.
Regardless, an app like Firefox should not be doing this, or even offer it as an option. There are certainly legitimate use cases even for Firefox, but I think with a web browser there's too much possibility for abuse and security/privacy issues to make it worth it.