iprange icon indicating copy to clipboard operation
iprange copied to clipboard

Bug: Gives warning and ends up with duplicate IPs in output...

Open Jas0n99 opened this issue 5 years ago • 0 comments

This is probably an edge case, but I figured still worth reporting...

I'm attaching a file combined.txt

which is a concatenation of the cymru full bogons & cidr-report bogons lists.

When you run the command iprange -v combined.txt > combined.ipset.txt

It gives the warning: iprange: WARNING: invalid range reversed start=224.0.0.0 end=0.255.255.255

.. and the end file combined.ipset.txt has loads of duplicate IPs (CIDRs) in it. If you also look at line 3073 you will see it wrote 224.0.0.0 with no CIDR. So I'm guessing the bug is something to do with the next few entries in the original file that bork the processing and it just dumps the rest of the input to output. (There was already a 0.0.0.0/8 at the beginning of the file, the one in the sample below would be the start of the 2nd concatenated file).

224.0.0.0/4
240.0.0.0/4
0.0.0.0/8

If you process them as individual files then it works just fine, ex: iprange -v cymru_full.netset cidr-report.netset > this_works.ipset

Hopefully it's an easy fix... lol

Jas0n99 avatar Sep 09 '19 22:09 Jas0n99