Experienced an odd situation running Authen::Captcha with mod_perl. Authen::Captcha generates images containing a random sequence of letters, somewhat obfuscated to foil OCR. I ran into a problem running it under mod_perl, where rand() was being seeded at compile time (before Apache pre-forks all its children), and each perl interpreter had the same seed, and thus the same "random" sequences would be generated over and over. Authen::Captcha has some code that immediately deletes a captcha image that it thinks is a duplicate of one it already created, and thus I was getting 404s some of the time when I refreshed the page containing the captcha. The solution: call srand() once at runtime. Then all the interpreters have a different seed and the chance of a collision drops to near zero.