Here’s a script, which I just posted to the Revolution forum. I post it on my blog, because I like the script and it might be useful to many people. It should also be simple to translate this to PHP for instance.
This script generates passwords with length theLength, choosing consonents and vowels semi-randomly such as to keep the password speakable. This function allows for double consonants while still keeping the password speakable.
function speakablePassword theLength
put “bcdfghjklmnprstwyz” into myConsonants
put “aeiou” into myVowels
put “” into myPass
repeat myPasswordLength
if char -1 of myPass is in myConsonants then
if char -2 of myPass is in myConsonants or
length(myPass = 9) then
put any char of myVowels after myPass
else
if any item of “true,false” then
put any char of myVowels after myPass
else
put any char of myConsonants after myPass
end if
end if
else
put any char of myConsonants after myPass
end if
end repeat
return myPass
end speakablePassword
Posterous can’t handle unix. Please figure out line feeds yourself for now. Will edit later.
I fixed the problem with unix line endings.