5 ms·
CPython has the unfortunate property that ints aren’t covered by hash randomization, and `hash(x) == x % ((1 << 61) - 1)` always.
by minitech 6d ago
CPython has the unfortunate property that ints aren’t covered by hash randomization, and `hash(x) == x % ((1 << 61) - 1)` always.
- progval 6d agoOuch, that's a big footgun. Why was the lack of randomization considered a vulnerability, but not this?