Te-k / harpoon

CLI tool for open source and threat intelligence
https://www.randhome.io/blog/2018/02/23/harpoon-an-osint-/-threat-intelligence-tool/
GNU General Public License v3.0
1.16k stars 181 forks source link

BUG: Threatminer API seems broken #146

Closed evilcel3ri closed 3 years ago

evilcel3ri commented 3 years ago

Command ran: harpoon intel domain perdu.com

###################### perdu.com ###################
[+] Checking ThreatMiner...
Traceback (most recent call last):
  File "/home/chris/_HUB/harpoon/.env/bin/harpoon", line 8, in <module>
    sys.exit(main())
  File "/home/chris/_HUB/harpoon/.env/lib/python3.7/site-packages/harpoon/main.py", line 61, in main
    plugins[args.command].run(config, args, plugins)
  File "/home/chris/_HUB/harpoon/.env/lib/python3.7/site-packages/harpoon/commands/intel.py", line 70, in run
    plugins[p].intel("domain", unbracket(args.DOMAIN), data, conf)
  File "/home/chris/_HUB/harpoon/.env/lib/python3.7/site-packages/harpoon/commands/threatminerc.py", line 206, in intel
    response = tm.passive_dns(query)
  File "/home/chris/_HUB/harpoon/.env/lib/python3.7/site-packages/threatminer/threatminer.py", line 46, in passive_dns
    response = self.session.get('https://api.threatminer.org/v2/domain.php?q={}&rt=2'.format(site)).json()
  File "/home/chris/_HUB/harpoon/.env/lib/python3.7/site-packages/requests/models.py", line 898, in json
    return complexjson.loads(self.text, **kwargs)
  File "/usr/lib/python3.7/json/__init__.py", line 348, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.7/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.7/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
evilcel3ri commented 3 years ago

Cannot reproduce, probably not on our side

zaqes commented 3 years ago

I also had this issue, but it was fixed with the latest commits.

evilcel3ri commented 3 years ago

Ok, works my other machine too where the problem was seen first. I guess it was not on our side or something like that.