ntop / ntopng

Web-based Traffic and Security Network Traffic Monitoring
http://www.ntop.org
GNU General Public License v3.0
6.21k stars 651 forks source link

Add ASN REST #7027

Closed MatteoBiscosi closed 1 year ago

MatteoBiscosi commented 1 year ago

What would you like to add or change?: Currently no ASN REST is available in ntopng, for this reason I'd like to add a new REST returning correctly the ntopng ASN data

midoelhawy commented 1 year ago

Hi @MatteoBiscosi Unfortunately, the API not working as expected.

The API redirect to : Location: /lua/http_status_code.lua?message=not_found&referer=MY_IP_ADDRESS%3A3000%2Flua%2Frest%2Fv2%2Fget%2Fasn%2Fasn_info.lua%3Fifid%3D0&error_message=

The query :

curl -u admin:PASSWORD -H "Content-Type: application/json" -I 'http://MY_IP_ADDRESS:MY_PORT/lua/rest/v2/get/asn/asn_info.lua?ifid=0&asn=21859'

NTOPNG VERSION : v.5.4.221222