title: python code to generate password list
body: <p>I am researching wireless security and trying to write a python script to generate passwords, not random, but a dictionary of hex numbers.  The letters need to be capital, and it has to go from 12 characters to 20 characters.  I went from 11 f's to 20 f's, this seems like it would meet the requirements.  I then tried to place them in a text file.  After I made the file, I chmod'ed it to 777 and then clicked run.  It has been a few minutes, but I cannot tell if it is working or not.  I am running it in kali right now, on a 64 bit core i3 with 8gb of ram. I'm not sure how long it would be expected to take, but this is my code, let me know if it looks right please:</p>
  
  <pre><code># generate 10 to 32 character password list using hex numbers, 0-9 A-F
  def gen_pwd(x):
      x = range(17592186044415 -295147905179352830000)
      def toHex(dec):
          x = (dec % 16)
          digits = "0123456789ABCDEF"
          rest = dec / 16
          if (rest == 0):
              return digits[x]
          return toHex(rest) + digits[x]
  
      for x in range(x):
          print toHex(x) 
      f = open(/root/Home/sdnlnk_pwd.txt)
      print f
      value = x
      string = str(value)
      f.write(string) 
  
  gen_pwd
  </code></pre>