thinkst / canarytokens

Canarytokens helps track activity and actions on your network.
http://canarytokens.org
Other
1.75k stars 258 forks source link

ipinfo missing auth #145

Closed JStyle21 closed 1 year ago

JStyle21 commented 2 years ago

Hi,

I've registered with ipinfo and provided the token via settings as per design, when i go to manage a canary token i can see in the map a missing auth response even tho it was provided.

I've tested the settings and the ipinfo python code manually on the running docker container and i can see it's working fine, no idea what's causing the map issue.

Map example

From the container:

>>> resp = requests.get('http://ipinfo.io/' + ip + '/json')
>>> print(resp.json())
{u'loc': u'39.0437,-77.4875', u'city': u'Ashburn', u'country': u'US', u'region': u'Virginia', u'hostname': u'ec2-184-72-122-29.compute-1.amazonaws.com', u'timezone': u'America/New_York', u'ip': u'184.72.122.29', u'readme': u'https://ipinfo.io/missingauth', u'org': u'AS14618 Amazon.com, Inc.'}

>>> resp = requests.get('http://ipinfo.io/'+ip+'/json/', auth=(settings.IPINFO_API_KEY,''))
>>> print(resp.json())
{u'loc': u'39.0437,-77.4875', u'city': u'Ashburn', u'country': u'US', u'region': u'Virginia', u'hostname': u'ec2-184-72-122-29.compute-1.amazonaws.com', u'timezone': u'America/New_York', u'ip': u'184.72.122.29', u'org': u'AS14618 Amazon.com, Inc.'}

>>> print(resp.status_code)
200
jayjb commented 2 years ago

Hi @JStyle21,

Sorry for the delay. There is work being done on the side to get Canarytokens to python3, so that has been the focus.

Please can you confirm that you added CANARY_IPINFO_API_KEY=<api key> to switchboard.env?

JStyle21 commented 2 years ago

It's ok @jayjb i understand.

Yes, confirmed, the api key is set in switchboard.env

Any ideas how to further debug this?

jayjb commented 1 year ago

Hi @JStyle21,

Sorry for the delay here. We have made a bunch of new changes. Would you mind pulling them and giving it a shot and seeing if you still have any issue?

jayjb commented 1 year ago

Hi @JStyle21,

I am closing this issue due to inactivity. With the new wholesale changes landed, please pull the latest code. If you continue to have this issue, please reopen this issue.