Assuming computing power of the attacker can be expressed exponentially over time:
p = a·ebt
where t is time (t = 0 when the attacker starts trying passwords), a and b are two constants, and p is a measure of power expressed in "password tries per time unit", then the size of the space of passwords explored by the attacker over time period T is:
Moore's law more or less means that the exponential-based formula is a valid model -- within some limits. An optimistic expression of Moore's law is that, over the course of three years, transistor density has quadrupled and clocking frequency has doubled at constant budget: for the same cost, we have four times as many transistors and we can run the circuit twice faster. This would mean that b = 0.693 inverse years (logarithm of 2: power doubles every year; we express time t in years) and a is the number of passwords that the attacker can try right now with his yearly budget (say, a = 3×1017 passwords/year if the attacker begins at 10 billions per second, as would be the case for a simple salted MD5 hash and a few thousands of dollars of budget).
The calculation above assumes the following properties, which are not very realistic:
- The attacker has a renewable yearly budget, allowing him to perform regular hardware updates.
- Conversion from old to new hardware costs nothing, which is akin to declaring that software grows on tree and you just have to walk below the branches with a basket.
- The attacker can follow Moore's law. Password cracking is highly parallel, but this will still need to play with FPGA. Consumer products like CPU or GPU have other constraints which prevent them from obtaining the full power of Moore's law (in particular, memory latency does not scale as well).
- Moore's law holds. Gordon Moore himself, back in 1997, gave it about 20 more years before falling apart, i.e. until about year 2017 -- which is only four years away. Moore's law operates on the gradual application of a stock of optimization ideas which have been expressed, at least theoretically, in the 1970s. That stock is fast running out... and, indeed, we can see that clocking frequency in circuits (even ASIC) has somewhat stalled below 10 GHz.
- We can ignore energy consumption. We now know that this is not true. Energy is now a major constraint on big computations (not only for feeding the machines, but also for cooling, because all that energy becomes heat). It is also the closest boundary on theoretical computing powertheoretical computing power.
Therefore, while you can use a formula like the one I showed above, the results you will get out of it will not be very practical. I would like to add that if the attacker is sufficiently intent on spending hardware on a yearly basis in order to crack your password, then that guy is indeed your arch enemy; it won't be long before he realizes that hiring two or three thugs to break your kneecaps is vastly cheaper and more effective.