Yes i solved a problem this way. I was trying to figure out how to generate a password that would always pass complexity requirements without reducing the entropy.

I woke up that night with the simple solution immediately top of mind…

just a loop that generates a random password, then tests it for complexity. If it doesn’t meet complexity requirements, loop again. If complexity test succeeds, return that as the generated password. (And a max loop count to avoid infinite loop conditions, of course.)

Reply to this note

Please Login to reply.

Discussion

No replies yet.