This isn't actually a bug in aggregate -- the problem is that your sort keys don't include the prefix length field, so sort -u is throwing away lines that aren't actually redundant. For example:
$ cat >simple.txt 203.86.64.0/20 203.86.64.0/19 $ sort -u -t . -k 1,1n -k 2,2n -k 3,3n -k 4,4n simple.txt 203.86.64.0/20 (And obviously aggregate will produce different output for the /19 vs. the /20.) If you remove the -u option, then aggregate will process your sample file correctly: $ wget http://web.archive.org/web/20141220181537/https://dl.dropboxusercontent.com/u/108553/blacklist.txt $ cat blacklist.txt | ./aggregate -t 2>/dev/null | md5sum - 45b4ce32ffcf5df0f15409c92c5450c0 - $ sort -t . -k 1,1n -k 2,2n -k 3,3n -k 4,4n blacklist.txt | ./aggregate -t 2>/dev/null | md5sum - 45b4ce32ffcf5df0f15409c92c5450c0 -