1

I'm trying to get my camera app to launch from a password protected lock screen. I've added the following intent filter to allow the app to appear as an option for the lock screen shortcut:

<intent-filter>
            <action android:name="android.media.action.IMAGE_CAPTURE_SECURE" />
            <category android:name="android.intent.category.DEFAULT" />
</intent-filter>

However, when launching the app from the lock screen I get the following exception: java.lang.SecurityException: Lacking privileges to access camera service

I already have <uses-permission android:name="android.permission.CAMERA" /> declared in the manifest, and the app runs just fine otherwise.

Any insight into this would be much appreciated. Thank you!

Edit: I can successfully launch the app as a lock screen short when the lock screen is not password protected. Once it's password-locked though, I get the java.lang.SecurityException: Lacking privileges to access camera service exception.

For some reason SO is not letting me paste my manifest, so here's a link to the code: http://pastebin.com/F5kk9HrT

Eddie Kezeli
  • 61
  • 1
  • 6
  • You have checked all answers here: http://stackoverflow.com/questions/7829162/failed-to-connect-to-camera-service ? – Sebastian Roth Dec 07 '15 at 02:08
  • Yes, I have everything declared properly in the manifest. I can successfully launch the app as a lock screen short when the lock screen is not password protected. Once it's password-locked though, I get the `java.lang.SecurityException: Lacking privileges to access camera service` exception. – Eddie Kezeli Dec 07 '15 at 07:29
  • Can you post the full `AndroidManifest.xml`? – Sebastian Roth Dec 07 '15 at 07:47
  • For some reason SO is not handling the manifest, so I pasted it here: http://pastebin.com/F5kk9HrT – Eddie Kezeli Dec 07 '15 at 09:24

0 Answers0