Why not use the pattern directly?
Human gestures come from a much smaller and more predictable space than random encryption keys. A derivation function combines the entered pattern with a unique salt and configured work parameters. The output participates in unlocking protected key material; the pattern itself is not used as a permanent file key.
Example: An attacker testing 10,000 likely patterns should have to pay the configured Argon2id memory and computation cost for every candidate. A legitimate user pays that cost once when unlocking. A simple corner-to-corner line is still a poor choice because it may appear early in the attacker’s guess list.
What “memory-hard” contributes
Specialized guessing hardware excels when millions of independent guesses are cheap. Requiring meaningful memory per guess raises the resource cost and limits parallelism. Parameters must still be tuned for the actual phone: too low weakens resistance; too high causes unusable delays or memory pressure.
Salt is not a secret
A unique random salt prevents the same pattern from producing the same derived output across vaults or installations. The salt can be stored with the encrypted record. Its job is uniqueness, not secrecy.
Pattern strength still matters
Avoid simple letters, straight lines, repeated shapes, birthdays translated into positions, and patterns someone has watched you draw. Use a longer shape that is memorable to you but not a common motif. Keep recovery material separately; do not turn the recovery phrase into a note inside the vault it must recover.
See how to choose a strong vault pattern for a practical method.
Technical reference
RFC 9106 describes Argon2 and its Argon2id variant, including its hybrid approach to side-channel and tradeoff resistance. The presence of Argon2id is not by itself proof of a secure product; parameters, key separation, storage, and failure handling matter too.
Guide reviewed: 28 August 2026.