Andrometiq

Passkeys for Frappe · A plain-language guide

Why passkeys are safer — and when they aren't

A passkey signs you in with your fingerprint, your face or your screen lock. There is no password to type, remember or leak.

It is the rare security upgrade that also makes signing in easier. This guide shows what it fixes, and the few things it doesn't, so you can decide with your eyes open.

What it is

A passkey replaces your password with a key on your device

You unlock it the way you already unlock your phone: fingerprint, face or PIN. That is the whole experience.

Underneath, a passkey is a pair of keys. The split between them is the point.

  • The private key never reaches the site. Signing in proves you hold it, without ever sending it. Where it lives is up to your device and provider: a security key keeps it in dedicated hardware, most phones and laptops use a Secure Enclave or TPM, and a synced passkey travels only through your provider's end-to-end encrypted sync (or a share you choose to make).
  • Your fingerprint or PIN unlocks that key on the device. It is never sent to the site either. The site learns only that a real person unlocked this device.
  • The site keeps only the matching public key. It is safe to leak.

So one touch proves two things at once: you have the device, and a person is present. Neither secret ever reaches the site.

NOTHING SECRET CROSSES Your device The site Secure hardware Private key never sent Fingerprint / PIN never sent Signature only Public key safe to leak can't sign anyone in
Your device Secure hardware Private key never sent Fingerprint / PIN never sent NOTHING SECRET CROSSES Signature only The site Public key safe to leak can't sign anyone in

In short The secret never reaches the server, which holds only a public key that is useless to steal.

Why it's safer

Passwords get stolen two ways. Passkeys close both.

Phishing: nothing to type means nothing to hand over. A passkey is tied to the real site it was made for. Your browser offers it only on that site, and the site checks where every sign-in came from.

On a lookalike page the passkey is never offered, so the attacker cannot even ask for it.

A password or a one-time code is different. You can type it into any page, and a convincing fake will take it. That is the big one, because “two-factor” codes are no exception: SMS codes, authenticator apps and “Approve?” taps are all things a fooled user can hand to the wrong site.

Breaches: the passkey leaves nothing worth stealing. For each passkey the server keeps only a public key, and a public key cannot sign anyone in. The passkey itself gives an attacker nothing to crack. If the account ever had a password, its hash stays on the server: passkey-only stops that password from signing in but does not delete it.

Each passkey is also unique to one site. A leak at one place is worthless everywhere else, so the password reuse that powers “credential stuffing” is gone.

PHISHING Password typed examp1e.com Password stolen Fake site Passkey Never offered to the fake example.com Allowed BREACH Database dump Password hashes leak Can be cracked → reused elsewhere Public keys leak Cannot sign in · useless to a thief
PHISHING FAKE SITE Password examp1e.com Password stolen Passkey Never offered to the fake example.com Allowed: the real site BREACH Database dump Password hashes leak cracked, reused elsewhere Public keys leak can't sign anyone in

Here is where the common sign-in methods sit. One hard line divides them. Below it, you hand over something an attacker can catch and reuse. Above it, your device signs a one-time challenge and hands over nothing.

Strongest at top

  1. Passkeyfingerprint / face + device keyNot phishable
  2. Hardware security keya device you tapNot phishable
  3. Push approval (“Approve?”)the tap can't tell which site askedPhishable
  4. Authenticator app codea code you retypePhishable
  5. SMS / email OTPa code you retypePhishable
  6. Password / PINa secret you type, and reusePhishable
The verdict column is the whole game. Below the line, every method hands over something typeable or tappable that a fake site can catch and reuse.

In short A fake site can't even ask for your passkey. From a server breach, a passkey leaks only its public half, which is worthless to an attacker.

The intuition-buster

So why does my bank pile on hoops, and Google doesn't?

Your bank may ask for an OTP, a card PIN and a security question, and it still feels fragile. Google asks for a single glance, and it feels bulletproof.

Google isn't being careless. The lesson is that friction is not the same thing as security.

Why banks show visible hoops

Mostly, the hoops are not a security choice. Regulation requires them: the EU's PSD2 and India's RBI both require two factors for payments. They also shift fraud liability, and decades-old systems and auditors favour a visible, logged code.

The irony is that the factor banks most often chose, the SMS OTP, is itself phishable. The RBI says it never mandated SMS in particular, and it now allows other factors, including phishing-resistant ones.

Why Google feels effortless, yet is safer

Google didn't skip authentication. It moved the work into the background, on top of a passkey.

A risk engine quietly scores each sign-in on device, location and behaviour, and interrupts you only when something looks off. The strong factor is still there. It just doesn't make you type anything.

More hoops ≠ more security Your bank Google Visible hoops SMS OTP Card PIN Security question SMS: phishable One glance Device-bound key Not phishable Background risk engine Device · IP / location Behaviour · bots · reputation Challenge only at high risk
More hoops ≠ more security Your bank visible hoops SMS OTPCard PINSecurity question SMS: phishable Google One glance Device-bound key Not phishable Background risk engine Device · IP / location Behaviour · bots · reputation Challenge only at high risk

