[Python] Error API Shodan Error: Access denied (403 Forbidden)

Discussão em 'Python' iniciado por Stack, Setembro 28, 2024.

  1. Stack

    Stack Membro Participativo

    When i try to scan an ip, always throes the same error, (Error: Access denied (403 Forbidden))

    def getShodan(ip):
    print("-------Shodan-------")

    try:
    api = shodan.Shodan("")
    info = api.host(ip)
    return ("""
    IP: {}
    HOSTNAMES: {}
    COUNTRYNAME: {}
    PORTS: {}
    ORGANIZATION: {}
    OPERATINGSYSTEM: {}
    """.format(ip, info.get('hostnames'), info.get('country_name'), info.get('ports'), info.get('org'), info.get('os')))
    except shodan.exception.APIError as e:
    print(('Error:')+' %s\n---------------------------------\n\n' % e)
    exit(0)


    I already change the API key multiple times but nothing changes

    Continue reading...

Compartilhe esta Página