Use native password manager


Use native password manager



Is it possible to use (with Codename One) the native password manager to store or to get the user password?



My use case: see this screenshot of the iOS Teachable app, in the virtual keyboard there is a key icon to access the iPhone password manager (that uses the FaceID in the case of iPhone X). I know how to do a login form using a TextModeLayout, but I don’t know how to get this navite password management functionality.



teachable login screen





Why the massive screenshot?
– Joakim Danielson
Jun 30 at 7:24





Why the two downvotes? I see the screenshot fits in the device screen. I’m using the StackOverflow app on iPhone and the screenshot is taken in the same device. It looks fine on the device, I’ll resize it (if it’s appear too big) when I will have access to my computer.
– Francesco Galgani
Jun 30 at 7:30





Downvotes, read up on how to ask a question in the help section. This kind of "How to do it" with very little own research is not considered a well written question here at SO.
– Joakim Danielson
Jun 30 at 7:51





Very little own research??? I tried to find this functionality in the Codename One API and I didn’t find it, I read a lot of times the TextModeLayout documentation. I don’t know if this functionality exists and if it’s portable, that why I’m asking. It’s a legal coding question.
– Francesco Galgani
Jun 30 at 7:57





I think people downvoted because they read the word iOS and missed the fact that it's Codename One so they thought you didn't do research.
– Shai Almog
Jul 1 at 4:08




1 Answer
1



We don't support that right now but it should be pretty easy to add based on this: https://medium.com/@abhimuralidharan/password-autofill-for-ios-apps-for-faster-login-ios-11-1d9f77deb35a



We can do that seamlessly for password fields but we'll probably need a new bit type for the username field. Ideally we should also have field types for all the properties so form auto-fill will work correctly.



We'll probably also need a build hint to set the app domain so the password manager will associate your app with the right domain. I'm not sure if we'll get to it in this release as we have a lot on our plate and summer months are rough but you can file an RFE and we'll get to it.



As a short term workaround you can use this: https://github.com/codenameone/FingerprintScanner/ to authenticate using touch ID and possibly face id (haven't tested it yet as we built this cn1lib before face id was around).






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Render GeoTiff to on browser with leaflet

How to get chrome logged in user's email id through website

using states in a react-navigation without redux