Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Integrating Password Manager Into iPhone App

I've noticed a few iPhone apps have started to allow you to use your password manager to sign in. Slack is an example of this:

Slack login

Slack password manager

It looks like there's a link that's triggering a partial version of the share toolbar in Safari which lets you access your favourite password manager's widget. That's all I've been able to figure out so far though.

My question is, how have they got this functionality into their app? I'm primarily developing things using React Native, but if it needs a custom component then that's not a problem.

like image 223
edcs Avatar asked Mar 13 '23 09:03

edcs


1 Answers

This is now supported natively by iOS 12+ (and by react-native 0.60+) without the need for an extension.

  • Documentation for enabling it on iOS is located here on Apple's site. TLDR is to set the UITextContentType values of .username and .password for your inputs and, optionally, add an associated domain entitlement so your app can share passwords with your website.

  • The prop for enabling it in React Native is documented here. TLDR there is to provide an autoCompleteType on your TextInput component. The two OSes should handle that properly, though again you will have to add an associated domain if you want to share passwords between your website and app.

like image 114
Zack Avatar answered Mar 30 '23 18:03

Zack