"));
What is this thing?

# Stop worrying about passwords

## Memorising passwords or even saving them in our browser, an application or the cloud just isn't good enough.

Master Password is a solution that voids the need to keep your passwords anywhere. Not in your head, not on your computer and not in the cloud. Nothing to store means nothing to lose. At the same time it makes sure that your accounts are adequately protected with exclusive passwords.

With Master Password, you remember one secure password and use that with the application to generate any password you might need. You could even generate PIN codes with it, if you wanted. Today, it's time to stop worrying about passwords and get on with what we need to get done.

Front page How does it work?

# What is this?

Master Password is a revolution in password management.

It aims to secure your online (and offline!) life by changing the way you deal with passwords.

# Revolution? Why would I need that?

You already know the problem:
Passwords are confidential information between you and a site. They should never be shared with anyone else, definitely not other sites. Yet that's exactly what happens with most of us: Hundereds of online accounts to manage and authenticate, we can't help but reuse one, two or five passwords that we can remember. Maybe we keep a paper stuck to our monitor with a list of passwords on them, because we realize the truth:

> It is impossible to remember a secure password for each of our accounts and still keep those passwords both exclusive and confidential.

Multiple solutions exist:
Sites that realize that passwords aren't the end-all of authentication usually implement some sort of alternative authentication mechanism: OpenID, SAML, some form of mobile authentication, secure tokens, etc.
The problem here is that these solutions only work for the select few sites that have chosen to implement them; and then you, the user, are stuck with whatever mechanism the site has chosen for you.

To solve the problem for other sites, there are programs that remember our passwords for us.
The problem with these is that they do not actually help us with setting exclusive and confidential passwords for our accounts. They just offload the work of remembering passwords, and at a great expense: If you lose your data, you lose your online identity and are locked out of everything.

# So, I guess you claim to do better?

Master Password aims to turn the tables in favor of the user, you.
In the end, what we really want is a way of dealing with passwords in an exclusive and confidential way without having to remember them, and without running the risk of losing our online identity to fraudsters.

Master Password does exactly this. You remember a single master password. Make it a long and secure one. Master Password uses this password along with the name of the site that you want to log into and generates a secure but unique password for that site. What's more, it doesn't store this information anywhere. If you lose your phone, the thieves can get none the wiser from it. You kick yourself for losing your phone, pick up any other phone, start the application, enter your master password, and instantly have access to all your passwords again. No sync, no backups, no hassle.

- Built with the highest security considerations in mind.
- Designed with beauty, elegance, simplicity and usability in mind.
- Different types of passwords can be generated to curb sites with strange password policies.
- A password counter lets you generate a new password for a site in case it gets compromised.
- Master password can be either:
  - Stored securely on the device (so you don't need to enter it anymore).
  - Not stored but remembered between sessions (so you only enter it once after powering on).
  - Not stored or remembered and required for every usage of the application (safest).
- For those cases where you cannot change your account's password, the application will encrypt passwords with your master password and store them securely (as explained, stored passwords can get lost).
- Integrates with iCloud to synchronize and back up your site history and stored passwords.
- For those that care to know, the password generation algorithm is open and documented within the application.

# OK, I'm convinced. Where do I get in?

Master Password is currently in beta.
Anyone interested in joining the beta is invited to join the Lyndir TestFlight team. Every so often new pending testers are admitted to the Master Password beta testers team.

Participation in the beta is free of charge, but does come with the expectation that you will contribute. Comment constructively, report issues and propose improvements.

Post-beta, Master Password is expected to sell for somewhere around 7 USD. The most helpful testers will receive the final version (and all future updates) free of charge.

What is this thing? View the code

# So how does it work?

The theory behind Master Password is simple. The user remembers a single, secure password. The user only ever uses that password to log into the Master Password application. This master password is then used as a seed to generate a different password based on the name of the site to generate a password for.

The result is that each master password generates its own unique sequence of passwords for any site name. Since the only input data is the master password and the site name (along with a password counter, see below), there is no need for any kind of storage to recreate a site's password. All that's needed is the correct master password and the correct algorithm implementation. What that does for you is make it almost impossible to lose your passwords. It also makes it nearly impossible for hackers to steal your online identity.

# The algorithm

Alright, let's describe the process in detail. This part will likely make sense to you only if you're well versed in computer security jargon. If you're the kind of person who likes to know how the clock ticks before deciding that it can be trusted to keep ticking, read on.

The user chooses a single master password, preferably sufficiently long to harden against brute-force attacks. When the user requests a password be generated for a site, the application composes a string consisting of the site name, the master password, and a password counter, delimited in that order by a dash character, and hashes those `UTF-8` bytes using the `SHA-1` algorithm. The bytes resulting from this hashing operation are called the `keyBytes` in the next steps.

`

                    keyBytes = sha1( site name "-" master password "-" password counter )

`

Next, we need the password type that the user has chosen to use for the site. Password types determine the cipher that will be used to encrypt `keyBytes` into a readable password. For instance, the standard password type Long Password activates one of three pre-set ciphers: `CvcvCvcvnoCvcv`, `CvcvnoCvcvCvcv` or `CvcvCvcvCvcvno`. Which of those will be used, depends on the first of the `keyBytes`. Take the byte value modulo the amount of pre-set ciphers (in this case, three), and the result tells you which of the three ciphers to use.

`

                    ciphers = [ "CvcvCvcvnoCvcv", "CvcvnoCvcvCvcv", "CvcvCvcvCvcvno" ]
                    cipher  = ciphers[ keyBytes[0] % count( ciphers ) ]

`

Now that we know what cipher to use for building our final password, all that's left is to iterate the cipher, and produce a character of password output for each step. When you iterate the cipher (`i`), every character in the cipher represents a set of possible output characters (`passChars`). For instance, a `C` character in the cipher indicates that we need to choose a capital consonant character. An `o` character in the cipher indicates that we need to choose an other (symbol) character. Exactly which character to choose in that set for the password output depends on the next byte from `keyBytes`. Like before, take the next unused `keyByte`'s byte value modulo the amount of characters in the set of possible output characters for the cipher iteration and use the result to choose the output character (`passChar`). Repeat until you've iterated the whole cipher.

`

                    passChar  = passChars[ keyBytes[i + 1] % count( passChars ) ]
                    passWord += passChar

`