Re:Stop putting AUTO_INCREMENT ids in URLs
by mnw21cam on Wednesday November 05, 2014 @07:39AM
(#8561504)
You don't have to have a massive random number - just one long enough to fulfil your goal. You then ensure uniqueness using your database. If your goal is just to allow sufficient addressability, then the random number needs to have enough bits to cover the maximum number of items you can ever conceive of creating. If your goal is to prevent people from typing in a random number and getting a valid page, you need to multiply your address space by 1/(acceptable probability of guessing).
Having two levels of random number is unnecessary - you should be able to access a job/operation combination with a single identifier.
Having two levels of random number is unnecessary - you should be able to access a job/operation combination with a single identifier.