0

attempting to run the saferoom demo running against an emulator defined as Pie (API 28). using android studio 3.4 on a Lenovo Windows 10 Professional system. sdk for API 28 is being used.

At open the app shows the message "You do not have a secure keyguard!" as a long toast on the emulated screen.

How is this corrected?

no change to the code from Github clone.

JWDurbin
  • 11
  • 4
  • "At open the app shows the message "You do not have a secure keyguard!" as a long toast on the emulated screen" -- the sample app happens to use the `AndroidKeyStore` for storing a generated database passphrase. That, in turn, requires a secure keyguard to work. "How is this corrected?" -- set a secure keyguard on your test device. Or, don't run the sample. – CommonsWare May 29 '19 at 10:46

1 Answers1

0

resolved by opening settings in the emulator and setting a pin number for log on to the emulator. However - each time the emulator is restarted, the settings need to be changed again. Maybe there is a way to control this in code or some setting in android studio?

What I meant by "the settings need to be changed again" was a mistake. Once set up with a pin, the emulator does retain the pin across restarts. The app itself asks for the pin. Apparently pin, password, or fingerprint must be set up through the settings app in the emulator at least once in order for the emulator to have a secure keyguard. for my app, requesting the pin at startup is a good thing.

Thanks for the question. it helped clarify things for me.

JWDurbin
  • 11
  • 4
  • I do not know what "the settings need to be changed again" means. I do not often use the emulator, but I have not had problems with a secure keyguard on an emulator. – CommonsWare May 29 '19 at 10:46