liuch/dmarc-srg

Ip address I wrong in reports.

Closed this issue · 4 comments

Is that me only who facing the issue that unpacked IP address is different from the one in the xml report?
In my case first part of the IP is wrong.

When I do print inet_ntop(inet_pton('165.223.228.22')); - it return 165.223.228.22.

But when it comes to Report web UI -the first part of the IP (165) is different.

I tried to decode the value store in MYSQL with inet_ntop - got the same error. So probably it something on my side? Using Mariadb 10.4.

I created a report file with your IP address and uploaded it to my environment. Both the report list and the WebUI report shows the correct IP value. It looks like the problem is on your side.

$ mariadb --version
mariadb  Ver 15.1 Distrib 10.11.6-MariaDB, for debian-linux-gnu (x86_64) using  EditLine wrapper

$ echo "describe rptrecords" | mariadb -udmarc_user -p dmarc | grep "ip"
Enter password: 
ip	varbinary(16)	NO	MUL	NULL

Maybe your version of MariaDB has a problem with BLOBs. Unfortunately I have no other idea what the problem is.

p.s. If the IP address you provided is just an example, you can email the real address to me so I can check it, just in case.

I use ddev for that installation.
And the IP I shared is not the one I have problems with.

The problem was for at least 2 other IPs I don't want to share.

Anyway, what is it the reason converting the ip to blob and then back? Database size?
I removed that conversion, changed the DB schema and now it works fine for me.

The cause could have been clipping the value of the blob field in the database.

Anyway, what is it the reason converting the ip to blob and then back? Database size?

This solution was used to be able to sort by this field.

This solution was used to be able to sort by this field.

Ah, ok. Not really important for me.
What might be important is filter by specific IP.
I believe there was some feature request for that.

Ok, about the main issue - if it is only me experiencing it - then i think we can close the issue.