<div class="gmail_quote"><div>+1 to option d (host-based salt) but would need to consistently order the hostnames/addresses to guarantee that all processes on the same machine got the same salt by default.</div><div><br></div>
<div>+1 to option c (environment variable) as an override. And/or maybe an override on the command line.</div><div><br></div><div>+1 to implementing the salt in the dictionary hash as an additive value.</div><div><br></div>
<div>+0 to exposing the salt as a constant (3.3+ only) - or alternatively expose a hash function that just takes an existing hash and returns the salted hash. That would make it very easy for anything that wanted a salted hash to get one.</div>
<div><br></div><div>For choosing the default salt, I think something like:</div><div><br></div><div><div>a. If IPv6 is enabled, take the link-local address of the interface with the default route. Pretty much guaranteed not to change, can&#39;t be determined externally (salting doesn&#39;t need a secret, but it doesn&#39;t hurt), large number so probably a good salt. (If it is likely to change, a salt override should be being used instead). Don&#39;t use any other IPv6 address. In particular, never use a &quot;temporary&quot; IPv6&quot; address like Windows assigns - multiprocessing could end up with instances with different salts.</div>
<div><br></div><div>b. Take the FQDN of the machine.</div></div><div><br></div><div>Tim Delaney</div></div>