title: Calculating entropy for user- and random passwords
body: <p>When calculating entropy for user passwords, what is the standard method used? It almost seems as if everybody has his or her own opinions on what to use. Some reference xkcd, other people mention NITH and Shannon.</p>
  
  <p>Say I want to calculate the entropy of the top-10 passwords in the Rockyou leak, what I should use. The majority of the Rockyou passwords are not randomly generated.</p>
  
  <p>If I wanted to calculate the entropy of randomly generated passwords, such as those generated from resetting your password on websites, often 4-6 characters long, with only a-z, A-Z characters.</p>
  
  <p>Are there any Python implementations of whatever recommended method recommended for these scenarios?</p>