christophetd / CloudFlair

🔎 Find origin servers of websites behind CloudFlare by using Internet-wide scan data from Censys.
https://blog.christophetd.fr/bypassing-cloudflare-using-internet-wide-scan-data/
2.48k stars 345 forks source link

Error when i run docker command #85

Open RedaBenh opened 3 months ago

RedaBenh commented 3 months ago

When i run the docker command on a website under cloudflare, i get this error: Command: $ docker run --rm -e CENSYS_API_ID=your-id -e CENSYS_API_SECRET=your-secret christophetd/cloudflair myvulnerable.site

Result:

Traceback (most recent call last):
  File "/data/cloudflair.py", line 184, in <module>
    main(args.domain, args.output_file, censys_api_id, censys_api_secret)
  File "/data/cloudflair.py", line 153, in main
    hosts = find_hosts(domain, censys_api_id, censys_api_secret)
  File "/data/cloudflair.py", line 43, in find_hosts
    cert_fingerprints = censys_search.get_certificates(domain, censys_api_id, censys_api_secret)
  File "/data/censys_search.py", line 30, in get_certificates
    [cert["parsed.fingerprint_sha256"] for cert in certificates_search_results]
  File "/data/censys_search.py", line 30, in <listcomp>
    [cert["parsed.fingerprint_sha256"] for cert in certificates_search_results]
  File "/usr/lib/python3.6/site-packages/censys/search/v1/api.py", line 141, in search
    payload = self._post(self.search_path, data=data)
  File "/usr/lib/python3.6/site-packages/censys/common/base.py", line 213, in _post
    return self._make_call(self._session.post, endpoint, args, data)
  File "/usr/lib/python3.6/site-packages/censys/common/base.py", line 41, in _wrapper
    return _impl()
  File "/usr/lib/python3.6/site-packages/backoff/_sync.py", line 94, in retry
    ret = target(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/censys/common/base.py", line 39, in _impl
    return method(self, *args, *kwargs)
  File "/usr/lib/python3.6/site-packages/censys/common/base.py", line 204, in _make_call
    details=details,
censys.common.exceptions.CensysNotFoundException: 404 (not_found): The requested URL was not found.

I think it's a bug, Can you help please, i did find any other options to fix it .

christophetd commented 3 months ago

Does the same thing happen without docker?