Calculate position in password search

255 Views Asked by At

I'm running a password cracker on my own password and I'm trying to calculate how long it will take. I know the rate the software is checking at and I also know the password.

The password is $14$ characters long and is all lower case. Thus the total number of possibilities is $26$ to the $14$th power, which works out to $64,509,974,703,297,200,000$ according to Excel.

Let's assume the password is: fakepassokayab. The algorithm will start with $14$ character long passwords, so it will begin with

aaaaaaaaaaaaaa
aaaaaaaaaaaaab

etc, until it reaches

zzzzzzzzzzzzzz

Once it finds the matching password, it will stop and display it.

Two questions:

  • To calculate the position of the password in the entire sequence, I figured it would be the factoral of every letter's position in the alphabet, so that if the fake password is fakepassokayab, that would be $6\times1\times11\times5\times16\times1\times19\times19\times15\times11\times1\times25\times2$, or $15,725,160,000$. Is this correct? Since there are some 1s in there, it seems like those positions wouldn't be counted correctly

  • Currently the password cracker is at $182.629,132$. How can I calculate which position this is, given that it will run in alphabetical order and use all 26 letters?

If I need to provide additional information please ask me rather than mark this as a negative. I'm new to this part of Stack Exchange.

1

There are 1 best solutions below

4
On BEST ANSWER

1) What you are actually asking is what is this base 26 number in decimal form. Letting $a\rightarrow 0$, $b\rightarrow 1$,..., $z\rightarrow 25$, then "fakepassokayab" in base 26 is the number

$$ 5,0,10,4,15,0,18,18,14,10,0,24,0,1. $$ Which in decimals is $$ 1 + 24\times26^{2} +10\times26^{4} +...+5\times26^{13} = 12,443,114,072,130,351,169. $$

2) To calculate what word a corresponding position is then convert your position to base 26 and then use the alphabet relations above.

Note The way I knew your answer was wrong was the word faaaaaaaaaaaaa is (very) approximately $\frac{1}{4}$ of the way through all the possible combinations and it is close to our password. But $\frac{1}{4}$ of the way through our combinations is $\approx 16,000,000,000,000,000,000$ which isn't close to your answer.