Friday, February 8, 2013

Password programming for beginners (Part 2)

Password programming for beginners (Part 2)

The power of a password depends to begin with the number of possibilities. Say that we must guess a number from 0 to 9. You understand that you have a 10 chance of finding the answer since you have 10 possible combinations. If you guess a letter of the alphabet, you have a chance of 26 to find the answer because there are 26 letters in the alphabet. Now, if you have to guess a number or a letter of the alphabet it is in uppercase or lowercase, your chances of finding the answer will be the sum of the possibilities.

10 + 26 + 26 = 62
10 values

The main strength of a computer is the ability to produce a very large number of operations per second without getting tired. A human is exhausted after a sustained effort. While a human will take some time to find the answer, the machine will only take a small fraction of seconds to try all possible combinations. If you try the example program, you would notice that it is really fast.
62 values

With little program that I developed, we find that it takes a hundredth of second to go through all possible results. It is very fast and we can say that can not really do better. Why? Because it is very straightforward, too simple. At the limit, one could ask the program to not try the other options if the equation is solved. Equality could be found at the beginning of the list of possibilities and it can also be the final results. On average, statistically speaking we can say that it can take up half the time.

In the next article, I will increase the number of combinations for passwords longer. By adding options next to each other, we multiply the possibilities to make the password more secure.

sample program

Download the sample project  :

Read the Next Post : The complexity of a password

Read the previous post of this article in English, French, German, Spanish and Chinese

No comments:

Post a Comment