android-9.0-pie

Android KeyStore with StrongBox: How to test for User Presence?

旧城冷巷雨未停 提交于 2021-01-27 12:50:59
问题 Android API 28 running on a Pixel 3 gives the option to require User Presence for keys generated inside the Android KeyStore. But how do I actually test for user presence when creating a signature with that key? Am I missing something in the docs? KeyGenParameterSpec.Builder keyGenSpec = new KeyGenParameterSpec.Builder("alias", KeyProperties.PURPOSE_SIGN) .setDigests(KeyProperties.DIGEST_SHA256) .setKeySize(256) .setIsStrongBoxBacked(true) .setUserPresenceRequired(true); KeyPairGenerator

Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE TYPE_MEDIA_PROJECTION in Android Pie and Q

こ雲淡風輕ζ 提交于 2020-11-28 08:30:04
问题 any body knows why this error occur, Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION on getMediaProjection() even i call getMediaProjection() method after calling startforeground() method..! Stack Trace is : Process: com.al1.screenrecorder, PID: 24641 java.lang.RuntimeException: Unable to start service com.al1.screenrecorder.service.DisplayRecorderService@9ef2101 with Intent { cmp=com.al1.screenrecorder/.service

Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE TYPE_MEDIA_PROJECTION in Android Pie and Q

社会主义新天地 提交于 2020-11-28 08:29:04
问题 any body knows why this error occur, Media projections require a foreground service of type ServiceInfo.FOREGROUND_SERVICE_TYPE_MEDIA_PROJECTION on getMediaProjection() even i call getMediaProjection() method after calling startforeground() method..! Stack Trace is : Process: com.al1.screenrecorder, PID: 24641 java.lang.RuntimeException: Unable to start service com.al1.screenrecorder.service.DisplayRecorderService@9ef2101 with Intent { cmp=com.al1.screenrecorder/.service