sbyx / hnetd

HomeNet-CP implementation (WIP)
Apache License 2.0
39 stars 16 forks source link

New PA code + pseudorandom = not win #33

Closed fingon closed 9 years ago

fingon commented 9 years ago

(IRC log)

10.32 pseudorandom does not seem to work that well with AA etc 10.33 given it has 128 candidates, and it is trying to pick random address from /64 that hits it.. 10.33 odds of a hit are 1/2^57 10.33 oryon: any idea how to fix that? ;) 10.34 I suspect same problem might crop up with also normal prefixes, if ISP gives e.g. /48 and you try to allocate a /64 10.35 odds of a pseudorandom hit are 1/2^(64-48-7) 10.35 hrm, that's just 1 in 512, not so bad

fingon commented 9 years ago

Hamming distance stuff fixes this one.