

Generate Secure Random Strings and Integers in PHP - paragon_init
https://paragonie.com/blog/2015/07/how-safely-generate-random-strings-and-integers-in-php?resubmit=1

======
switch007
Sometimes, programming Python just feels like cheating:

    
    
      from random import SystemRandom
      import string
      num = SystemRandom().randint(...)
      pw = ''.join(SystemRandom().choice(
        string.ascii_uppercase + string.digits) for _ in range(26))