The evidence is plain. Google made security keys mandatory for its more than 85,000 employees in early 2017, and by mid-2018 it reported no phishing takeovers of their work accounts. Google also found that signing in with a security key took about half the time of an SMS code.

The keys also cut Google's support costs. Security and convenience were never the same lever. Better authentication gives you both.

In short Friction is a poor proxy for security. Passkeys give your users less friction and more safety at the same time.

For payments

A recommended pattern for approving payments

Payments often need two factors. You can meet that without an SMS code: pair the passkey with a short transaction PIN, in this order.

  1. Confirm the payment with a passkey. Your app shows the amount and payee, and the user approves this exact payment with their passkey. The app's @passkey_protected confirmation is single-use, expires in about three minutes, and is bound to the action and to the values you choose to bind, such as the amount and the payee. It cannot be used on a look-alike site.
  2. Only then, ask for a transaction PIN. In the same flow, and only after the passkey step succeeds, ask for a 4–6 digit PIN. Your server checks it against the same confirmed payment, limits attempts and locks after a few wrong tries. The PIN is never asked for anywhere else, so a PIN leaked on its own opens nothing.
STEP 1 Passkey confirms this payment: amount and payee ✓ STEP 2 Transaction PIN checked by the server ✓ Payment released A PIN on its own is never asked for no way in step 2 needs step 1 first
STEP 1 Passkey confirms this payment: amount and payee ✓ STEP 2 Transaction PIN checked by the server ✓ Payment released A PIN on its own is never asked for: step 2 needs step 1 first

It is the same idea as UPI: something you have (there, your phone and SIM; here, the passkey on your device) plus something you know (the UPI PIN; here, the transaction PIN). The passkey unlock often already uses the device's own PIN or biometric. The transaction PIN adds a second secret that your server holds and checks, not the device.

Compared with an SMS OTP it is safer and more dependable. There is no SMS code to phish or relay, since the passkey sends nothing an attacker can reuse. There is also no waiting on an SMS that arrives late or not at all.

This is a pattern your site or app builds. The passkeys app provides the confirmation step; showing the amount and payee, storing and checking the PIN, the attempt limit and the lockout are your code. Meeting the payment rules that apply to you stays your responsibility.

In short Passkey first, then a PIN, for the same payment. Two factors, no SMS, and a PIN that is useless on its own.

When they aren't enough

What passkeys don't fix

Passkeys do one thing superbly: they make the login itself phishing-resistant. They leave real gaps elsewhere.

If you are deciding whether to turn them on, plan around these three.

  1. Someone can unlock the device

    Anyone who can pass the phone's unlock check, by knowing the PIN or getting past Face ID, can use the passkeys on it. The passkey trusts that local unlock.

  2. A weak recovery back door

    An email link, an SMS code or an old password left switched on lets an attacker skip the passkey entirely. Passkeys stop phishing; a flimsy fallback quietly undoes it.

  3. A hijacked cloud account

    Synced passkeys live in an Apple, Google or Microsoft account, end-to-end encrypted. If that account itself is taken over, its own security is what protects the keys.

In short Passkeys make the front door very hard to pick. Close the side doors too: disable weak recovery fallbacks, and keep a second factor where it counts.

For your Frappe site

Turning this on

Adding passkeys to a Frappe site means choosing the same model as Google. Sign-in becomes phishing-resistant by construction, and lighter for users than the password it replaces.

For each passkey the server stores only a public key, which is safe to leak. A password the account still has keeps its hash on the server.

  1. Turn on a passkey login mode. Every mode ships off. Choose passwordless login, a passkey as the second factor after a password, or both. Enrol and test a passkey (and a backup) for each user, and arrange recovery before closing the other ways in.
  2. Close the side doors. The Passkey Settings page lists the ways a stock Frappe site still lets a user sign in without a passkey, such as password login, social sign-in and email links, so you can close them. Review any custom sign-in your own apps add separately. Switch off “Allow OTP Fallback for Passkey Second Factor” too; it is on by default.
  3. Keep a second factor where it counts. Keep one wherever a regulator or a sensitive action calls for it. Developers can also require a fresh, single-use passkey confirmation before a sensitive action runs.

Do that, and the login is both stronger and easier. It is the rare change that costs your users nothing.

The app is open source (MIT): read the install guide and the security model, or browse the project on GitHub.

In short Adding passkeys means choosing phishing resistance by construction, and handing users something faster than the password it replaces.

From Andrometiq

Passkeys for your Frappe site

We built Frappe Passkey for our own ERPNext, where our bank transactions run. It adds passkey sign-in, as the only login or as a second factor, and a fresh passkey confirmation before a sensitive action runs. It is free and open source under the MIT licence.

See Frappe Passkey →

Sources & further reading

Where this comes from

A short, illustrated explainer of passkey security for anyone weighing them up. Illustrations are inline SVG. The page reads in light or dark.

Talk to us

Bring us a hard problem.

We took the time to understand passkey security, then wrote it down in plain language. That is how we usually work. If you want a problem solved with the same care, get in touch.

build 22